setup itemContainer width in k2 item category list

Start-up Joomla template with amazing CSS3 animated icons, price tables and parallax effect background.
Rate this topic: Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.1.00 out of 6 based on 1 vote(s)
GK User
Sat Nov 23, 2013 7:29 pm
Reply with quote
Report this post
Hello,

in a category listing view (k2) i am trying to setup width (%). By default it is set to 33.2% but it does not suit my needs since i am not using aside position ... i want to set it at 30.2% for styling better my k2 items! Check screenshot!

How can i set itemContainer width manually? (override.css is not working in this case)
User avatar
Junior Boarder

GK User
Sat Nov 23, 2013 7:47 pm
Reply with quote
Report this post
Ok,

in case somebody requires something similar:

html\com_k2\templates\default\category.php

change:

<div class="itemContainer<?php echo $lastContainer; ?>"<?php echo (count($this->secondary)==1) ? '' : ' style="width:'.(number_format(100/$this->params->get('num_secondary_columns'), 1)-0.1).'%;"'; ?>>

to whichever suits you, e.g.

<div class="itemContainer<?php echo $lastContainer; ?>"<?php echo (count($this->secondary)==1) ? '' : ' style="width:'.(number_format(100/$this->params->get('num_secondary_columns'), 1)-3.1).'%;"'; ?>>
User avatar
Junior Boarder


cron