Forums / Setup & design / Lastest News Box of the site Two Garden Court Chambers

Lastest News Box of the site Two Garden Court Chambers

Author Message

Leandro Alves

Wednesday 01 September 2004 2:40:21 pm

Hi

What Can I do to display the class article in my template <b>randomly</b> like the <b>"Lastest News Box"</b> in the site Two Garden Court Chambers (http://www.2gardenct.law.co.uk)

Does it is JavaScript?

Please, help me if you can...

Thank's a lot.
Leandro

Paul Borgermans

Wednesday 01 September 2004 3:04:37 pm

http://ez.no/community/contributions/template_plugins/vertical_latest_news_scroller

-paul

This should go into the FAQ apparently, please do so

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

steve walker

Thursday 02 September 2004 4:23:58 am

Leandro,

To get the news shown to be random you need to implement the 'shuffle' randomiser contribution.

If you get it working in the scroller fetch could you submit the code please.

Thanks, Steve.

http://www.oneworldmarket.co.uk

Leandro Alves

Thursday 02 September 2004 6:15:07 am

Thanks All for the replies.

Steve, I don't want to implement "random" articles... I want my result equal the Two Garden site. I'm sorry my english...

So I tried what the Paul posted above, but it didn't work fine.

I followed all instrutions in http://ez.no/community/contributions/template_plugins/vertical_latest_news_scroller and http://www.ez.no/community/forum/developer/how_to_remove_the_last_character_of_a_loop but the news doesn't appear in my site.

The IE return the error:

Line: 352
Characters: 77
Error: Constant of sequence didn't conclude
Code: 0

I am using IE version 6.0.

With this Could you give me some tip?

Thanks a lot!
Leandro

steve walker

Friday 03 September 2004 12:33:30 am

Leandro,

I think this is because the Ez data generated for the scroller contents isnt formatting itself correctly.

The working code for scrolled data should look like:

v_content=[
['/index.php/2gt/latest_news/two_garden_court_chambers_welcomes_two_new_practitioners__1',
'Michael Paget joins Two Garden Court Chambers','_parent'],             
['/index.php/2gt/latest_news/two_garden_court_chambers_welcomes_two_new_practitioners','Marc Willers joins Two Garden Court Chambers','_parent'],             
['/index.php/2gt/news','Get all the latest news from Two Garden Court here...','_parent']
];

The important bit to note is that there is no comma on the last line "['/index.php/2gt/news','Get all the latest news from Two Garden Court here...','_parent']" and currently this is a static line which in the downloaded template that closes off this loop correctly (though I want to rework it with Pauls delimiter suggestion).

Steve.

http://www.oneworldmarket.co.uk