Plugin Directory

Changeset 639767


Ignore:
Timestamp:
12/15/2012 06:40:01 PM (13 years ago)
Author:
aviaxis
Message:

compatibility

File:
1 edited

Legend:

Unmodified
Added
Removed
  • traffic-counter-widget/trunk/wp-traffic-counter-widget.php

    r443646 r639767  
    55Description: Counts the number of visitors of your blog and shows the traffic information on a widget
    66Author: Bogdan Nicolaescu
    7 Version: 2.0.2
     7Version: 2.1.2
    88Author URI: http://www.pixme.org/
    99*/
     
    134134      $sql .= ' AND IS_BOT <> 1';
    135135
    136   return number_format_i18n($wpdb->get_var($wpdb->prepare($sql)));
     136  return number_format_i18n($wpdb->get_var($sql));
    137137}
    138138
     
    156156       $ip = $_SERVER['REMOTE_ADDR'];
    157157
    158   $user_count = $wpdb->get_var($wpdb->prepare("SELECT COUNT(*) FROM $table_name where ".time()." - Time <= 3 and IP = '".$ip."'"));
     158  $user_count = $wpdb->get_var("SELECT COUNT(*) FROM $table_name where ".time()." - Time <= 3 and IP = '".$ip."'");
    159159
    160160  if (!$user_count) {
     
    227227   $table_name = $wpdb->prefix . "wtc_log";
    228228
    229    $user_count = $wpdb->get_var($wpdb->prepare("SELECT COUNT(*) FROM $table_name where ".time()." - Time <= 1000 and IP = '".$ip."'"));
     229   $user_count = $wpdb->get_var("SELECT COUNT(*) FROM $table_name where ".time()." - Time <= 1000 and IP = '".$ip."'");
    230230
    231231   return $user_count == 0;
Note: See TracChangeset for help on using the changeset viewer.