peut on trier en fonction des champs specifiques

  • Anonymous
  • Topic Author
  • Visitor
  • Visitor
14 years 3 months ago #19960 by Anonymous
Bonjour,

FLEXIContent permet-il d'afficher la liste d'articles appartenant à une catégorie (à partir d'un clic sur élément d'un menu), triés en fonction des champs spécifiques qu'on a crée avexc FLEXIContent ?

Merci.

Please Log in or Create an account to join the conversation.

  • Anonymous
  • Topic Author
  • Visitor
  • Visitor
14 years 3 months ago #19962 by Anonymous
Replied by Anonymous on topic peut on trier en fonction des champs specifiques
Auto réponse : Oui, et c'est génial :)
Il faut créer autant de catégories que l'on veut de manière de trier les articles, et définir la façon de trier dans ces catégories.
Puis créer un lien de menu FLEXIContent / Catégorie

Je suis néanmoins bloqué par un ultime problème :

Comment créer un lien depuis nos articles listés vers les articles eux mêmes ? Est-ce possible de rendre un champ en mode vue catégorie cliquable ?

Please Log in or Create an account to join the conversation.

More
14 years 3 months ago #19964 by micker
si tu as utiliser un template blog ->dans ta categorie utilise l'option lire la suite

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

Please Log in or Create an account to join the conversation.

  • Anonymous
  • Topic Author
  • Visitor
  • Visitor
14 years 3 months ago #19978 by Anonymous
Replied by Anonymous on topic peut on trier en fonction des champs specifiques
Salut merci pour ta prompte réponse.

J'utilise des templates dupliqués de "default", car la présentation sous forme de tableau est ce qui convient le mieux.

Mais du coup tu m'as mis sur la piste, je peux avoir le lien en activant "Titre des contenus" et "Titre cliquable".

Avant j'affichais le titre avec le champ du noyau "Title", ce qui présente l'avantage de pouvoir choisir où positionner ce champ. Serait-il possible de le rendre cliquable ou encore mieux de rendre n'importe lequel des champs cliquables avec un lien vers l'article ?

Please Log in or Create an account to join the conversation.

More
14 years 3 months ago #19986 by ggppdk
This is not supported unless you make some customization in your template.

e.g. use a PHP if to add the link for field that is in some column e.g. column 4

Regards


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!

Please Log in or Create an account to join the conversation.

  • Anonymous
  • Topic Author
  • Visitor
  • Visitor
14 years 3 months ago #19992 by Anonymous
Replied by Anonymous on topic peut on trier en fonction des champs specifiques
ok.

May I ask where to find the file to modify ?
Or maybe you know some tutorial that explains the file structures in joomla / FLEXIContent ? (where to find what)

Anyway, thanks a lot for this mighty extension.

Please Log in or Create an account to join the conversation.

More
14 years 3 months ago #19994 by ggppdk
Ok, I will give you the code you need but first note that:

The template files are meant to be editable by developers to customize them according to their needs, end users are meant to use only the graphical template editor to add remove fields.

For a template tutorial , please see here:
extensions.netassopro.com/9-tutorials


Better not to alter 'default' template files

So
1. go to template manager and duplicate the template, e.g. name the new template 'default1'
2. open file: components/com_flexicontent/templates/default1/category_items.php

find code:
Code:
<!-- BOF item fields --> <?php foreach ($columns as $name => $label) : ?> <td><?php echo isset($item->positions['table']->{$name}->display) ? $item->positions['table']->{$name}->display : ''; ?></td> <?php endforeach; ?> <!-- EOF item fields -->

and replace with:
Code:
<!-- BOF item fields --> <?php $linkcols=array(4,6); $colcnt = 0; if ( $this->params->get('show_title', 1) ) $colcnt++; ?> <?php foreach ($columns as $name => $label) : ?> <td> <?php $colcnt++; if (in_array($colcnt, $linkcols)) echo "<a href='".JRoute::_(FlexicontentHelperRoute::getItemRoute($item->slug, $item->categoryslug))."'>"; echo isset($item->positions['table']->{$name}->display) ? $item->positions['table']->{$name}->display : ''; if (in_array($colcnt, $linkcols)) echo ""; ?> </td> <?php endforeach; ?> <!-- EOF item fields -->

CHANGE line:
$linkcols=array(4,6);

to put the columns you want to link to the item, above i have 4 and 6, you could leave only 4 or 6 :
$linkcols=array(4);

Do not put columns that have already links in them e.g. favourites or some other field that has url or javascript links in it.

If you need to do further modifications please read the tutorials.


Regards


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline
Save