Friday, May 29, 2009

Routes and AJAX

Do you have to do anything special when you have custom routes and calling an Ajax function?
 
Trying to do something simple and no luck.....update a div
 
my routes take users/journals to /journals simply removing the "users" in the url....
 
Now on journals i want to load a entry (element) into a div and all i get is users/journal/entry not found.
 
I have other ajax div updates on pages where there are no route changes and it works fine....
 
Checked:
render the entry.ctp in the elements folder
 
Tried url in the html link helper using users/journals  and journals
 
Tried leaving controller action as # in the link and use $("#page_load").load( id + '/entry' , {
 
What am I missing? The  div fades out where the new one should load...then users/journal/entry not found.
 
What am I doing wrong / missing?
 
Thanks
 
Dave

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments: