Mobile app version of vmapp.org
Login or Join
Deb1703797

: Link absolute URIs correctly when loading pages locally When developing pages, I like to load them in my browser locally to see how they look rather than have to deploy them to the server

@Deb1703797

Posted in: #Html #Url

When developing pages, I like to load them in my browser locally to see how they look rather than have to deploy them to the server every time. I'm using Lift and server deployment takes a few seconds, and just running Lift puts a heavy strain on my old laptop. The problem is absolute paths e.g. /css/main.css, while correct on the server, will cause the browser to search from the root filesystem e.g. file:///css/main.css when I open the page locally.

Is there a technique to be able to work with absolute paths, yet somehow trick the browser into using a different base to calculate the paths from when loading the pages locally? A browser plug-in perhaps?

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Deb1703797

1 Comments

Sorted by latest first Latest Oldest Best

 

@Candy875

You probably want to make your browser run a small webserver: addons.mozilla.org/en-US/firefox/addon/browser-server/

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme