Question

I've recently been playing with nodejs and would like to build my first project with it. But there is a major stumbling block for me.

URL Generation.

I'm very used to Codeigniter's base_url() and site_url(), this gave a full url like http://www.example.com/resources/img/bla.jpg, so it's been a bit odd for me to find that there is no such equivalent functions for NodeJS / Express.

Am I going about this wrong or is there a module somewhere that would make it possible to generate urls much like base_url() and site_url() did?

I'm using the Express Framework with Jade as the template engine and MongoDB as the Database.

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top