CSS Styles and Array for Search Results

  • kaya
  • Autore della discussione
  • Offline
  • Nuovo Utente
  • Nuovo Utente
Di più
11 Anni 8 Mesi fa #1248 da kaya
CSS Styles and Array for Search Results è stato creato da kaya
Hello,

working with CP, I have two problems, I don't know how to solve.

I have two CP search modules (Dates/Teacher).
For the first one, I need a result-order by "earlierst first" (as it is now), but all
teacher names have to be arranged alphabetical.
I found this one:
solidsystem.it/how-to-and-tutorials/166-...stom-properties.html
but I don't know, what to change in alt.php. Or is there another way?

Next question is:

Is it possible to create to different css styles for THE RESULTS.
I tried "Module class suffix" but it only works for the module itself, not for the results.
I would like to show the titel in "Teacher"-results and hide it in "Dates"-results(or modify it).
I changed cp_title (display:none) but then both titles are not shown.

Thank you for your support.

kaya

Si prega Accesso o Crea un account a partecipare alla conversazione.

Di più
11 Anni 8 Mesi fa #1250 da andrea_4g
Risposta da andrea_4g al topic CSS Styles and Array for Search Results
Results ordering is set at component level only. There are no parameters at module level to set different orderings for results.

The "tutorial" you are referring to, helps solving the second issue about formatting.
solidsystem.it/how-to-and-tutorials/166-...stom-properties.html

You need to have 2 different templates, for example:
- default.php (for dates)
- teachers.php

You then give a different, harcoded, CSS class to the second template. E.g.
change line 377 of teacher.php from:
Code:
<div class="blog<?php echo $this->params->get('pageclass_sfx');?>">
to
Code:
<div class="blog teachers">

Last step: configure each cp_search module to use a different template when dispalaying results setting the relevant 'Template' parameter in module config.

Si prega Accesso o Crea un account a partecipare alla conversazione.

  • kaya
  • Autore della discussione
  • Offline
  • Nuovo Utente
  • Nuovo Utente
Di più
11 Anni 8 Mesi fa #1251 da kaya
Risposta da kaya al topic CSS Styles and Array for Search Results
Thankx, it works.

Si prega Accesso o Crea un account a partecipare alla conversazione.

Tempo creazione pagina: 0.159 secondi