Page 1 of 1

Pretty URLs not recognized by jQuery? (SOLVED)

Posted: Wed Dec 30, 2009 3:38 pm
by appleyard
Hi everyone, this is my first post. I've been using CMSMS on a few recent projects and have REALLY enjoyed it!

My issue is this: my site is using Pretty URLs, and on a page that's a few levels deep into the hierarchy (e.g. "domain.com/section/page/"), I'm running a jQuery script (Code Slider: http://www.ndoherty.biz/tag/coda-slider/ ) that uses hash links to trigger a sliding effect. Unfortunately the links are resolving to "domain.com/#2" (thus sending the browser to the homepage) instead of "domain.com/section/page/#2", which I guess is because the page is running from domain.com/index.php. When I type in the rewritten URL + hash anchor manually, it works as expected.

I have posted this question to the Coda-Slider forum as well, but it seems like this might be a problem for a lot of jQuery scripts that use hash anchors for triggers. Is there a way to pass the rewritten URL from CMSMS to JavaScript/jQuery?

Re: Pretty URLs not recognized by jQuery?

Posted: Wed Dec 30, 2009 11:35 pm
by JeremyBASS
The issue it the you’re not using a page extension.. I code heave in jQuery... never have this issue but I always use page extension .html... But that it My2Cents... Hope this helps...
Cheers
Jeremy

Re: Pretty URLs not recognized by jQuery?

Posted: Thu Dec 31, 2009 2:37 pm
by appleyard
Ah, that makes sense. Thank you sir!

Re: Pretty URLs not recognized by jQuery?

Posted: Thu Dec 31, 2009 3:56 pm
by JeremyBASS
Always happy to help, don't forget to mark solved in your original post title if it's fixed... Cheers and happy New Year.
Jeremy