aboutsummaryrefslogtreecommitdiffstats
path: root/admin/include/functions_metadata.php
diff options
context:
space:
mode:
authorz0rglub <z0rglub@piwigo.org>2004-10-30 15:42:29 +0000
committerz0rglub <z0rglub@piwigo.org>2004-10-30 15:42:29 +0000
commit7cd9b65e3299fb8bc6a83e65f89fcecca62f3178 (patch)
treee068090892b16db654a2bf0c2886b65eaf44a14f /admin/include/functions_metadata.php
parent3730c810f254267ab1fb49f4cad55866e780ad6e (diff)
- function mysql_query replaced by pwg_query : the same with debugging
features - by default, DEBUG is set to 0 (off) git-svn-id: http://piwigo.org/svn/trunk@587 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r--admin/include/functions_metadata.php20
1 files changed, 10 insertions, 10 deletions
diff --git a/admin/include/functions_metadata.php b/admin/include/functions_metadata.php
index 60a826774..42f34c4ff 100644
--- a/admin/include/functions_metadata.php
+++ b/admin/include/functions_metadata.php
@@ -128,7 +128,7 @@ function update_metadata($files)
// depending on the MySQL version, we use the multi table update or N
// update queries
$query = 'SELECT VERSION() AS version;';
- $row = mysql_fetch_array(mysql_query($query));
+ $row = mysql_fetch_array(pwg_query($query));
if (version_compare($row['version'],'4.0.4') < 0)
{
// MySQL is prior to version 4.0.4, multi table update feature is not
@@ -151,7 +151,7 @@ UPDATE '.IMAGES_TABLE.'
WHERE id = '.$insert['id'].'
;';
// echo '<pre>'.$query.'</pre>';
- mysql_query($query);
+ pwg_query($query);
}
}
else
@@ -160,7 +160,7 @@ UPDATE '.IMAGES_TABLE.'
$query = '
DESCRIBE '.IMAGES_TABLE.'
;';
- $result = mysql_query($query);
+ $result = pwg_query($query);
$columns = array();
while ($row = mysql_fetch_array($result))
{
@@ -187,7 +187,7 @@ PRIMARY KEY (id)
)
;';
// echo '<pre>'.$query.'</pre>';
- mysql_query($query);
+ pwg_query($query);
// inserts all found pictures
$query = '
INSERT INTO '.IMAGE_METADATA_TABLE.'
@@ -224,7 +224,7 @@ INSERT INTO '.IMAGE_METADATA_TABLE.'
$query.= '
;';
// echo '<pre>'.$query.'</pre>';
- mysql_query($query);
+ pwg_query($query);
// update of images table by joining with temporary table
$query = '
UPDATE '.IMAGES_TABLE.' AS images, '.IMAGE_METADATA_TABLE.' as metadata
@@ -235,7 +235,7 @@ UPDATE '.IMAGES_TABLE.' AS images, '.IMAGE_METADATA_TABLE.' as metadata
WHERE images.id = metadata.id
;';
echo '<pre>'.$query.'</pre>';
- mysql_query($query);
+ pwg_query($query);
}
}
}
@@ -258,7 +258,7 @@ SELECT id, dir
FROM '.CATEGORIES_TABLE.'
WHERE dir IS NOT NULL
;';
- $result = mysql_query($query);
+ $result = pwg_query($query);
$cat_dirs = array();
while ($row = mysql_fetch_array($result))
{
@@ -291,7 +291,7 @@ SELECT id, uppercats
}
$query.= '
;';
- $result = mysql_query($query);
+ $result = pwg_query($query);
while ($row = mysql_fetch_array($result))
{
$uppercats_array[$row['id']] = $row['uppercats'];
@@ -302,7 +302,7 @@ SELECT galleries_url
FROM '.SITES_TABLE.'
WHERE id = 1
';
- $row = mysql_fetch_array(mysql_query($query));
+ $row = mysql_fetch_array(pwg_query($query));
$basedir = $row['galleries_url'];
// filling $cat_fulldirs
@@ -328,7 +328,7 @@ SELECT id, file, storage_category_id
}
$query.= '
;';
- $result = mysql_query($query);
+ $result = pwg_query($query);
while ($row = mysql_fetch_array($result))
{
$files[$row['id']]