0

I'm about to run out screaming! I have a news/index template and news/article that views fine until I add a third segment eg: news/article/test.

The only channel entry that appears on the news/article/test page is the info wrapped in the news channel entry tags. All other channel entry tags do not any longer appear. I have a few other channel entries on the page but they are gone just on the "test" page. Below is the part of the template.

    {exp:channel:entries channel="site_layout_options" limit="1"}
      {news_page_layout_options}        
      <div class="{newsFluid} section">
      {/news_page_layout_options}
    {/exp:channel:entries}

      <div class="row two-col-row">

               <div class="col-sm-10 entry-wrapper items-container">
                  {exp:channel:entries channel="news" limit="1"}
                  <div class="{layout} news-col entry-container">
                    <div class="item">
                       <h2>{title}</h2>
                       <p>{article_content}</p>
                       <a href="/news/{segment_2}/{url_title}"><button class="btn btn-md btn-transparent-black">READ MORE</button></a>
                    </div>
                 </div>
                 {/exp:channel:entries}
               </div>

               <div class="col-sm-2 items-container">
                  <div class="col-sm-12 news-col item">
                       <h2>Archieves</h2>
                       <p>{date}</p>
                  </div>
               </div>

            </div>

    </div>

The first channel entry for "site_layout_options" is left out. This goes for any other channel entry on the page with the exception of the "news" channel entry.

I'm using channel fields to control some styling and thought that it may be causing some problems but not luck. I removed it and anything that is outside of the "news" channel is gone. The strange thing is that it only happens when I view the "news/article/test" page.

I'm using the following opening channel tag on the "news/index" page to link to the full article.

{exp:channel:entries channel="news" limit="6" dynamic="no"}

and the link is:

{url_title_path='news/article'}

I've tried dynamic="off" and a few different url options with no luck.

  • I figured it out. I didn't set all the other embedded channel entries to dyanamic="no". Sometimes I hate this stuff. – lanceb Aug 16 '15 at 20:17
  • We have all been bitten by dynamic="no" - no shame in that! – Derek Hogue Aug 16 '15 at 21:49
  • I tend to write dynamic="no" for every channel:entries tag (I guess its instinctive now) and remove it if I absolutely need to. Because 99/100 of our clients require more complex routing than the standard EE model it works out well for me. I feel your pain! – Blatant Aug 20 '15 at 17:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.