Benjamin Adler: apache zickt bei php dateien

Beitrag lesen

Hi!

Ich habe ein Problem mit meinem Apache unter Linux...
Ich bin gerade am PHP-lernen und möchte meine Dateien eigentlich lokal testen.
Aber er macht es nicht mit!
Wenn ich diese Datei:
  <html>
  <body>
  <?php
     // es folgt der echo-Befehl
     echo "Dieses Programm wurde geschrieben";
     echo " von Max Müller";
  ?>
  </body>
  </html>

mit http://localhost/test.php aufrufen möchte, kommt diese Fehlermeldung:
   Parse error: parse error, unexpected T_STRING in /srv/www/htdocs/test.php on line 5

Und dass, obwohl die Datei ganz sicher korrekt ist -> Ich hab sie per Copy & Paste aus meinem ebook rauskopiert...

Weiss jmd, was da falsch läuft?

Achja: wenn ich nur http://localhost eingebe, kommt die Webserver-Testseite, auf der deutlich steht, dass PHP 4 installiert ist:

+++ testinfo - webserver +++

This is only a test page for the webserver!
          SuSE is not responsible for the contents of this domain!

system information Operating system: [ SuSE Linux 8.1 (i386) ]
   Host: [ linux.local, Kernel: 2.4.19-4GB (i686) ]

webserver and modules Webserver version:
   [ Apache/1.3.26 (Linux/SuSE) PHP/4.2.2 ]
   Installed modules:
   [ PHP4 module ]
   [ Apache perl module (mod_perl) is not installed ]
   [ Apache DAV module (mod_dav) is not installed ]
   [ Apache Python module (mod_python) is not installed ]

documentation [ This host is not configured as server for the SuSE
   help system ]
   [ Apache manual is not installed ]
   [ The SuSE website ]

powered by SuSE

Vielen Dank für Vorschläge!

d:-) Benny