Vous n'êtes pas identifié(e).
- Contributions : Récentes | Sans réponse
Pages : 1
#1 11/02/2012 17:09:32
- deckool
- Membre
- Inscription : 11/02/2012
- Messages : 4
Categories in home
Hello, i want to tell you that pluxml is amazing. I have some problems using this forum, i know a little french but i also use google translate for it.
Ok, my question is if i can in a way make categories to appear in the loop like them articles appear on my homepage. i really disn't found the code for that.
My site is www.parfait.ro if you are intersted to view the template.
Thanks
Hors ligne
#2 11/02/2012 17:29:43
Re : Categories in home
Hello deckool
See categorie.php file in your theme folder.
Pluxopolis un site sur PluXml, mais pas seulement...
Twitter: @pluxopolis
-----
Mon site perso
Mon compte twitter
Hors ligne
#3 11/02/2012 18:10:26
- deckool
- Membre
- Inscription : 11/02/2012
- Messages : 4
Re : Categories in home
Thanks, i looked there but it looks like the home.
What i want is to find what the shortscripts are for category to use them on the loop.
I have this lines
<?php while($plxShow->plxMotor->plxRecord_arts->loop()): ?>
<h2><?php $plxShow->artTitle('link'); ?></h2>
<div class="image"><div class="pcaption"><?php $plxShow->artTitle(); ?></div><img src="../script/timthumb.php?src=../data/images/<?php $plxShow->artTitle(); ?>/<?php echo rand(1,3);?>.jpg&a=c&h=120&w=690&zc=1" alt="">
</div>
<div class="art-chapo"><?php $plxShow->artChapo(); ?></div>
there i want to change the plxRecord_arts with something to take them categories and recursively artTitle with catsTitle i guess and so on...
I also looked in the core for what i have to put in there but i didn't figured it!
Thanks
Hors ligne
#4 11/02/2012 18:29:34
Re : Categories in home
I'm not sure to understand what you want.
If you add this following line in the loop (in home.php) it will display the name of the category
<?php $plxShow->artCat(); ?>Is it what you want to do ?
Pluxopolis un site sur PluXml, mais pas seulement...
Twitter: @pluxopolis
-----
Mon site perso
Mon compte twitter
Hors ligne
#5 11/02/2012 18:49:53
- deckool
- Membre
- Inscription : 11/02/2012
- Messages : 4
Re : Categories in home
Ok, so right now i made a hybrid with what i found on the sidebar.php.
I paste the code it works just fine but the <?php echo rand(1,3);?> won't work!
Here's the code - you also can see it live on my website.
Anyway if it's another option to make this please tell me, or if u know how can i make the php rand to work inside that.(i like few rotating images)
<?php $plxShow->catList('','<h2 id="#cat_id" class="#cat_status"><a href="#cat_url" title="#cat_name">#cat_name</a></h2>
<div class="image"><div class="pcaption">#cat_name</div><img src="../script/timthumb.php?src=../data/images/#cat_name/1.jpg&a=c&h=120&w=690&zc=1" alt="">
</div>
'); ?>
Hors ligne
#6 11/02/2012 19:21:08
- deckool
- Membre
- Inscription : 11/02/2012
- Messages : 4
Re : Categories in home
actually not any php call won't work in that
Hors ligne
Pages : 1