ONJava.com -- The Independent Source for Enterprise Java
oreilly.comSafari Books Online.Conferences.


AddThis Social Bookmark Button
  Understanding MVC in PHP
Subject:   What about image
Date:   2009-03-14 06:12:29
From:   Vaielab
I have some difficulty with your mod_rewrite in the controller.

If I don't know where on the server my mvc will be, how can I show images... I mean, if the url is www.myDOmain.com/mvc/module/class and in the view I want to show an image test.jpg, the server will try to load www.myDOmain.com/mvc/module/class/test.jpg

I can't use absolute path because like I said I don't know where I'll be on the server maybe www.myDomain.com/mvc or www.myDOmain.com/test/123/ or anything else...

Some one has a idea?