All Low add-ons are now owned by EEHarbor. Read the blog post.

Support archive

Previous entry works but next entry doesn't

thedesigncore 20 May 2013 22:31 question, complete

For some reason my previous entry link works correctly but my next entry does not.

I'm using the following code:

 
<ul>
<li id="prevProject">
{exp:low_reorder:prev_entry set="1" entry_id="{entry_id}" prefix="prev_" loop="yes"}
<a href="{path='our-work/{prev_url_title}'}" title="Previous Project"></a>
{/exp:low_reorder:prev_entry}
</li>
<li id="closeProject">
<a href="{site_url}" title="Back to Home"></a>
</li>
<li id="nextProject">
{exp:low_reorder:next_entry set="1" entry_id="{entry_id}" prefix="next_" loop="yes"}
<a href="{path='our-work/{next_url_title}'}" title="Next Project"></a>
{/exp:low_reorder:next_entry}
</li>
</ul>


The prev_entry link takes me through all of my entries in the correct order but the next_entry link alternates me between the 1st entry & the 7th.

Any help is appreciated.

Replies

  1. Low 21 May 2013 06:52

    What are your EE, LR and PHP versions?
    Also, what are your Reorder Set's settings? A screenshot would help there.

  2. thedesigncore 21 May 2013 12:40

    EE 2.4, LR 2.1.1, PHP 5.3.5

  3. Low 21 May 2013 13:05

    I take it you're nesting the tags inside a channel:entries or low_reorder:entries loop? Also, can you enable the Template Debugger and copy/paste the output for a page with the wrong 'Next' link here?

  4. thedesigncore 21 May 2013 13:31

    I am nesting the tags inside a channel:entries loop.

    I turned on template debugging but do not get any output. I tried creating a blank template with just a simple channel:entries tag but still got no debug info. No sure what's going on here.

  5. Low 21 May 2013 13:33

    Is your CP on another domain than the front-end of your site?

  6. thedesigncore 21 May 2013 13:39

    Yes.

  7. Low 21 May 2013 13:41

    Well, that explains why you're not recognised as logged in on the front end, as the cookie is set on the CP's domain.

    Is the CP on a subdomain? If so, try to set the cookie domain to .yourdomain.com

  8. thedesigncore 21 May 2013 13:45

    It's not on a subdomain. The cookie setting did not work.

  9. Low 21 May 2013 13:47

    Well then. Copy an admin.php file from an EE install to the root of your front-end site, make sure the $system_path variable inside it points to your EE system folder, and use that to log in on the site. Then at least you should be able to log in under that domain and see the template debugger.

  10. thedesigncore 21 May 2013 13:59

    Ah! This is an MSM install and I was logged in on a different domain. I logged in using the domain in question & debugging works!

    Here's the output for the reorder stuff:

     
    (0.002277 / 7.75MB) Parse Date Format String Constants
    (0.002521 / 7.75MB) Parse Current Time Variables
    (0.002619 / 7.75MB) Parsing Segment, Embed, and Global Vars Conditionals
    (0.006346 / 7.84MB) - Beginning Tag Processing -
    (0.006380 / 7.84MB) Parsing Tags in Template
    (0.006430 / 7.84MB) Tag: {exp:channel:entries channel="work" limit="1" require_entry="yes" dynamic="yes" status="open|home" disable="category_fields|member_data|pagination" }
    (0.006571 / 7.84MB) Closing Tag Found
    (0.006676 / 7.85MB) Processing Tags
    (0.006724 / 7.85MB) Module Tag: Channel/entries
    (0.006747 / 7.85MB) Including Files for Plugins and Modules
    (0.024921 / 10.21MB) Files for Plugins and Modules All Included
    (0.025662 / 10.23MB) Beginning Final Tag Data Processing
    (0.025697 / 10.23MB) Calling Class/Method: Channel/entries
    (0.026402 / 10.24MB) -> Class Called: Channel
    (0.028762 / 10.50MB) -> Method Called: entries
    (0.061789 / 13.73MB) Calling Extension Class/Method: Low_reorder_ext/channel_entries_query_result
    (0.062093 / 13.73MB) Calling Extension Class/Method: Store_ext/channel_entries_query_result
    (0.089599 / 16.22MB) Calling Extension Class/Method: Matrix_ext/channel_entries_tagdata
    (0.114599 / 17.13MB) -> Data Returned
    (0.114714 / 17.08MB) Parsing Tags in Template
    (0.114750 / 17.09MB) Tag: {exp:low_reorder:prev_entry set="1" entry_id="95" prefix="prev_" loop="yes"}
    (0.114827 / 17.09MB) Closing Tag Found
    (0.114887 / 17.09MB) Tag: {exp:low_reorder:next_entry set="1" entry_id="95" prefix="next_" loop="yes"}
    (0.114944 / 17.09MB) Closing Tag Found
    (0.114985 / 17.10MB) Processing Tags
    (0.115021 / 17.10MB) Module Tag: Low_reorder/prev_entry
    (0.115038 / 17.10MB) Module Tag: Low_reorder/next_entry
    (0.115050 / 17.10MB) Including Files for Plugins and Modules
    (0.116312 / 17.29MB) Files for Plugins and Modules All Included
    (0.116334 / 17.29MB) Beginning Final Tag Data Processing
    (0.116349 / 17.29MB) Calling Class/Method: Low_reorder/prev_entry
    (0.116485 / 17.29MB) -> Class Called: Low_reorder
    (0.116625 / 17.29MB) -> Method Called: prev_entry
    (0.116663 / 17.29MB) Low Reorder: Retrieving set from database
    (0.117424 / 17.30MB) Low Reorder: Getting ordered entry_ids from database
    (0.118108 / 17.30MB) Low Reorder: Getting prev entry from stack 355|98|100|457|96|461|97|361|99
    (0.118968 / 17.30MB) -> Data Returned
    (0.119002 / 17.30MB) Calling Class/Method: Low_reorder/next_entry
    (0.119103 / 17.30MB) -> Class Called: Low_reorder
    (0.119227 / 17.30MB) -> Method Called: next_entry
    (0.119268 / 17.30MB) Low Reorder: Retrieving set from cache
    (0.119298 / 17.30MB) Low Reorder: Getting ordered entry_ids from cache
    (0.119345 / 17.31MB) Low Reorder: Getting next entry from stack 461|96|457|100|98|355|95|99|361|97
    (0.120177 / 17.30MB) -> Data Returned
    (0.120217 / 17.30MB) - End Tag Processing -
    (0.120240 / 17.30MB) Processing Advanced Conditionals
    (0.120788 / 17.31MB) - Processing Sub Templates (Depth: 1) -
    (0.120812 / 17.31MB) List of Embeds: includes/head url_title=cirque-du-horror title_suffix=Our Work,includes/header
    (0.120877 / 17.31MB) Processing Sub Template: includes/head
    (0.120893 / 17.31MB) Retrieving Template
    (0.120906 / 17.31MB) Retrieving Template from Database: includes/head
    (0.121393 / 17.32MB) Template Found
    (0.121495 / 17.31MB) Template Type: webpage
    (0.121529 / 17.32MB) Parsing Site Variables
    (0.121564 / 17.32MB) Snippets (Keys): freelancer_version|csm:action|csm:error|snp-props|snp-footer|site_id|site_label|site_short_name|last_segment

  11. Low 21 May 2013 14:11

    Still can't seem to replicate.

    Can you send SuperAdmin login credentials to hi at gotolow dot com so I can take a look myself?

  12. thedesigncore 21 May 2013 14:22

    Sent. Thanks for looking into this!

  13. Low 21 May 2013 14:44

    Saving the Set's order and clearing the cache solved the issue.