Support » Plugin: Google Analytics for WordPress by MonsterInsights » [Plugin: Google Analytics for WordPress] Coding issues and E_STRICT spam

  • Using PHP 5.3 or 5.4 will generate (tons of) log entries for invalid static access of non-static properties for GA_Filter.

    Quick fix: all methods of GA_Filter are *only* used in static context and should be declared with static public.

    Some minor issues:
    for googleanalytics.php
    line 24: plugin_dir_path( __FILE__ ) does add a trailing slash. Not needed to do so twice.

    line 1510: $gaf = new GA_Filter(); is not used by the plugin.
    There is no need for it, as the interface is static already.

    wp-gdata.php:
    For consistence either omit all public in public function or always use it.

    If time permits I’ll add a more complete coding review later this year (basic consistency, common error and performance checkup. maybe something about missing source documentation too).

    http://wordpress.org/extend/plugins/google-analytics-for-wordpress/

  • The topic ‘[Plugin: Google Analytics for WordPress] Coding issues and E_STRICT spam’ is closed to new replies.