NetBeans question

Why is it that if I do not start up my webserver (i.e. MAMP) that when I try to run a PHP script in NetBeans that it does not run??

TomTees

Actually I was confused in my original post?! (:

It seems to me that in the past, that if I didn’t have an Internet connection then I could get PHP scripts to run in NetBeans. (Instead I was thinking it was if MAMP wasn’t running, which would obviously cause issues! Duh!)

But when I turned off my Internet conenction today, but had MAMP running and NetBeans running, my PHP script ran, so I’m not sure why I thought that was an issue in the past?

TomTees

yes.

Netbeans is the IDE - which comes with it’s own installed server(s) but I can’t get them to work with php (only JSF), so I use XAMPP as my web server for php.

PHP is a server side scripting language and so PHP code is executed on a web server and so your php script needs the web server it is sitting on to be running.

So MAMP is the webserver and not NetBeans?

TomTees