Home Forums Plugin Support WP User Frontend Pro wp_deregister if is home

This topic is: not resolved

This topic contains 8 replies, has 2 voices, and was last updated by  Tareq Hasan 5 years, 11 months ago.

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #5751

    zellermaniac
    Participant
    Post count: 40

    Speed up Page.
    It´s not necessary. wpuf css and javascript in every page.

    I want to deregister all.

    Example: If is home i need no plupload.

    I want to deregister all css and js wpuf.

    What´s the best way.

    – It´s possible to degegister all wpuf or musst i show an deregister every file.

    How can I do that?

    Only if is page. register wpuf.

    #5758

    Tareq Hasan
    Keymaster
    Post count: 2831

    Download the latest plugin, it only loads scripts/styles only to specific pages that uses only WP User Frontend.

    #5836

    zellermaniac
    Participant
    Post count: 40

    I Update:-)

    – German language file
    – CSS
    – Changes upload.js

    How can I Override? ChildPlugin? Is there an Solution.

    Now.

    -plugin
    – wp-user-frontend-pro
    – wp-user-frontend-pro – 2.15
    – wp-user-frontend-pro – 2.14

    I copy manualy.

    You forget? home

    #5841

    Tareq Hasan
    Keymaster
    Post count: 2831

    Can you be more detailed? As you needed, it doesn't load the plugin js/css in every pages, only loads where it requires.

    #5847

    zellermaniac
    Participant
    Post count: 40

    You forgot.

    #5848

    zellermaniac
    Participant
    Post count: 40

    `
    type='text/javascript' src='http://maps.google.com/maps/api/js?sensor=true&ver=3.5.2'>

    #5849

    zellermaniac
    Participant
    Post count: 40

    maps/api/js?sensor=true&ver=3.5.2

    #5852

    zellermaniac
    Participant
    Post count: 40
    
       /**
         * Enqueues Styles and Scripts when the shortcodes are used only
         *
         * @uses has_shortcode()
         * @since 0.2
         */
        function enqueue_scripts() {
            $path = plugins_url( '', __FILE__ );
    
    
    
         $scheme = is_ssl() ? 'https' : 'http';
            wp_enqueue_script( 'google-maps', $scheme . '://maps.google.com/maps/api/js?sensor=true' );
    

    Is there any reason, why it is outside the if wpuf_has_shortcode ?

    #5853

    Tareq Hasan
    Keymaster
    Post count: 2831

    Yes, there are reasons. If you are using map shortcode, google maps script needs everywhere in your site.

Viewing 9 posts - 1 through 9 (of 9 total)

The topic ‘wp_deregister if is home’ is closed to new replies.