In my template I'd like to capture the entry_id of my main channel:entries loop, because I have subsequent loops where I may want to avoid that entry in one case, and invoke it again in another. So I'm looking for some way to create a variable that will allow me to do this. But the only user-defined variables I've found so far are the preload_replace ones, which happen before the channel:entries are run, so no good for my purposes.

Are there other user-defined variables I may have missed? How would you do this?


1 Answer 1


I think this is a job for Stash. We may leave the template with two channel:entries tags after all, but only because we're running out of time. This will be a ToDo if we run into performance issues.

In fact, you should be able to store the entire record in Stash, and not need a second channel:entries at all.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.