Error message after PHP update

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
Fri Jan 17, 2014 4:54 pm
Reply with quote
Report this post
After my hosting provider updated their PHP version from 5.3.10 to 5.5.7 I get a whole lot of error messages on my site.

For example:

Warning: Missing argument 2 for GKTemplateAPI::get(), called in /storage/content/50/119050/lsvk.org/public_html/templates/gk_rockwall/layouts/default.php on line 111 and defined

Notice: Undefined index: one_article_per_category in /storage/content/50/119050/lsvk.org/public_html/modules/mod_news_pro_gk5/data_sources/com_content/model.php on line 180

I have updated to the lastest version of the template, News Show Pro and Joomla 2.5.

How can I fix this?
User avatar
Platinum Boarder

GK User
Fri Jan 17, 2014 6:56 pm
Reply with quote
Report this post
Hello,

In the layouts/default.php file please replace line:

Code: Select all
<?php if(($this->API->get('reg_link', '0') == '1' && $userID == 0) || $this->API->modules('login')) : ?>


with:

Code: Select all
<?php if(($this->API->get('reg_link') == '1' && $userID == 0) || $this->API->modules('login')) : ?>


In the News Show Pro GK5 case please try to resave all module instances.
User avatar
Administrator

GK User
Fri Jan 17, 2014 7:21 pm
Reply with quote
Report this post
The code is already like what I should replace it with.

You can check out the error messages here: http://lsvk.org/

Resaving the modules solved NSP problem!
User avatar
Platinum Boarder

GK User
Fri Jan 17, 2014 7:46 pm
Reply with quote
Report this post
So in this case please open file lib/framework/helper.api.php and please replace:

Code: Select all
public function get($key, $default) {
        return $this->API->params->get($key, $default);
    }


with:

Code: Select all
public function get($key, $default = '') {
        return $this->API->params->get($key, $default);
    }
User avatar
Administrator

GK User
Fri Jan 17, 2014 8:55 pm
Reply with quote
Report this post
Thanks that solved the problem!
User avatar
Platinum Boarder


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