-
AuthorPosts
-
sobe Friend
sobe
- Join date:
- June 2010
- Posts:
- 249
- Downloads:
- 13
- Uploads:
- 20
- Thanks:
- 32
- Thanked:
- 4 times in 1 posts
October 12, 2014 at 5:16 am #201998There seems to be a problem with the blog layout when 1 Leading Article is selected followed by a few Intro Articles displayed with two columns. The first article works fine, but the 2nd article seems completely misaligned (somewhat similar to the 1st article, yet off to the side), and then the other articles appear in two columns properly.
I just re-installed the quickstart template (J version 3.3) and chose to modify the “J! Blog” menu to have 1 Leading Article, 4 Intro Articles, and 2 Columns and the problem is easily replicable.
How do I get the page to have simply 1 leading article, and then the rest in two columns?
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
October 13, 2014 at 8:24 am #552703Hi sobe,
You can try with my tweak here:
– Open file: templatesja_fixelhtmlcom_contentcategoryblog.php
– At approx line 80, you will see this snippet of code:
<?php
$key = ($key - $leadingcount) + 1;
$rowcount = (((int) $key - 1) % (int) $this->columns) + 1;
$row = $counter / $this->columns;if ($rowcount == 1) : ?>
<div class="items-row cols-<?php echo (int) $this->columns;?> <?php echo 'row-'.$row; ?> row-fluid">
Replace it with:
<?php
$key = ($key - $leadingcount) + 1;
$rowcount = (((int) $key - 1) % (int) $this->columns) + 1;
$row = $counter / $this->columns;if ($rowcount != 1) : ?>
<div class="items-row cols-<?php echo (int) $this->columns;?> <?php echo 'row-'.$row; ?> row-fluid">
Hope it helps.
sobe Friendsobe
- Join date:
- June 2010
- Posts:
- 249
- Downloads:
- 13
- Uploads:
- 20
- Thanks:
- 32
- Thanked:
- 4 times in 1 posts
October 13, 2014 at 10:25 am #552737Hi Saguaros,
You’re tweak did resolve the second article issue, but it also created another problem. Now, for some reason the two column layout is skipping the third article and leaving an empty space where that article should be.Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
October 14, 2014 at 1:29 am #552804You can PM me admin and ftp credentials of your site, I will take a look.
sobe Friendsobe
- Join date:
- June 2010
- Posts:
- 249
- Downloads:
- 13
- Uploads:
- 20
- Thanks:
- 32
- Thanked:
- 4 times in 1 posts
October 15, 2014 at 7:42 pm #553136Hi Saguaros,
Any progress in helping to resolve the issue?Thanks again for your help.
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
October 16, 2014 at 2:28 am #553160Hi sobe,
I replace this:
<?php if (!empty($this->intro_items)) : ?>
<?php foreach ($this->intro_items as $key => &$item) : ?>
<?php
$key = ($key - $leadingcount) + 1;
$rowcount = (((int) $key - 1) % (int) $this->columns) + 1;
$row = $counter / $this->columns;if ($rowcount == 1) : ?>
With:
<?php if (!empty($this->intro_items)) : ?>
<?php foreach ($this->intro_items as $key => &$item) : ?>
<?php $rowcount = ((int) $counter % (int) $this->columns) + 1; ?>
<?php if ($rowcount == 1) : ?>
<?php $row = $counter / $this->columns; ?>
I also back up the old file so that you can see the difference.
Have a nice day
Saguaros1 user says Thank You to Saguaros for this useful post
-
AuthorPosts
This topic contains 6 replies, has 2 voices, and was last updated by Saguaros 10 years, 1 month ago.
We moved to new unified forum. Please post all new support queries in our New Forum