[ Index ]

MailPress 7.1

[ Index ]     [ Classes ]     [ Functions ]     [ Variables ]     [ Constants ]     [ Statistics ]    

title

Body

[close]

/mp-includes/class/ -> MP_Stat.class.php (source)

   1  <?php
   2  class MP_Stat
   3  {
   4  	function __construct( $stype, $slib, $scount ) 
   5      {
   6          global $wpdb;
   7          $sdate   = date( 'Y-m-d' );
   8          $results = $wpdb->query( $wpdb->prepare( "UPDATE $wpdb->mp_stats SET scount=scount+$scount WHERE sdate = %s AND stype = %s AND slib = %s;", $sdate, $stype, $slib ) );
   9          if ( $scount < 1 ) return;
  10          if ( !$results ) $wpdb->insert( $wpdb->mp_stats, compact( 'sdate', 'stype', 'slib', 'scount' ) );
  11      }
  12  }


Generated: Mon Mar 11 18:33:33 2019 Cross-referenced by PHPXref 0.7.1