WordPress.org

Ready to get started?Download WordPress

Forums

wordTube
put js in cache (wordtube Version: 2.4.0) (1 post)

  1. zetoun17
    Member
    Posted 2 years ago #

    hello
    here 2 small improvements easy to include in your next version:
    file :statistic.js.php (put js in cache)

    header('Content-Type: text/javascript; charset=utf-8', true);
    header("Last-Modified: " . gmdate("D, d M Y H:i:s",filemtime(__FILE__)) . " GMT");
    header('Cache-Control: public, max-age=29030400');

    file : wordtube.class.php (put wordtube in footer)

    function integrate_js() {
    
    			wp_enqueue_script('swfobject', WORDTUBE_URLPATH . 'javascript/swfobject.js', false, '2.1');
                wp_enqueue_script('wordtube_stats', get_option ('siteurl') . '/index.php?wordtube-js=true', array('jquery'), '2.0',true);
    	}

    thx for your plugin
    regards

    http://wordpress.org/extend/plugins/wordtube/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic