ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

show_pages and entry_id together

February 16, 2012 4:26pm

Subscribe [1]
  • #1 / Feb 16, 2012 4:26pm

    John-Gordon

    76 posts

    I just tried using the parameters show_pages=“only” and entry_id=“not 1” and get these errors:

    A PHP Error was encountered
    
    Severity: Notice
    
    Message: Array to string conversion
    
    Filename: channel/mod.channel.php
    
    Line Number: 1507
    
    A PHP Error was encountered
    
    Severity: Warning
    
    Message: Cannot modify header information - headers already sent by (output started at /home/content/77/8449677/html/cpll/codeigniter/system/core/Exceptions.php:170)
    
    Filename: core/Common.php
    
    Line Number: 405
    
    
    Fatal error: ob_start() [<a href="http://ref.outcontrol">ref.outcontrol</a>]: Cannot use output buffering in output buffering display handlers in [path-to-system]/codeigniter/system/core/Exceptions.php on line 166

    I removed the “not” operator and it worked fine; it showed only entry #1.

    Are these parameters not allowed together or is this a bug?

  • #2 / Feb 17, 2012 6:09pm

    Dan Decker

    7338 posts

    Hi John-Gordon,

    Those parameters can be used together. In your example though, unless every entry on your site besides ID is assigned as a page, you are going to see the error.

    Essentially you are telling channel entries to only display pages and that every entry that isn’t “1” is a page. So, I think it is rather confused.

    Does that help clarify for you? Can you tell me what it is you are trying to accomplish and I will be happy to help you get there!

    Cheers,

  • #3 / Feb 17, 2012 6:34pm

    John-Gordon

    76 posts

    That is rather confusing.

    I just wanted to display pages in a footer and I wasn’t sure if I wanted entry #1 in the output.  It’s not a big deal.  I went ahead and have it showing; doesn’t matter either way.

    A hypothetical: Say I also had categories assigned to these pages, would category=“not 1” work? or are we looking at the same problem?

  • #4 / Feb 22, 2012 5:34pm

    Dan Decker

    7338 posts

    Hi John-Gordon,

    would category=“not 1”

    I do believe that would work. As long as the 1 entry you didn’t want to include was the only entry in category 1.

    Cheers,

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases