Advertisement
Guest User

Untitled

a guest
Jun 3rd, 2010
1,231
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.25 KB | None | 0 0
  1. $stmt= array( 'array of statements' );
  2. $query= 'INSERT INTO yourtable (col1,col2,col3) VALUES ';
  3. foreach( $stmt AS $k => $v ) {
  4.   if ( $k > 0 ) $query.= ', ';
  5.   $query.= '(' .$v. ')'; // NOTE: you'll have to change to suit
  6. }
  7. $r= mysql_query($query);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement