Changeset 45270

Show
Ignore:
Timestamp:
05/11/08 17:48:14 (2 months ago)
Author:
misterbisson
Message:

alpha

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • bsuite/trunk/core.php

    r45267 r45270  
    606606                  $s['sess_bl'] = $se['bl']; 
    607607 
    608                   if ( false === $wpdb->insert( $this->hits_sessions, $s )) 
    609                         return new WP_Error('db_insert_error', __('Could not insert term into the database'), $wpdb->last_error); 
     608                  if ( false === $wpdb->insert( $this->hits_sessions, $s )){ 
     609                        new WP_Error('db_insert_error', __('Could not insert session into the database'), $wpdb->last_error); 
     610                        return( FALSE ); 
     611                  } 
    610612                  $session_id = (int) $wpdb->insert_id; 
    611613            } 
     
    660662                  if( ( $referers = implode( $this->get_search_terms( $hit->in_from ), ' ') ) && ( 0 < strlen( $referers ))) { 
    661663                        $term_id = $this->bstat_insert_term( $referers ); 
    662 echo "<h2>$referers</h2>"; 
    663 print_r( $term_id ); 
    664664                        $searchwords[] = "($object_id, $object_type, $term_id, 1, '$hit->in_time')"; 
    665665                  } 
     
    707707                  update_option( 'bsuite_doing_migration_status', $status ); 
    708708            } 
    709 /* 
     709 
    710710            if( count( $res )){ 
    711711                  if ( false === $wpdb->query( "DELETE FROM $this->hits_incoming WHERE in_time < '$since' ORDER BY in_time ASC LIMIT ". count( $res ) .';')) 
     
    714714                        $wpdb->query( "OPTIMIZE TABLE $this->hits_incoming;"); 
    715715            } 
    716 */ 
     716 
    717717/*           
    718718            $posts = $wpdb->get_results("SELECT object_id, AVG(hit_count) AS hit_avg