Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Bricolage: users

associating multiple related stories to a given story

 

 

Bricolage users RSS feed   Index | Next | Previous | View Threaded


mallah.rajesh at gmail

Apr 7, 2008, 4:44 AM

Post #1 of 5 (265 views)
Permalink
associating multiple related stories to a given story

Hi,


I would want to know how i can associate multiple stories as
related story to a given story.

Eg in Story:
http://news.bbc.co.uk/2/hi/uk_news/england/london/7333980.stm
There are multiple stories under "SEE ALSO" in the RHS column
can anyone please tell me if "related story" is meant for this
kind of use ?


regds
mallah.


phillip at communitybandwidth

Apr 7, 2008, 9:37 AM

Post #2 of 5 (251 views)
Permalink
Re: associating multiple related stories to a given story [In reply to]

Hi there Mallah,

That's exactly the kind of thing that a "related story" sub-element
can be used for.

You'll need a related_story.mc template to handle the display of your
related stories.

Best,

Phillip.

On 7-Apr-08, at 7:44 AM, Rajesh Kumar Mallah wrote:
> Hi,
>
>
> I would want to know how i can associate multiple stories as
> related story to a given story.
>
> Eg in Story:
> http://news.bbc.co.uk/2/hi/uk_news/england/london/7333980.stm
> There are multiple stories under "SEE ALSO" in the RHS column
> can anyone please tell me if "related story" is meant for this
> kind of use ?
>
>
> regds
> mallah.

--
Phillip Smith,
Simplifier of Technology
Community Bandwidth
http://www.communitybandwidth.ca

Don't miss the Social Tech Training:
www.marsdd.com/socialtechtraining
June 22-24, 2008 in Toronto


mallah.rajesh at gmail

Apr 8, 2008, 3:31 AM

Post #3 of 5 (250 views)
Permalink
Re: associating multiple related stories to a given story [In reply to]

Hi,

The "Related Stories" and "Related Story" Element Types were useful.
However i could not find related_story.mc file (did you mean story_list.mc?)

Hence i did below in my template.
I hope it is appropriate and efficient.

regds
mallah.

--- see_also.mc ------

<%perl>
my $container = $element->get_container( 'related_stories' ) ;
return unless defined $container;
my @stories = map { $_->get_related_story() }
$container->get_elements('related_story');
return unless (@stories);
</%perl>
<br>
<b>SEE ALSO</b>
<ul>
% foreach my $s (@stories) {
<li> <a href="<% $s->get_uri() %>"><% $s->get_name() %></a></li>
%}
</ul>

---------- end -----------------
On Mon, Apr 7, 2008 at 10:07 PM, Phillip Smith
<phillip[at]communitybandwidth.ca> wrote:
>
> Hi there Mallah,
>
> That's exactly the kind of thing that a "related story" sub-element can be
> used for.
>
> You'll need a related_story.mc template to handle the display of your
> related stories.
>
> Best,
>
> Phillip.
>
>
>
> On 7-Apr-08, at 7:44 AM, Rajesh Kumar Mallah wrote:
>
> > Hi,
> >
> >
> > I would want to know how i can associate multiple stories as
> > related story to a given story.
> >
> > Eg in Story:
> > http://news.bbc.co.uk/2/hi/uk_news/england/london/7333980.stm
> > There are multiple stories under "SEE ALSO" in the RHS column
> > can anyone please tell me if "related story" is meant for this
> > kind of use ?
> >
> >
> > regds
> > mallah.
> >
>
> --
> Phillip Smith,
> Simplifier of Technology
> Community Bandwidth
> http://www.communitybandwidth.ca
>
> Don't miss the Social Tech Training:
> www.marsdd.com/socialtechtraining
> June 22-24, 2008 in Toronto
>
>


phillip at communitybandwidth

Apr 9, 2008, 7:26 AM

Post #4 of 5 (245 views)
Permalink
Re: associating multiple related stories to a given story [In reply to]

Hi ho,

On 8-Apr-08, at 6:31 AM, Rajesh Kumar Mallah wrote:
> Hi,
>
> The "Related Stories" and "Related Story" Element Types were useful.
> However i could not find related_story.mc file (did you mean
> story_list.mc?)


Nope. Meant the related_story.mc template. :-) If it's not there,
you probably haven't created it yet. ;-)


> Hence i did below in my template.
> I hope it is appropriate and efficient.


Looks efficient to me. Doesn't Perl translate to "many ways to get
things done?"

Phillip.


>
>
> regds
> mallah.
>
> --- see_also.mc ------
>
> <%perl>
> my $container = $element->get_container( 'related_stories' ) ;
> return unless defined $container;
> my @stories = map { $_->get_related_story() }
> $container->get_elements('related_story');
> return unless (@stories);
> </%perl>
> <br>
> <b>SEE ALSO</b>
> <ul>
> % foreach my $s (@stories) {
> <li> <a href="<% $s->get_uri() %>"><% $s->get_name() %></a></li>
> %}
> </ul>
>
> ---------- end -----------------
> On Mon, Apr 7, 2008 at 10:07 PM, Phillip Smith
> <phillip[at]communitybandwidth.ca> wrote:
>>
>> Hi there Mallah,
>>
>> That's exactly the kind of thing that a "related story" sub-element
>> can be
>> used for.
>>
>> You'll need a related_story.mc template to handle the display of your
>> related stories.
>>
>> Best,
>>
>> Phillip.
>>
>>
>>
>> On 7-Apr-08, at 7:44 AM, Rajesh Kumar Mallah wrote:
>>
>>> Hi,
>>>
>>>
>>> I would want to know how i can associate multiple stories as
>>> related story to a given story.
>>>
>>> Eg in Story:
>>> http://news.bbc.co.uk/2/hi/uk_news/england/london/7333980.stm
>>> There are multiple stories under "SEE ALSO" in the RHS column
>>> can anyone please tell me if "related story" is meant for this
>>> kind of use ?
>>>
>>>
>>> regds
>>> mallah.
>>>
>>
>> --
>> Phillip Smith,
>> Simplifier of Technology
>> Community Bandwidth
>> http://www.communitybandwidth.ca
>>
>> Don't miss the Social Tech Training:
>> www.marsdd.com/socialtechtraining
>> June 22-24, 2008 in Toronto
>>
>>

--
Phillip Smith,
Simplifier of Technology
Community Bandwidth
http://www.communitybandwidth.ca


bharder at methodlogic

Apr 9, 2008, 9:32 AM

Post #5 of 5 (243 views)
Permalink
Re: associating multiple related stories to a given story [In reply to]

On Wed, Apr 09, 2008 at 10:26:03AM -0400, Phillip Smith wrote:
>
> Hi ho,
>
> On 8-Apr-08, at 6:31 AM, Rajesh Kumar Mallah wrote:
> >Hi,
> >
> >The "Related Stories" and "Related Story" Element Types were useful.
> >However i could not find related_story.mc file (did you mean
> >story_list.mc?)
>
>
> Nope. Meant the related_story.mc template. :-) If it's not there,
> you probably haven't created it yet. ;-)

? related_story.mc is distributed w/ my copy of 1.10.3

> >Hence i did below in my template.

For the record, here's a copy of the distributed copy of "related_story.mc" I have:

<!-- Start "Related Story" -->
% my $rel_story = $element->get_related_story;
<b>Title:</b>&nbsp;
<% $element->get_value('alternate_title') || $rel_story->get_title %><br />
<b>Teaser:</b>&nbsp;
<% $element->get_value('alternate_teaser') ||
$rel_story->get_description %><br />
<!-- End "Related Story" -->


> >I hope it is appropriate and efficient.
>
>
> Looks efficient to me. Doesn't Perl translate to "many ways to get
> things done?"
>
> Phillip.
>
>
> >
> >
> >regds
> >mallah.
> >
> >--- see_also.mc ------
> >
> ><%perl>
> >my $container = $element->get_container( 'related_stories' ) ;
> >return unless defined $container;
> >my @stories = map { $_->get_related_story() }
> >$container->get_elements('related_story');
> >return unless (@stories);
> ></%perl>
> ><br>
> ><b>SEE ALSO</b>
> ><ul>
> >% foreach my $s (@stories) {
> ><li> <a href="<% $s->get_uri() %>"><% $s->get_name() %></a></li>
> >%}
> ></ul>
> >
> >---------- end -----------------
> >On Mon, Apr 7, 2008 at 10:07 PM, Phillip Smith
> ><phillip[at]communitybandwidth.ca> wrote:
> >>
> >>Hi there Mallah,
> >>
> >>That's exactly the kind of thing that a "related story" sub-element
> >>can be
> >>used for.
> >>
> >>You'll need a related_story.mc template to handle the display of your
> >>related stories.
> >>
> >>Best,
> >>
> >>Phillip.
> >>
> >>
> >>
> >>On 7-Apr-08, at 7:44 AM, Rajesh Kumar Mallah wrote:
> >>
> >>>Hi,
> >>>
> >>>
> >>>I would want to know how i can associate multiple stories as
> >>>related story to a given story.
> >>>
> >>>Eg in Story:
> >>>http://news.bbc.co.uk/2/hi/uk_news/england/london/7333980.stm
> >>>There are multiple stories under "SEE ALSO" in the RHS column
> >>>can anyone please tell me if "related story" is meant for this
> >>>kind of use ?
> >>>
> >>>
> >>>regds
> >>>mallah.
> >>>
> >>
> >>--
> >>Phillip Smith,
> >>Simplifier of Technology
> >>Community Bandwidth
> >>http://www.communitybandwidth.ca
> >>
> >>Don't miss the Social Tech Training:
> >>www.marsdd.com/socialtechtraining
> >>June 22-24, 2008 in Toronto
> >>
> >>
>
> --
> Phillip Smith,
> Simplifier of Technology
> Community Bandwidth
> http://www.communitybandwidth.ca
>
>

--

Brad Harder,
Method Digital Logic
http://www.methodlogic.net

Bricolage users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.