|
Posted by Erwin Moller on 06/13/07 15:17
rhXX wrote:
> hi,
>
> i need to begin in php. is there any tutorial to begin? (i started an
> hour ago .....)
>
> i copied this first example
>
> <html>
> <head>
> <title> Hello World </title>
> </head>
> <body>
>
> Hello, world!
>
> <?php
>
> echo 'This is my first PHP web page.';
>
> ?>
>
> </body>
> </html>
>
> and saved as .html file, and when i open it with the browser, it
> appears only the html part, but not php ....
Not entirely true.
Check the source of the html page, and you find the php-part in there just
fine. It only didn't execute. :)
The problem with your approach is that you need PHP to actually run.
Just throwing it into a browser as a html-file will not do.
You need PHP installed on a server (can be your own machine), and tell your
webserver (Apache/IIS/whatever) that it should use PHP for all requests
that end with .php (.html is NOT a smart idea).
That asside, I tink e_matthes gave you a better answer: Just get a good
book.
I prefer books from O'Reilly, but that is a matter of taste.
Regards,
Erwin Moller
>
> tks in advance
Navigation:
[Reply to this message]
|