Event items ordering

GK User
Thu Jul 02, 2015 3:38 pm
Hello - I am using Joomla's most recent version.
Here is the page concerned. http://www.novascotiaheritageconference.ca/events/

I cannot get the 2 items showing to sort by oldest first. I have tried changing the Item ordering setting within the "Other layout options" for the 07 Wednesday category but with no luck. It is currently set for Oldest First (by create date)

Any advice would be appreciated. Thanks
User avatar
Junior Boarder

GK User
Fri Jul 03, 2015 10:32 am
From what I see the older is first (08 Thursday) then never (09 Friday).
User avatar
Moderator

GK User
Fri Jul 03, 2015 10:42 am
I need them sorted WITHIN a category. 07 Wednesday is a category. By whatever sorting method, it does not matter but items need to be chronological order within a category.

Cyberek wrote:From what I see the older is first (08 Thursday) then never (09 Friday).
User avatar
Junior Boarder

GK User
Fri Jul 03, 2015 11:47 am
Even if I have to sort them manually, it is necessary to be able to have them in order by their time.

Pipemeister wrote:I need them sorted WITHIN a category. 07 Wednesday is a category. By whatever sorting method, it does not matter but items need to be chronological order within a category.

Cyberek wrote:From what I see the older is first (08 Thursday) then never (09 Friday).
User avatar
Junior Boarder

GK User
Sun Jul 05, 2015 7:13 pm
Is this an unreasonable request, to be able to sort within a category? Is it a bug with K2? A bug with the template? A bug with me?
User avatar
Junior Boarder

GK User
Mon Jul 06, 2015 6:39 pm
1. Please do not bump your questions - it makes you wait longer.
2. Where do I need to click to see this event? Could you please provide link directly to such a page where this issue occurs? I guess it is a problem with settings but I need to see the page (with the problem) first.
User avatar
Moderator

GK User
Mon Jul 06, 2015 7:08 pm
The link was in the original post but here it is again for you: http://www.novascotiaheritageconference.ca/events/. Please see 07 Wednesday as example.

Cyberek wrote:1. Please do not bump your questions - it makes you wait longer.
2. Where do I need to click to see this event? Could you please provide link directly to such a page where this issue occurs? I guess it is a problem with settings but I need to see the page (with the problem) first.
User avatar
Junior Boarder

GK User
Mon Jul 06, 2015 7:12 pm
Ok, now I understand. This is part of the code that is hardcoded into template. I'll ask our devteam how to change it and will write back as soon as I'll get an answer.
User avatar
Moderator

GK User
Mon Jul 06, 2015 7:25 pm
Thank you!

Cyberek wrote:Ok, now I understand. This is part of the code that is hardcoded into template. I'll ask our devteam how to change it and will write back as soon as I'll get an answer.
User avatar
Junior Boarder

GK User
Mon Jul 06, 2015 7:29 pm
Sorry it took so long - I had the information in front of me and I couldn't see it.
User avatar
Moderator

GK User
Tue Jul 07, 2015 4:11 pm
Please send me a PM with:
1. URL to your website
2. login and password of user with admin/super-admin privileges (please create one for me)
3. ftp data (host, user, password)
4. link to this thread
User avatar
Moderator

GK User
Tue Jul 07, 2015 7:11 pm
I cannot get the PM to leave the Outbox.

Cyberek wrote:Please send me a PM with:
1. URL to your website
2. login and password of user with admin/super-admin privileges (please create one for me)
3. ftp data (host, user, password)
4. link to this thread
User avatar
Junior Boarder

GK User
Wed Jul 08, 2015 6:52 am
Not easy change:
templates/gk_events/html/com_k2/templates/events/category.php
In this file you need to find:
Code: Select all
                              <div class="itemList">
                                        <?php if($this->params->get('latestItemsDisplayEffect')=="first"): ?>
                                        <?php foreach ($block->items as $itemCounter=>$item): K2HelperUtilities::setDefaultImage($item, 'latest', $this->params); ?>
                                        <?php if($itemCounter==0): ?>
                                        <?php
                                 $this->item = $item;
                                 echo $this->loadTemplate('item' . ($this->params->get('latestItemsCols') > 1 ? '2' : ''));
                              ?>
                                        <?php else: ?>
                                        <h2 class="itemTitleList">
                                                  <?php if ($item->params->get('latestItemTitleLinked')): ?>
                                                  <a href="<?php echo $item->link; ?>"> <?php echo $item->title; ?> </a>
                                                  <?php else: ?>
                                                  <?php echo $item->title; ?>
                                                  <?php endif; ?>
                                        </h2>
                                        <?php endif; ?>
                                        <?php endforeach; ?>
                                        <?php else: ?>
                                        <?php foreach ($block->items as $item): K2HelperUtilities::setDefaultImage($item, 'latest', $this->params); ?>
                                        <?php
                                    $item->extra_fields = $results[$item->id];
                                    $this->item=$item;
                                    echo $this->loadTemplate('item' . ($this->params->get('latestItemsCols') > 1 ? '2' : ''));
                                 ?>
                                        <?php endforeach; ?>
                                        <?php endif; ?>
                              </div>

and change it to:
Code: Select all
                              <div class="itemList">
                                        <?php if($this->params->get('latestItemsDisplayEffect')=="first"): ?>
                                        <?php foreach ($block->items as $itemCounter=>$item): K2HelperUtilities::setDefaultImage($item, 'latest', $this->params); ?>
                                        <?php if($itemCounter==0): ?>
                                        <?php
                                 $this->item = $item;
                                 echo $this->loadTemplate('item' . ($this->params->get('latestItemsCols') > 1 ? '2' : ''));
                              ?>
                                        <?php else: ?>
                                        <h2 class="itemTitleList">
                                                  <?php if ($item->params->get('latestItemTitleLinked')): ?>
                                                  <a href="<?php echo $item->link; ?>"> <?php echo $item->title; ?> </a>
                                                  <?php else: ?>
                                                  <?php echo $item->title; ?>
                                                  <?php endif; ?>
                                        </h2>
                                        <?php endif; ?>
                                        <?php endforeach; ?>
                                        <?php else: ?>
                                        <?php $itemsList = array_reverse($block->items); ?>
                                        <?php foreach ($itemsList as $item): K2HelperUtilities::setDefaultImage($item, 'latest', $this->params); ?>
                                        <?php
                                    $item->extra_fields = $results[$item->id];
                                    $this->item=$item;
                                    echo $this->loadTemplate('item' . ($this->params->get('latestItemsCols') > 1 ? '2' : ''));
                                 ?>
                                        <?php endforeach; ?>
                                        <?php endif; ?>
                              </div>


The change was made on your server... The instructions are for other users who would search for such solution.
User avatar
Moderator

GK User
Wed Jul 08, 2015 11:07 am
Thank you for your help!
User avatar
Junior Boarder

GK User
Wed Jul 08, 2015 2:35 pm
Is there anything else I can help you with regarding this topic?
User avatar
Moderator

GK User
Thu Jul 09, 2015 9:26 pm
No thank you. I was able to complete my task after your changes. Thanks.
User avatar
Junior Boarder

GK User
Fri Jul 10, 2015 6:30 am
Feel free to post new forum threads if you have any other questions - it allows us to answer faster.
User avatar
Moderator


cron
Remember me
Register New Account
If you are old Gavick user, click HERE for steps to retrieve your account.