problems with new articles from NSP Newsh Show Pro GK4

Support forum dedicated to free and advanced Joomla content presentation module with various layout options and data sources support.
GK User
Tue Apr 02, 2013 10:41 pm
I have problems with NSP module in Joomla 3.0. It doesn't show the article from K2 component (1 category - 2 articles) created today. I can see only article from yesterday. Can be related this to time offset? Please, help me! sorry for my english.
User avatar
Junior Boarder

GK User
Wed Apr 03, 2013 8:29 am
Yes, probably it is related with your server configuration. Please make sure that the timezone is correct and then change offset inside module settings to -12 or +12 value.
User avatar
Platinum Boarder

GK User
Wed Apr 03, 2013 1:43 pm
this solution (+/- 12) doesn't help...
User avatar
Junior Boarder

GK User
Wed Apr 03, 2013 4:16 pm
Any idea? time zone in my Joomla is 'Warsaw'. All cache plugins I disabled.
User avatar
Junior Boarder

GK User
Wed Apr 03, 2013 4:29 pm
OK, done. I changed the file helper.php:)
User avatar
Junior Boarder

GK User
Thu Apr 04, 2013 10:41 am
It is one of the way but what amount of offset you need ? The -12/+12 was not working ? Maybe it was cache issue and you need to wait until you can see results.
User avatar
Platinum Boarder

GK User
Wed Apr 10, 2013 11:42 am
bkrztuk wrote:It is one of the way but what amount of offset you need ? The -12/+12 was not working ? Maybe it was cache issue and you need to wait until you can see results.


It's not a cache issue. I've done a little search in the code and i've found this:
Code: Select all
AND ( content.publish_up = '.$db->Quote($nullDate).' OR content.publish_up <= '.$db->Quote($now).' )

at line 174 in /mod_news_pro_gk4/gk_classes/gk.source.joomla.php

At this line the $db->Quote($now) has a not really specific $now variable, which is assigned here:
Code: Select all
$date = JFactory::getDate($config['time_offset'].' hour '.date('Y-m-d', strtotime('now')));
$now  = $date->toSql();

at line 106, 107 in the same PHP

You can see the problem at the date() function. Hour:Minute:Second format is not set. Joomla publish articles with a timestamp not just a date. Change date('Y-m-d', strtotime('now')) to date('Y-m-d H:i:s', strtotime('now')) and the articles will appear.
User avatar
Fresh Boarder

GK User
Wed Apr 24, 2013 9:04 am
Thanks for the information. We've already fixed this is packages.
User avatar
Platinum Boarder

GK User
Fri Apr 26, 2013 9:29 pm
i have the same problem, i made the changes of otto.spang, and not work :/ but is weird because in some modules display the articles right (the most news) and in others no.

sorry for my english.
User avatar
Fresh Boarder

GK User
Sat Apr 27, 2013 11:57 am
My solution is for displaying articles from Joomla, not from K2. That's an other story. Don't know what's the problem with it. Use old school Joomla articles. ;)
User avatar
Fresh Boarder

GK User
Mon Apr 29, 2013 10:02 am
Please check the publish date for the article and make sure that you use lates NSP version which is available here >> https://github.com/GavickPro/News-Show-Pro-GK5
User avatar
Platinum Boarder


cron