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.

Content Organization Design Advice

May 25, 2008 6:20pm

Subscribe [2]
  • #1 / May 25, 2008 6:20pm

    Ian Cook

    93 posts

    i was wondering if anyone could give me their advice on an ee design question:

    i have a site that has a number of lesson categories. each category contains a number of video lessons which are split into a number of video segments.

    so far i have the following design ..

    each of the lesson categories is set as a category. each of the video lessons are weblog entries in a ‘lesson’ weblog.

    the problem is that each video segment isn’t really being ‘indexed’ into EE. the list of segment titles and times shown in the page is hardcoded in the {blurb} field… which is of course a dumb way to do it.

    so i guess im not sure how to represent each ‘lesson’ which is actually a collection of video segments. not sure how many categories / weblogs i should be making for various things. dont want to end up with a tangled mass of lessons.

    it seems like i should be making each lesson its own weblog, with its entries being each video segment it consists of. but, that sounds like a lot of small weblogs to be floating around in ee…. if i went that route, what if the content grew to 10x the size? how would i organize / categorize them? i suppose they’d just be associated with the lesson categories i’d previously set up….

    maybe you can nudge me in the right direction.

    thanks,

    ian

  • #2 / May 25, 2008 8:47pm

    Rob Allen

    3118 posts

    A lot probably depends on how much other content you have and how lessons and categories need to be associated with other content, and whthere you need to be able to add extra lessons to any particular catgeory later on.

    I’d look at using one blog for lessons, then using categories for lesson themes, the actual lessons/videos would then be weblog posts assigned to a relevant category. This would also allow you to create related links or Prev/next links to other lesson in the same series.

    Does that make sense?

  • #3 / May 25, 2008 9:37pm

    Ian Cook

    93 posts

    I think that’s currently how I have it…

    I have the lesson themes as categories. I have a lesson weblog where each entry contains one complete lesson. One complete lesson, however, consists of multiple lesson video segments. It’s those video segments which are being left out of EE.

    Once a lesson is published, it’s done and won’t have further content added to it. The lesson categories will contain any number of lessons in the future.

    So basically I’m unsure if a lesson should be a category with lesson segments being in a segment weblog, and associated with its lesson category, with the potential problem being that I’ll eventually have a ton of categories, one per lesson. OR, if a lesson should be a weblog and the lesson segments being another weblog with a relationship to the lesson weblog entry.

  • #4 / May 25, 2008 10:41pm

    Rob Allen

    3118 posts

    How are you calling the video files? Are you embeddeding the movie into the page or just providng a download link?

  • #5 / May 25, 2008 10:57pm

    Ian Cook

    93 posts

    The videos are loaded in a streaming flash player. The videos themselves are located on a streaming video server. The flash player loads an XML file containing the title, description, and RTMP url for each video segment.

    This is a major reason I need to get the segments entered as individual entries, because each segment needs to be listed in that XML file, so I can publish the XML file out of EE and not have to manage it manually.

  • #6 / May 26, 2008 5:14am

    Rob Allen

    3118 posts

    Hmmm, can you load a video if it’s hosted on your own server? If you can then there’s probably a path issue to the streaming server.

  • #7 / May 26, 2008 5:57am

    ExpressionEngineer

    148 posts

    One solution would be to use relationships, where one Lesson entry would contain the the meta data (description, prerequisites etc),
    and each related entry would contain the actual video segments.

    Read more about EE relationship fields here.

    The hierarchy would be something like this:

    Lesson theme (category)
    - Lesson (weblog entry)
    —Video segment 1 (weblog entry, related to Lesson using a relationship field)
    —Video segment 2 (weblog entry, related to Lesson using a relationship field)


    best
    Andy

  • #8 / May 26, 2008 2:06pm

    Ian Cook

    93 posts

    Would -Lesson and—Video Segment be each their own weblog?

    So I’d have a weblog of lessons and another weblog of Video Segments, with each being related to its Lesson weblog entry?

  • #9 / May 26, 2008 2:07pm

    Ian Cook

    93 posts

    Hmmm, can you load a video if it’s hosted on your own server? If you can then there’s probably a path issue to the streaming server.

    There aren’t any problems loading any videos. I’m only concerned with how to organize the content inside EE. 😊

  • #10 / May 26, 2008 2:09pm

    ExpressionEngineer

    148 posts

    Would -Lesson and—Video Segment be each their own weblog?

    So I’d have a weblog of lessons and another weblog of Video Segments, with each being related to its Lesson weblog entry?

    That’s correct! Sorry for not explaining it better.

  • #11 / May 26, 2008 5:59pm

    Ian Cook

    93 posts

    So I’m attempting to implement your suggestion, but for some reason no child entries are showing up under their parent’s entries.

    Here’s the code I’m using:

    <?xml version="1.0" encoding="utf-8" ?>
    <root>
    {exp:weblog:entries weblog="training" orderby="lessonsort" sort="asc"}
        <menuItems lessonID="{lessonid}" lessonText="Lesson {lessonid}:" lessonTitle="{title}">
        {related_entries id="trainingsegments"}
            <Items itemText="{title} - ({segmentlength} min)" mediaPath="rtmp://streamingservername:80/FLVPlaybackExample/videos/{flvpath}">
        {/related_entries}
    </menuItems>
    {/exp:weblog:entries}
    </root>

    The ‘training’ weblog contains the parent entries.
    The ‘trainingsegments’ weblog contains the children.

    I’ve added a custom relationship field to ‘trainingsegments’ which points at the ‘training’ weblog.

    I’ve added an entry to ‘trainingsegments’. In the relationship field dropdown I’ve selected the parent entry from ‘training’.

    Unfortunately when I view the template, there are no child entries displayed. The Items xml tag doesn’t even appear, which leads me to believe that something is wrong with the way I added the {related_entries id="trainingsegments"} tag.

    Did I do something obviously wrong? ( I’m hoping so… 😉 )

  • #12 / May 26, 2008 6:04pm

    Ian Cook

    93 posts

    Oh, ok.. I’m seeing that the related_entries id .. “must contain the Field Name of the custom field that contains the relationship.”

    When creating the custom field for the relationship, I called it ‘lesson’. Then I updated the code to :

    {related_entries id="lesson"}

    ... but, still nothing. I get the feeling that I don’t quite get it.

  • #13 / May 26, 2008 6:53pm

    ExpressionEngineer

    148 posts

    You’re almost there; I believe you’ll need to use the reverse_related_entries tag
    instead of the related_entries tag, have a look in the docs for more info.

  • #14 / May 26, 2008 7:10pm

    Ian Cook

    93 posts

    That did it. I think it’s all clicking into place now… Thanks a lot! 😊

  • #15 / May 26, 2008 11:42pm

    Ian Cook

    93 posts

    I’m sure this’ll come as a big shock, but ... I have another question. 😊

    I have everything set up and working as discussed above.

    My question is, in the following code…

    {exp:weblog:entriesweblog="training" category_group="2" style="linear"}
    
       In this weblog entries block this variable would get filled in: {lessonid}
    
    {reverse_related_entries orderby="itemsort"}
    
       ... but now that I'm in the reverse_related_entries block this no longer gets filled in: {lessonid}
    
    {/reverse_related_entries}
    {/exp:weblog:entries}

    ... how can I get access to a custom field in the parent entry called {lessonid} from inside a reverse_related_entries block?

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

ExpressionEngine News!

#eecms, #events, #releases