aboutsummaryrefslogtreecommitdiffstats
path: root/admin/include
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--admin/include/functions.php13
-rw-r--r--admin/include/functions_metadata.php22
2 files changed, 10 insertions, 25 deletions
diff --git a/admin/include/functions.php b/admin/include/functions.php
index 9855f8278..a60d44b75 100644
--- a/admin/include/functions.php
+++ b/admin/include/functions.php
@@ -2,10 +2,10 @@
// +-----------------------------------------------------------------------+
// | PhpWebGallery - a PHP based picture gallery |
// | Copyright (C) 2002-2003 Pierrick LE GALL - pierrick@phpwebgallery.net |
-// | Copyright (C) 2003-2006 PhpWebGallery Team - http://phpwebgallery.net |
+// | Copyright (C) 2003-2007 PhpWebGallery Team - http://phpwebgallery.net |
// +-----------------------------------------------------------------------+
// | branch : BSF (Best So Far)
-// | file : $RCSfile$
+// | file : $Id$
// | last update : $Date$
// | last modifier : $Author$
// | revision : $Revision$
@@ -1689,15 +1689,6 @@ function tag_id_from_tag_name($tag_name)
return $page['tag_id_from_tag_name_cache'][$tag_name];
}
- if (function_exists('mysql_real_escape_string'))
- {
- $tag_name = mysql_real_escape_string($tag_name);
- }
- else
- {
- $tag_name = mysql_escape_string($tag_name);
- }
-
// does the tag already exists?
$query = '
SELECT id
diff --git a/admin/include/functions_metadata.php b/admin/include/functions_metadata.php
index f468ab7e3..f26184ce7 100644
--- a/admin/include/functions_metadata.php
+++ b/admin/include/functions_metadata.php
@@ -2,10 +2,10 @@
// +-----------------------------------------------------------------------+
// | PhpWebGallery - a PHP based picture gallery |
// | Copyright (C) 2002-2003 Pierrick LE GALL - pierrick@phpwebgallery.net |
-// | Copyright (C) 2003-2005 PhpWebGallery Team - http://phpwebgallery.net |
+// | Copyright (C) 2003-2007 PhpWebGallery Team - http://phpwebgallery.net |
// +-----------------------------------------------------------------------+
// | branch : BSF (Best So Far)
-// | file : $RCSfile$
+// | file : $Id$
// | last update : $Date$
// | last modifier : $Author$
// | revision : $Revision$
@@ -65,6 +65,11 @@ function get_sync_iptc_data($file)
);
}
+ foreach ($iptc as $pwg_key => $value)
+ {
+ $iptc[$pwg_key] = addslashes($iptc[$pwg_key]);
+ }
+
return $iptc;
}
@@ -83,6 +88,7 @@ function get_sync_exif_data($file)
$exif[$pwg_key] = $matches[1].'-'.$matches[2].'-'.$matches[3];
}
}
+ $exif[$pwg_key] = addslashes($exif[$pwg_key]);
}
return $exif;
@@ -115,14 +121,6 @@ function update_metadata($files)
if ($conf['use_exif'])
{
$exif = get_sync_exif_data($file);
-
- if (count($exif) > 0)
- {
- foreach (array_keys($exif) as $key)
- {
- $data[$key] = addslashes($exif[$key]);
- }
- }
}
if ($conf['use_iptc'])
@@ -147,10 +145,6 @@ function update_metadata($files)
);
}
}
- else
- {
- $data[$key] = addslashes($iptc[$key]);
- }
}
}
}