Good morning, folks! I’m running into an issue with same-page extended entries, and I’m hoping one of you can help.
Way back in the day, when I’d first started using EE, I had a lovely JS code that allowed me to extend a blog entry right there on the same page. Being fairly certain that it’s pretty obsolete, I’ve gone in search of a new way to do it, and have found this entry on the forums:
https://ellislab.com/forums/viewthread/56925/
Now, I’ve created a JS (using what you see on that thread) template within my template group of embeds; embedded it into the header of my pages, and added the appropriate extended entry code to my template. Code is below:
The URL where this displays is http://www.thesagefuloak.com/index.php/site/news/site-launch . The problem occurs when I click on the “Read less” link, and I’m smacked upside the head with “The URI you submitted has disallowed characters.” In looking at the URL structure after clicking the “Read less” link, it looks like this:
http://www.thesagefuloak.com/index.php/site/news/[removed]void(0);And….I’m lost. If you can help me figure this out, I’d really appreciate it. I prefer the idea of not having to navigate to a single entry page to continue reading a post (just personal preference), and would love to once again be able to implement this feature!
Thanks so much, all! 😊
It’s actually a javascript problem, not an EE problem.
This line is the problem:
Returning
truemeans that the click event should be propagated upwards, resulting in the location.href being set.
Change the true to false and magic happens.
Edit: it appears that EE forums have stripped all the code out that would make the above make sense. Sigh. No posting certain types of javascript here I guess…
So here is the specifics:
showHide(17,0,this,'entry');return true;should be changed to :
showHide(17,0,this,'entry');return false;Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.