0

I installed easyphp Devserver17 on my PC (Windows 7 64bits) to kick-start my educational progression with PHP. I wanted to code php along with js, html, css before uploading these to my web host server.

I checked easyphp dashboard and everything seems to work fine:

  1. I finished setup my working directory.
  2. Started http server.
  3. Seems no error or issues or anything like that.

Then...

I typed the following php code embedded within index.html to quick test:

<? php
echo "hello world!";
?>

The web-page loaded successfully but no hello world, just empty page.

I'm looking at easyphp devserver17 dashboard, everything seems to work fine except no php result on my webpage.

Though, the quick-test php does work on easyphp devserver dashboard.. not on my web-pages, which puzzles me a bit.

*****Edited*****

I'm completely new to php and do not possess in-depth technical knowledge and expert on how to custom-configure http server on easyphp devserver or manually do so via file manager (or explorer) or something like that. I'm used to coding in html and css but that's it. So this php is whole new territory for me to step on.

All I know I really want to make blogging platform from scratch for my website.

  • Two things. 1) is there really a space in your code ` php` ? - 2) how are you using this as, `http://localhost` or as `file:///`? – Funk Forty Niner Mar 09 '18 at 23:03
  • and 3) *"embedded within index.html"* - did you instruct your server to treat `.html` files as php? 4) when you view your HTML source, what do you see? – Funk Forty Niner Mar 09 '18 at 23:03
  • @Funk Forty Niner 1) I removed the space between and php, and result is still same as before. 2) The latter one. I mean, when I finished setup working directory and started http server on easyphp devserver dashboard, I closed it then go to my working directory where my web files are then I just open it with firefox internet browser to see result, I presumed that it along with php code within it will be interpreted by the server automatically but no result. – Tyler Snider Mar 10 '18 at 14:30
  • @Funk Forty Niner 3) No, I did not instruct http server to treat .html files as php. I do not know how to do so. 4) When I viewed it (index.html with php codes) as source on firefox browser, the php codes are colourized as red. – Tyler Snider Mar 10 '18 at 14:31
  • Look at both duplicates that I used to close the question with. As well as my first comment. – Funk Forty Niner Mar 10 '18 at 14:31
  • @Funk Forty Niner, the truth is my question isn't exact duplicate of other questions along with answers which I already checked. Why mark this as exact duplicate which doesn't make sense when contents of my question isn't actually exactly same as other listed questions answers you closed this with. You know this to be true. – Tyler Snider Mar 10 '18 at 18:45

0 Answers0