Re: WebView dealing with PHP
Re: WebView dealing with PHP
- Subject: Re: WebView dealing with PHP
- From: Phillip Hutchings <email@hidden>
- Date: Sun, 4 Jan 2004 16:44:39 +1300
On 4/01/2004, at 3:53 PM, Oli Donald wrote:
Last question for tonight :)
When my WebView loads a php file via
'http://localhost/~user/index.php', it renders perfectly, but when I
load the same file via a file reference (using NSURL fileURLWithPath:)
it doesn't render the PHP at all. Is there something special I need to
do in order for php to be correctly rendered in my WebViews when the
source is a file? I do have both php and websharing enabled.
Yes, you need to run it through the web server, by requesting it via
HTTP ;)
PHP is a server-side technology, the web server processes it when the
file is requested. All the client ever sees is the processed page.
Hence, if you open it through the file system, bypassing the webserver,
you'll see the PHP code.
There is a command line PHP interpreter, I'm not sure if OS X has it
though. Type php in the terminal.
--
Phillip Hutchings
email@hidden
http://www.sitharus.com/
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.