diff --git a/jq_img_lazy_load.php b/jq_img_lazy_load.php index a509d37..e77f061 100644 --- a/jq_img_lazy_load.php +++ b/jq_img_lazy_load.php @@ -4,13 +4,13 @@ Plugin Name: jQuery lazy load plugin Plugin URI: http://github.com/ayn/wp-jquery-lazy-load/ Description: a quick and dirty wordpress plugin to enable image lazy loading. - Version: v0.3 + Version: v0.4 Author: Andrew Ng Author URI: http://blog.andrewng.com */ function jquery_lazy_load_headers() { - $plugin_path = plugins_url('/wp-jquery-lazy-load/'); + $plugin_path = plugins_url('/', __FILE__); $lazy_url = $plugin_path . 'javascripts/jquery.lazyload.pack.js'; $jq_url = $plugin_path . 'javascripts/jquery.js'; wp_deregister_script('jquery'); @@ -19,7 +19,7 @@ function jquery_lazy_load_headers() { } function jquery_lazy_load_ready() { - $placeholdergif = plugins_url('/wp-jquery-lazy-load/images/grey.gif'); + $placeholdergif = plugins_url('images/grey.gif', __FILE__); echo << $(document).ready(function($){ diff --git a/readme.txt b/readme.txt index 2c0e84f..fe82c86 100644 --- a/readme.txt +++ b/readme.txt @@ -1,9 +1,9 @@ === jQuery Image Lazy Load WP === Contributors: ayn Tags: images, jquery, javascript, optimization -Requires at least: 2.0 -Tested up to: 2.7.x -Stable tag: 0.3 +Requires at least: 2.8 +Tested up to: 2.8.x +Stable tag: 0.4 add jquery lazy loading to images