WordPress.org

Ready to get started?Download WordPress

Forums

WP Supersized
[resolved] How can I turn off the script on my mobile theme? (3 posts)

  1. pdstudio
    Member
    Posted 2 years ago #

    Hy!

    I use WPTouch on my site and the Supersized script loads into the mobile theme, but its not okay, so I want to disable it.
    Is there any way to do it with modifying my theme or anyway?
    Thank you forwards for help.

    http://wordpress.org/extend/plugins/wp-supersized/

  2. pdstudio
    Member
    Posted 2 years ago #

    Okay, I added to my mobile themes function file these lines:

    function my_deregister_javascript() {
    	wp_deregister_script( 'WPSupersized_standard' );
    	wp_deregister_script( 'WPSupersized_theme_js' );
    	wp_deregister_script( 'WPSupersized_core' );
    }

    and everything is solved.
    If someone else needs.

  3. pawel.z
    Member
    Posted 2 years ago #

    This code work smooth for me, after some small changes:

    if (!is_admin()) {
    	function site_init() {
    		wp_deregister_script( 'WPSupersized_standard' );
    		wp_deregister_script( 'WPSupersized_theme_js' );
    		wp_deregister_script( 'WPSupersized_core' );
    		}
    	add_action('init', 'site_init');
    }

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic