Broken Link Checker - Version 0.4.12

Version Description

Download this release

Release Info

Developer whiteshadow
Plugin Icon 128x128 Broken Link Checker
Version 0.4.12
Comparing to
See all releases

Code changes from version 0.4.10 to 0.4.12

Files changed (2) hide show
  1. broken-link-checker.php +7 -4
  2. readme.txt +2 -2
broken-link-checker.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Broken Link Checker
4
  Plugin URI: http://w-shadow.com/blog/2007/08/05/broken-link-checker-for-wordpress/
5
  Description: Checks your posts for broken links and missing images and notifies you on the dashboard if any are found.
6
- Version: 0.4.10
7
  Author: Janis Elsts
8
  Author URI: http://w-shadow.com/blog/
9
  */
@@ -23,7 +23,7 @@ class ws_broken_link_checker {
23
  var $options_name='wsblc_options';
24
  var $postdata_name;
25
  var $linkdata_name;
26
- var $version='0.4.10';
27
  var $myfile='';
28
  var $myfolder='';
29
  var $mybasename='';
@@ -246,8 +246,11 @@ class ws_broken_link_checker {
246
 
247
  $ch = curl_init();
248
  curl_setopt($ch, CURLOPT_URL, $url);
 
249
  curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)');
250
- //curl_setopt($ch, CURLOPT_USERAGENT, 'WordPress/Broken Link Checker (bot)');
 
 
251
  curl_setopt($ch, CURLOPT_RETURNTRANSFER,1);
252
 
253
  @curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
@@ -422,7 +425,7 @@ class ws_broken_link_checker {
422
 
423
  function post_deleted($post_id){
424
  global $wpdb;
425
- $sql="DELETE FROM ".$this->linksdata_name." WHERE post_id=$post_id";
426
  $wpdb->query($sql);
427
  $sql="DELETE FROM ".$this->postdata_name." WHERE post_id=$post_id";
428
  $wpdb->query($sql);
3
  Plugin Name: Broken Link Checker
4
  Plugin URI: http://w-shadow.com/blog/2007/08/05/broken-link-checker-for-wordpress/
5
  Description: Checks your posts for broken links and missing images and notifies you on the dashboard if any are found.
6
+ Version: 0.4.12
7
  Author: Janis Elsts
8
  Author URI: http://w-shadow.com/blog/
9
  */
23
  var $options_name='wsblc_options';
24
  var $postdata_name;
25
  var $linkdata_name;
26
+ var $version='0.4.12';
27
  var $myfile='';
28
  var $myfolder='';
29
  var $mybasename='';
246
 
247
  $ch = curl_init();
248
  curl_setopt($ch, CURLOPT_URL, $url);
249
+ //Masquerade as Internet explorer
250
  curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)');
251
+ //Add a semi-plausible referer header to avoid tripping up some bot traps
252
+ curl_setopt($ch, CURLOPT_REFERER, get_option('home'));
253
+
254
  curl_setopt($ch, CURLOPT_RETURNTRANSFER,1);
255
 
256
  @curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
425
 
426
  function post_deleted($post_id){
427
  global $wpdb;
428
+ $sql="DELETE FROM ".$this->linkdata_name." WHERE post_id=$post_id";
429
  $wpdb->query($sql);
430
  $sql="DELETE FROM ".$this->postdata_name." WHERE post_id=$post_id";
431
  $wpdb->query($sql);
readme.txt CHANGED
@@ -2,8 +2,8 @@
2
  Contributors: whiteshadow
3
  Tags: links, broken, maintenance
4
  Requires at least: 2.0.2
5
- Tested up to: 2.6.3
6
- Stable tag: 0.4.10
7
 
8
  This plugin will check your posts for broken links and missing images in background and notify you on the dashboard if any are found.
9
 
2
  Contributors: whiteshadow
3
  Tags: links, broken, maintenance
4
  Requires at least: 2.0.2
5
+ Tested up to: 2.7.1
6
+ Stable tag: 0.4.12
7
 
8
  This plugin will check your posts for broken links and missing images in background and notify you on the dashboard if any are found.
9