Intégrer une position de module dans un template category.ph

More
12 years 4 months ago #26857 by Hableur
Bonjour,

je cherche à intégrer une position dans le fichier category.php.

La position in_page est crée dans le templateDetails.xml et fonctionne avec {loadposition in_page} dans un article standard.

Dans le fichier category.php, {loadposition in_page} ne fonctionne pas.
Code:
<jdoc:include type="modules" name="in_page" style="xhtml" />
non plus.

Quelqu'un a-t-il la soluce.

Merci

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

More
12 years 4 months ago #26859 by ggppdk
You could use a system plugin to do this.

System plugin can replace text everywhere:
e.g.
Modules Anywhere
extensions.joomla.org/extensions ... clude/6402


-- 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...

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

More
12 years 4 months ago #26876 by Hableur
Thanks ggppdk,

unfortunately, i tried to install Modules Anywhere, but it seems to have a problem in zip file.

I think i'll use javascript, it would be lighter...

A lot of sun in Crete ?

Here, in Bretagne, it's raining since weeks :cry:

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

More
12 years 4 months ago #26879 by ggppdk
Yes weather is too hot here 27-37 Celsius, and there only sun for months, no clouds ...

you can use some other load module System plugin, or trigger the loadposition Joomla 's Content plugin:
Code:
<?php $mobj = new stdClass(); $mobj->title = $this->item->title; $mobj->text = "{loadposition mypos_name}"; $mobj->slug = $this->item->slug; $mobj->sectionid = $this->item->sectionid; $mobj->catid = $this->item->catid; $mobj->catslug = $this->item->categoryslug; $mobj->id = $this->item->id; $mobj->state = $this->item->state; $dispatcher = &JDispatcher::getInstance(); JPluginHelper::importPlugin('content'); $limitstart = 0; if (!FLEXI_J16GE) { $results = $dispatcher->trigger('onPrepareContent', array (&$mobj, &$this->params, $limitstart)); } else { $results = $dispatcher->trigger('onContentPrepare', array ('com_content.article', &$mobj, &$this->params, $limitstart)); } echo $mobj->text; ?>

Please note i have not tested the code above, so correct and also replace $this->item with e.g. any item variable you have available ... or maybe use empty strings '', and for parameters maybe create $myparams = new JParameter();

again i say i have not tested this code and you must correct it

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...

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

More
12 years 4 months ago #26888 by micker
desoler je capte pas .. installe module anywhere (si tu a un soucis installe le par l'opion tmp de joomla) puis active ce plugin et autorise le pour la description dans la catégorie
apres tu pourras charger ton module sans avoir a faire de position ...
non ?

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.

More
12 years 4 months ago #26899 by Hableur
@ggppdk

Too much sun in Crete, a too much rain and coldness in France. What a pity !

I don't try your code because i don't understand what it is for.

Would it interprate "{loadposition mypos_name}" in the html code producted by category.php ?

Why using $this->item->title and so on (item->catid...) in category.php in template flexi ?

Thanks

@Micker

Bonjour Micker, tu es du coté ensoleillé, toi, veinard !

En ce qui concerne Modules Anywhere, je ne te cache pas que je rechigne à installer un plugin dont le fichier zip n'est pas fonctionnel. Si il ne l'est pas, qu'y-t-il comme autre anomalie ? C'est un site en production, je n'ai pas le droit à l'erreur.

D'autre part, installer un plugin rien que pour mettre mon module mod-search dans ma page flexi, je trouve ça lourd.

Enfin, la place de ce module n'est pas prévue dans la description de la catégorie, mais du côté de l'affichage des filtres.

A côté de ça, créer une position en display:none dans le template, y mettre mon module et transférer le contenu en jQuery dans une div produite par category.php me paraît bien simple.

Bien cordialement

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

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.813 seconds
Save
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