2008年11月24日星期一

Re: [fw-mvc] CSS problem on application path

Are you using a relative path to your CSS file? With a trailing slash at the end of the url, the browser will attempt to look in the /mypath folder for the CSS file.

I've found it's best to prefix my CSS paths with a forward slash:

// in a controller
$this->view->headStyle()->appendStylesheet('/mystyles.css');


-Hector


On Mon, Nov 24, 2008 at 7:53 AM, Carlos Castro <carloscastro.carlos@gmail.com> wrote:
Hi everybody,
I have a problem with my application aspect (CSS) when i put a slash (/) at the end of my URL.

Example:

http://application/mypath  => it works perfectly
http://application/mypath/ => the page is showed without CSS efects

Can someone help me to resolve this problem?

Best Regards,
Carlos Castro


没有评论: