The Support Forums will be in read-only mode for a scheduled maintenance window on 01 September 2016 14:00 UTC - 20:00 UTC. More information.

Skitter Slideshow
[resolved] Fatal Errors with 3.2.1 Multisite, Audit Trail and Skitter Slider ... (2 posts)

  1. chuckingit
    Posted 5 years ago #

    i posted a similar fyi on the Audit Trail plugin forum but thought i should also mention it here ->

    just upgraded a WP multisite network to version 3.2.1 and got the following fatal errors below when trying to activate Audit Trail 1.9 after having just activated WP Skitter Slider 1.3 ..

    error message =

    Fatal error: Cannot redeclare pr() (previously declared in
    /home/site-name/public_html/wp-content/plugins/audit-trail/plugin.php:574) in
    /home/site-name/public_html/wp-content/plugins/wp-skitter-slideshow/wp-skitter-slideshow.php on line 266

    ugh ... any help certainly appreciated ... cordially, chuck scott


  2. chuckingit
    Posted 5 years ago #

    Okay - answering my own post here ... turns out that both Audit Trail and WP Skitter Slider are using similar debug function that appears to be suggested from CakePHP (info below) ...

    since i am not using Audit Trail's debug feature, i commented those lines out and that seemed to work and now both plugins co-exist ...

    it does remind me about some of the threads at Justin Tadlock's ThemeHybrid site that suggest importance of plugin authors to define their functions by pre-appending said functions with unique plugin text ... e.g., had Audit Trail author defined his pr function as audit_pr and Skitter used skitter_pr to define his, then the likelyhood of conflict would be greatly decreased but i digress ...

    cordially, chuck scott

    Info on Work Out

    1. code from skitter that PHP complained as fatal error circa lines 258 thru 266 =

     * Debug arrays and others
    function pr ($array)
    	echo '<pre>';
    	echo '</pre>';

    2. code from Audit Trail that php complained about circa lines 574 thru 582 (note i commented out the function) =

     * Debug helper, borrowed from CakePHP, that displays a print_r inside <pre></pre> tags
     * @param string $name Name of your plugin.  Is used to determine the plugin locale domain
     * @param string $base Directory containing the plugin's 'view' files.
     * @return void
    if ( !function_exists( 'pr' ) ) {
    	function pr( $thing ) {
    		echo '<pre>';
    		print_r( $thing );
    		echo '</pre>';

    - fin -

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic