PHP older version issue -> fatal error - on behalf of Jude

Issues and Feedbacks related to Smooth Slider should be discussed in this forum. You can post a question related to the plugin so that our developers and other Wordpress experts can answer you on ASAP.
Share |
Loading...

PHP older version issue -> fatal error - on behalf of Jude

Postby tejaswini » Fri Oct 09, 2009 12:11 pm

Congratulations for your plugin that I discovered 3 days ago.

But with this new release, I’ve a problem when activating the plugin (2.0)

“Plugin could not be activated because it triggered a fatal error.”

Parse error: syntax error, unexpected T_OBJECT_OPERATOR, expecting ',' or ';' in /home/sites/web26/html/diva/wp-content/plugins/smooth-slider/smooth-slider.php on line 1394
tejaswini
 
Posts: 271
Joined: Wed Aug 12, 2009 1:05 pm

Re: PHP older version issue -> fatal error - on behalf of Jude

Postby tejaswini » Fri Oct 09, 2009 12:20 pm

Hi Jude,

I guess your server is using older version of PHP that does not support some new object functions. But do not worry, just you need to do a bit of change in the plugin code, may e the issue would get resolved
Go to your admin panel => Plugins => Editor => on the right top select Smooth Slider => open smooth-slider.php => Find the below code (near the bottom of the file, line no 1392 - 1395):-
Code: Select all
     if ( in_array($post->ID, $slider_arr) ) {
        $count++;
        echo '<tr' . ($count % 2 ? ' class="alternate"' : '') . '><td><strong>' . $post->post_title . '</strong></td><td>By ' . get_userdata($post->post_author)->display_name . '</td><td>' . date('l, F j. Y',strtotime($post->post_date)) . '</td><td><input type="checkbox" name="slider_posts[' . $post->ID . ']" value="1" /></td></tr>';
     }

Replace it completely by
Code: Select all
     if ( in_array($post->ID, $slider_arr) ) {
        $count++;
        $sslider_author = get_userdata($post->post_author);
        $sslider_author_dname = $sslider_author->display_name;
        echo '<tr' . ($count % 2 ? ' class="alternate"' : '') . '><td><strong>' . $post->post_title . '</strong></td><td>By ' . $sslider_author_dname . '</td><td>' . date('l, F j. Y',strtotime($post->post_date)) . '</td><td><input type="checkbox" name="slider_posts[' . $post->ID . ']" value="1" /></td></tr>';
     }

Take care that you replace only the above code, and do not mess up with other code like "}" and so on.

Please post me back in case it does not work or you have an issue with changing the code. Thanks for your patience.

Regards,
tejaswini
 
Posts: 271
Joined: Wed Aug 12, 2009 1:05 pm

Re: PHP older version issue -> fatal error - on behalf of Jude

Postby ikepigott » Mon Oct 19, 2009 4:55 pm

I was having the same issue with the same exact error, and replacing this code didn't seem to change it.

It still would not activate.
ikepigott
 
Posts: 1
Joined: Mon Oct 19, 2009 4:46 pm

Re: PHP older version issue -> fatal error - on behalf of Jude

Postby tejaswini » Mon Oct 19, 2009 6:56 pm

Hi ikepigott,

The issue is due to older version of PHP. Are you using PHP 4, then first of all try to upgrade to PHP 5. The above solution for the issue is perfectly working, it worked for Jude. Still, if there is any issue in upgrading or replacing the code or if the issue lingers back, post me back. I will debug more into it. Hope the slider works on your site.
Thanks for your patience,
Regards,
tejaswini
 
Posts: 271
Joined: Wed Aug 12, 2009 1:05 pm

Re: PHP older version issue -> fatal error - on behalf of Jude

Postby mdehart1 » Wed Oct 28, 2009 5:30 pm

You're plugin looks amazing, thanks for all the hard work and good support.

I'm running Wordpress MU 2.8.4a.

I was having a similar error as posted earlier:
Parse error: syntax error, unexpected T_OBJECT_OPERATOR, expecting ',' or ';' in /homepages/15/d297682599/htdocs/keypa/wordpressMU/wp-content/plugins/smooth-slider/smooth-slider.php on line 1394

I changed the code, tried to reactivate and my plugins page reloaded blank. I renamed the plugin folder to disable the plugin and my plugins page came back with this message at the top:

Warning: Cannot modify header information - headers already sent by (output started at /homepages/15/d297682599/htdocs/keypa/wordpressMU/wp-admin/admin-header.php:18) in /homepages/15/d297682599/htdocs/keypa/wordpressMU/wp-includes/pluggable.php on line 865

Any suggestions or thoughts would be awesome.

Thanks!

Mike
mdehart1
 
Posts: 5
Joined: Wed Oct 28, 2009 5:09 pm

Re: PHP older version issue -> fatal error - on behalf of Jude

Postby mdehart1 » Thu Oct 29, 2009 4:26 pm

I forgot to say in the original post that I'm running PHP5 :)
mdehart1
 
Posts: 5
Joined: Wed Oct 28, 2009 5:09 pm

Re: PHP older version issue -> fatal error - on behalf of Jude

Postby mdehart1 » Thu Oct 29, 2009 6:01 pm

Got it working! Discovered that Smooth Slider and Google Sitemap don't play nice together.
mdehart1
 
Posts: 5
Joined: Wed Oct 28, 2009 5:09 pm


Share |

Return to Smooth Slider

Who is online

Users browsing this forum: No registered users and 2 guests