LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Test HTML file locally with my browser before posting it on a WEB server (https://www.linuxquestions.org/questions/linux-newbie-8/test-html-file-locally-with-my-browser-before-posting-it-on-a-web-server-731185/)

mcanallyd 06-06-2009 07:10 PM

Test HTML file locally with my browser before posting it on a WEB server
 
I can not test my INDEX.HTML document locally. The HTML document is properly formatted with html file extension. My operating system is Ubuntu and my browser is Mozilla Firefox. All Firefox does is display the HTML code.

I am doing nothing that I have not done many times with Microsoft Windows. Surely Linux operating systems provides the tools to check html files locally before posting them on a web server.

Thanks,

linus72 06-06-2009 07:43 PM

Yes, use apache2, available thru synaptic package manager
after installing, use file browser to go to /var/www.
If no www folder exists, make one in /var.
make a folder name "apache2-default" in "www".
Place index.html in /var/www/apach2-default folder.
Open firefox and enter into address bar
127.0.0.1
It should load your index.html
I had to reset it once and it worked.

You can also skip the "apache2-default" folder and just put the index.html in "www" folder too.

MrChilly0 06-06-2009 10:01 PM

you can also point firefox to the file itself /home/whatever/test.html

edit: whoops..missed the original post..my bad


All times are GMT -5. The time now is 09:40 PM.