Hi,
I'm trying to customize the layout of a template I'm using (blog template) in both item and category views.
For some reason (that I can't really understand…) it seems that this template is not that… flexible !
In my case, I'd like the images of my article to show first, then the title and after that, the tags.
So here is what I've done :
I went to site/components/com_flexicontent/templates/blog/
and copied those files :
category_items_html5.php
item_html5.php
and pasted those copies in
site/templates/mytemplate/html/com_flexicontent/templates/blog
So that I can work on these files and override the original files.
Can someone confirm this is the right way ?
Then, within the code, I tried to target the several elements I need to modify in these php files.
Which is not easy for me cause I'm not that familiar with php.
My actual problem is in the item_html5.php file. I can't find a way to separate the image and the tags.
I think that both the image and the tags are treated in the following paragraph :
Code:
<?php if (isset($item->positions['beforedescription'])) : ?>
<!-- BOF beforedescription block -->
<div class="customblock beforedescription group">
<?php foreach ($item->positions['beforedescription'] as $field) : ?>
<span class="element <?php echo $columnmode; ?>">
<?php if ($field->label) : ?>
<span class="flexi label field_<?php echo $field->name; ?>"><?php echo $field->label; ?></span>
<?php endif; ?>
<span class="flexi value field_<?php echo $field->name; ?><?php echo !$field->label ? ' nolabel ' : ''; ?>"><?php echo $field->display; ?></span>
</span>
<?php endforeach; ?>
</div>
<!-- EOF beforedescription block -->
<?php endif; ?>
Can someone tell me how to treat the image and the tags separately, starting from here ?
This would be highly appreciated !