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.

Use same channel on one page twice

October 17, 2012 5:14am

Subscribe [2]
  • #1 / Oct 17, 2012 5:14am

    WeeRab

    3 posts

    Bit of a weird name, bit of a weird problem.

    I have created a channel for cases, where the client can add a case. In the case detail page, I show the details of the selected case (based on the URI detail/case-title:

    <h1>Case overzicht</h1>
    
    {exp:channel:entries channel="cases" }
    <h2>{title}</a></h2>
    
    <p>{question}</p>
    
    <p><br />
    {answer}</p>
    
    <p><br />
    {/exp:channel:entries}


    On that same page, I would like to show all the available cases…..so the same channel, cases:

    <?php $teller = 1; ?>
    <div class="content-panels">
    
    <div class="arrowgreen">
     <ul>
    <? $channel = ""; ?>
    <? $limit = ""; ?>
    {exp:channel:entries limit="4" disable="categories|member_data|pagination" channel="cases" sort="asc"}   
     <li><a href="http://{url_title_path=%27cases/detail%27}" title="{title}"><h2>CASE: 0<?php echo $teller; ?></h2><p>{subtitel}</a><div class="pijl"></div></li><br />
    <?php $teller++; ?><br />
    {/exp:channel:entries} <br />
        </ul><br />
    </div><br />
    </div>

    But now this overview of cases, will only show the selected case as well. Is there a way to “clear” the data, so that it will show the full channel entries within the cases channel? Like set the variables to “” or NULL ?

    Hope someone can help me. 😊

    Cheers, Robbert

     

  • #2 / Oct 17, 2012 8:07am

    danieljohnbarnes

    151 posts

  • #3 / Oct 17, 2012 8:23am

    WeeRab

    3 posts

    Ahhhh got it, thanks!! Such a small parameter, big result. Thnx!

  • #4 / Oct 17, 2012 12:26pm

    Kevin Smith

    4784 posts

    Yes, that’s a parameter you’ll want to tattoo on your brain, Robbert! Definitely one that’s important to remember.

    Anything else you need help with?

  • #5 / Oct 17, 2012 2:31pm

    WeeRab

    3 posts

    Hi Kevin,

    No thanks, the tattoo guy is on it’s way 😉. I’m a very happy EE (and Codeigniter) fan since 4 months now, don’t want to go back after some nice projects! If I have any other questions I know where to go!

    Thanks for the replies guys, well appreciated.

    Cheers, Robbert

  • #6 / Oct 18, 2012 2:40pm

    Robin Sowell

    13255 posts

    😉  You just made a good day even better!  Glad the guys got you squared away.

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

ExpressionEngine News!

#eecms, #events, #releases