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.

channel within channels

June 22, 2012 2:02pm

Subscribe [1]
  • #1 / Jun 22, 2012 2:02pm

    vincentstephens

    13 posts

    Hi, I am building a multimedia resource. 

    It has three categories, established, settling and historical.  The first two categories I have built and are running off channel their own channel and respective channel fields.  (resource - established channel and resource - settling channel)

    The third category has a channel and channel fields (resource - historical) This section is different as it will have a channel in side of it. 

    -> Channel Historical - some historical ee channel field tags including {century_selector}

    The century selector is a text area that contains the ee embed code for the associated channel.  ie, for one of the entries in the historical channel, there will be the embed code of the 16th century channel inside the century selector text area. 

    Problem is that I am getting the ee tags come up without rendering the channel field entries.

    Here is a working example, where the 16th Century channel embed code is used on the 16th century section and below the resource.  This shows the code working and pulling in the three channel fields.  I have tried to change the century selector default formatting field to both none and xhtml, neither option work. 

    http://www.theworldatyourfeet.co.uk/index.php/twayf/resource

    the resource html:

    <!-- ESTABLISHED -->
             <ul title="Established">
                 
                 {exp:channel:entries channel='story_resources-established'}
                 <li>
                  {image-established}
                        <div>{title} - {story_type-established}</div>
                        <div class="content">
                         <h3>{title}</h3>
    <p>                        {story_description-established}<br />
                            </p>
    
    <p>                        <table><br />
                             <tr><br />
                              <td width="420"><br />
                               <iframe src="http://www.youtube.com/embed/{media_source-established}" frameborder="0" allowfullscreen ></iframe><br />
                              </td><br />
                              <td align="left"><br />
                               A copy of the story transcript is available for download in text format. <br />
     <br />
                            <a href="http://{text_transcript_established}">_                        <a href="http://www.theworldatyourfeet.co.uk/images/download1.png">http://www.theworldatyourfeet.co.uk/images/download1.png</a></a><br />
                              </td><br />
                             </tr><br />
                            </table><br />
                         </div>                  <br />
                    </li>  <br />
         {/exp:channel:entries}<br />
                 <br />
                  </ul><br />
       </p>
    
    <p>   <br />
       <br />
       <!-- SETTLING --><br />
                <ul title="Settling"><br />
                 <br />
                 {exp:channel:entries channel='story_resources-settling'}<br />
                 <li><br />
                        {image-settling}<br />
                        <div>{title} - {story_type-settling}</div><br />
                        <div class="content"><br />
                          </p><h3>{title}</h3>
    <p>                        {story_description-settling}<br />
                            </p>
    
    <p>                        <table><br />
                             <tr><br />
                              <td width="420"><br />
                               <iframe src="http://www.youtube.com/embed/{media_source-settling}" frameborder="0" allowfullscreen ></iframe><br />
                              </td><br />
                              <td><br />
                               A copy of the story transcript is available for download in text format. <br />
     <br />
                            <a href="http://{text_transcript_settling}">_                        <a href="http://www.theworldatyourfeet.co.uk/images/download1.png">http://www.theworldatyourfeet.co.uk/images/download1.png</a></a><br />
                              </td><br />
                             </tr><br />
                            </table><br />
                      </div>                  <br />
                   </li><br />
                    {/exp:channel:entries}</p>
    
    <p>  </ul><br />
                <br />
                <br />
                <!-- Historical Historical --><br />
                <ul title="Historical"><br />
                    <br />
                    {exp:channel:entries channel='story_resources-historical' fixed_order="62|51|63|64|65|66"}<br />
                 <li><br />
                        {image-historical}<br />
                        <div>{title} - Story Assets</div><br />
                        <div class="content"><br />
                            </p><h3>{title}</h3>
    <p>                        {asset_description-historical}<br />
                                <div id="historical_assets"><br />
                                  {century_selector}<br />
                                 </div><br />
                             <br />
                         </div>                  <br />
                   </li><br />
                    {/exp:channel:entries}<br />
                    <br />
                  </ul><br />
                <br />
                           <br />
            </div><br />
      </div><br />
    </div></p>
    
    <p><br />
    <table><br />
    {exp:channel:entries channel='resource_historical_16thc' }</p>
    
    <p><tr><br />
    <td> {asset_description} </td> <td>{asset}</td><br />
    </tr><br />
    <tr><br />
    <td>{text_asset}<td><br />
    </tr></p>
    
    <p>{/exp:channel:entries}<br />
    </table>

     

    Any help greatly appreciated…Monday deadline!

     

    Thanks, Vince

  • #2 / Jun 25, 2012 4:01pm

    Dan Decker

    7338 posts

    Hi Vince,

    I hope your deadline is still ahead!

    The century selector is a text area that contains the ee embed code for the associated channel.  ie, for one of the entries in the historical channel, there will be the embed code of the 16th century channel inside the century selector text area.

    I’m not sure I follow you here - out-of-the-box, ExpressionEngine does not support anything like this. However, you can use Relationships or you can pass the value of your {century_selector} field to an embedded template within your main template.


    Cheers,

     

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

ExpressionEngine News!

#eecms, #events, #releases