| 1 |
<?php |
<?php |
| 2 |
// $Id: imagepicker.module,v 1.2.2.3 2008/06/07 14:17:02 hutch Exp $ |
// $Id: imagepicker.module,v 1.2.2.4 2008/06/14 23:39:16 hutch Exp $ |
| 3 |
// $Name: DRUPAL-5 $ |
// $Name: $ |
| 4 |
|
|
| 5 |
/** |
/** |
| 6 |
* @file |
* @file |
| 258 |
$nextimgid = db_next_id('{imagepicker}_img_id'); |
$nextimgid = db_next_id('{imagepicker}_img_id'); |
| 259 |
$title = htmlspecialchars($form_values['title']); |
$title = htmlspecialchars($form_values['title']); |
| 260 |
$description = htmlspecialchars($form_values['description']); |
$description = htmlspecialchars($form_values['description']); |
| 261 |
if (db_query("INSERT INTO {imagepicker} (img_id, uid, img_name, img_title, img_description) VALUES ('%d', '%d', '%s', '%s', '%s')", array($nextimgid, $user->uid, $file, $title, $description))) { |
if (db_query("INSERT INTO {imagepicker} (uid, img_name, img_title, img_description) VALUES ('%d', '%s', '%s', '%s')", array($user->uid, $file, $title, $description))) { |
| 262 |
drupal_set_message(t('Image was successfully uploaded.')); |
drupal_set_message(t('Image was successfully uploaded.')); |
| 263 |
drupal_goto('imagepicker/browse/'. $nextimgid); |
drupal_goto('imagepicker/browse/'. $nextimgid); |
| 264 |
} |
} |