10 years ago
Topic

Hi,

I would like to know how can i have a search & list type, from menu link, getting the results in random order?

Here is the link: http://yogabrasilia.org/novidades/locais-de-pratica?search=locais_de_pratica_de_yoga&task=search

It is aways in publish date order, i would like to have random order...

I know how to do that with a module, but is it possible to do in a search & list that is not a module, but a menu link?

Thanks

Get a Book for SEBLOD
4229 Posts
Kadministrator
10 years ago
1
Level 1

Hi,

unfortunatelly there is currently no such option in component, only in module

10 years ago
0
Level 2

Hi Klas, ok! Thanks for fast reply!

If some day the component have this feature i would like to know, i will mark as solved for now :)

I would like to say thanks for the one hour support, solved some issues that i think i could not do alone!

Was very professional and flexible solution, for automatic metadescription! Very good code... Thanks a lot!

Best wishes.

10 years ago
1
Level 1

Hi again Klas,

Do you think i could open a tracker as a feature request about this topic?

Thanks

4229 Posts
Kadministrator
10 years ago
0
Level 2

Hi,

I'm glad support helped :) 

For feature request - yes, go ahead, this is why we have it.

4229 Posts
Kadministrator
10 years ago
0
Level 1

Hi,

I was browsing products page when I got this idea:

If you combine random option http://www.seblod.com/products/13683 with search ordering field http://www.seblod.com/products/919 it should result in random order.

10 years ago
1
Level 1

Hi Klas,

Thanks for checking :)

I tried that:

Created the field search orthering, with some option:

art_id asc , art_id desc , art_title asc , art_title des

variation -> filter

tested and field working ok.

later i set the field to live value random, but didnt work... 

what more shoul i do?

Thanks

97 Posts
Anjo
10 years ago
0
Level 2

Hi diogowernik,

For random order I add the following code within a custom template "tpl_basic_list":

shuffle($items);

Never tested this in a native seblod template like seb_table or seb_blog. However you could try hacking the template by adding this code straight after the line

$items=$cck->getItems();

shuffle($items);

If it works you could then create your own template based on the one you are using (copy and rename it) then add the hack there so updates do not override. here's a link on how to copy a seblod template and rename it and install

http://www.seblod.com/v2/forum/101-General-Discussions/34072-Missing-files-and-some-help-on-template-creation.html#34957

Hope this might help for now

Anjo

10 years ago
0
Level 1

Thanks anjo, i will try that :)

Get a VIP membership