![]() ![]() If so, you are good to go, and you can continue to work with your tutorial book. ![]() When you preview that file you will see a complete page full of information about your installed PHP version. Then create a simple "testInfo.php" file with onlyīetween the body tags. READ that post, and FOLLOW the instructions. In my previous post, I described to you clearly how to configure EW to find the php-cgi.exe file. Since yours clearly does, you either do not have the correct "php" extension on the file, or you have not told EW where to find the PHP executable, or both (I'm betting on the latter). In any event, what it does not do is display the raw PHP code. That said, the code does properly execute and emit the expected HTML when the PHP executable is correctly configured. Yes, the code as written both misspells Fahrenheit and misspells and miscapitalizes Celsius, and omits the space preceding the Celsius value. In Firefox displaying the single line "Body temperature is 98.6 degrees Faranheit(37 degrees celcius)". Since I do, in fact, have PHP properly configured in EW, when I previewed the file the page opened As a check, I copied and pasted your PHP code, above, into a blank PHP file in EW. It is quite clear that you have not properly configured your PHP executable. ![]() It is common courtesy to recognize those who have helped you, and it also makes it easier for visitors to find the resolution later. Please remember to "Mark as Answer" the responses that resolved your issue. I would suggest that you might want to slow down, learn to read and understand HTML markup (not just use the EW design view), and then start working withīasic PHP tutorials, which will help you to understand how to set up and enable PHP, and how to write, test, and debug PHP code. Or, for that matter, what HTML is and how it works, how it differs from server-side code or even client-side javascript, To be honest, from here it sounds as if you have jumped into using PHP without any understanding of what it actually is and how it works. You want to set it to be used for "all pages" so that the server will be started always, so that if you openĪ plain HTML page, then navigate from there to one of your PHP pages, the server will be running and able to execute the PHP page. You would point to the one that came with Abyss. Here is a sample of the settings you needĪs you can see, I installed WAMPServer and used the PHP executable that came with it. Then, in the "Site|Site Settings|Preview" tab for your site, tell EW to use the PHP executable found in Application Options. Options|General" tab, in the "Path to PHP executable." text box. You need to do that in the "Tools|Application If you would simply post the page to your server, then provide a link here so that we can actually see the source code, we could very quicklyĭetermine exactly where the problems exist in your source code and help you to correct it.Īs for your PHP code, you need to name your page(s) with a PHP extension, and you need to point EW to the location of your php-cgi.exe file so that the code can be read and executed and converted to HTML for the browser. HTML is a "fail-safe" protocol, in that if the browser sees markup that it does not understand it ignores it. that code is executed on the server, then the emitted pure HTML is sent down to the browser-the browser never sees it, wouldn't understand it if it did, and couldn't execute it.Īs for why you're seeing all of that code and markup "in the raw," I suspect it is because your syntax is so badly written that the browser does not recognize it as a Web page and is simply rendering it as plain text, which is what you are seeing. For server-side scripting, such as PHP, ASP.NET, ASP,Įtc. ![]() javascript), that support is automatically enabled, and must in fact be disabled if the user so desires. It's the same for javascript.įirst, you don't have to "enable scripting' in any browser. Unfortunately when I try to view the page on Internet Explorer I view the whole I have installed php in EW4 on my computer (via the book) I have also enabled scripting on Internet Explorer via the instructions. ![]()
0 Comments
Leave a Reply. |