Changeset 1863
- Timestamp:
- Feb 27, 2007, 1:32:23 PM (17 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/admin/include/functions.php
r1817 r1863 215 215 { 216 216 global $conf; 217 218 // destruction of the access linked to the user 219 $query = ' 220 DELETE FROM '.USER_ACCESS_TABLE.' 217 $tables = array( 218 // destruction of the access linked to the user 219 USER_ACCESS_TABLE, 220 // destruction of data notification by mail for this user 221 USER_MAIL_NOTIFICATION_TABLE, 222 // destruction of data RSS notification for this user 223 USER_FEED_TABLE, 224 // deletion of calculated permissions linked to the user 225 USER_CACHE_TABLE, 226 // deletion of computed cache data linked to the user 227 USER_CACHE_CATEGORIES_TABLE, 228 // destruction of the group links for this user 229 USER_GROUP_TABLE, 230 // destruction of the favorites associated with the user 231 FAVORITES_TABLE, 232 // destruction of the caddie associated with the user 233 CADDIE_TABLE, 234 // deletion of phpwebgallery specific informations 235 USER_INFOS_TABLE, 236 ); 237 238 foreach ($tables as $table) 239 { 240 $query = ' 241 DELETE FROM '.$table.' 221 242 WHERE user_id = '.$user_id.' 222 243 ;'; 223 pwg_query($query); 224 225 // destruction of data notification by mail for this user 226 $query = ' 227 DELETE FROM '.USER_MAIL_NOTIFICATION_TABLE.' 228 WHERE user_id = '.$user_id.' 229 ;'; 230 pwg_query($query); 231 232 // destruction of data RSS notification for this user 233 $query = ' 234 DELETE FROM '.USER_FEED_TABLE.' 235 WHERE user_id = '.$user_id.' 236 ;'; 237 pwg_query($query); 238 239 // destruction of the group links for this user 240 $query = ' 241 DELETE FROM '.USER_GROUP_TABLE.' 242 WHERE user_id = '.$user_id.' 243 ;'; 244 pwg_query($query); 245 246 // destruction of the favorites associated with the user 247 $query = ' 248 DELETE FROM '.FAVORITES_TABLE.' 249 WHERE user_id = '.$user_id.' 250 ;'; 251 pwg_query($query); 252 253 // deletion of calculated permissions linked to the user 254 $query = ' 255 DELETE FROM '.USER_CACHE_TABLE.' 256 WHERE user_id = '.$user_id.' 257 ;'; 258 pwg_query($query); 259 260 // deletion of computed cache data linked to the user 261 $query = ' 262 DELETE FROM '.USER_CACHE_CATEGORIES_TABLE.' 263 WHERE user_id = '.$user_id.' 264 ;'; 265 pwg_query($query); 266 267 // deletion of phpwebgallery specific informations 268 $query = ' 269 DELETE FROM '.USER_INFOS_TABLE.' 270 WHERE user_id = '.$user_id.' 244 pwg_query($query); 245 } 246 247 // destruction of the user 248 $query = ' 249 DELETE FROM '.SESSIONS_TABLE.' 250 WHERE data LIKE "pwg_uid|i:'.(int)$user_id.';%" 271 251 ;'; 272 252 pwg_query($query); … … 525 505 { 526 506 $first = true; 527 507 528 508 $query = 'SHOW VARIABLES LIKE \'max_allowed_packet\';'; 529 509 list(, $packet_size) = mysql_fetch_row(pwg_query($query)); … … 540 520 $first = true; 541 521 } 542 522 543 523 if ($first) 544 524 { … … 554 534 , '; 555 535 } 556 536 557 537 $query .= '('; 558 538 foreach ($dbfields as $field_id => $dbfield) … … 574 554 $query .= ')'; 575 555 } 576 556 577 557 $query .= ' 578 558 ;'; … … 1942 1922 { 1943 1923 array_push($all_tag_ids, $row['tag_id']); 1944 1924 1945 1925 if (!isset($tags_of[ $row['image_id'] ])) { 1946 1926 $tags_of[ $row['image_id'] ] = array(); 1947 1927 } 1948 1928 1949 1929 array_push( 1950 1930 $tags_of[ $row['image_id'] ], … … 1987 1967 $xml_string.= " <tag>".$tag_name_of[$tag_id]."</tag>\n"; 1988 1968 } 1989 1969 1990 1970 $xml_string.= " </photo>\n"; 1991 1971 } 1992 1972 1993 1973 $xml_string.= '</export>'; 1994 1974 fwrite($fp, $xml_string); … … 2049 2029 'EXTENSIONS' => 'http://'.PHPWG_DOMAIN.'/ext', 2050 2030 ); 2051 if ( isset($lang_info['code']) and 2031 if ( isset($lang_info['code']) and 2052 2032 in_array($lang_info['code'], array('fr','en')) ) 2053 2033 { /* current wiki languages are French or English */ -
trunk/include/ws_protocols/rest_encoder.php
-
Property
svn:keywords
set to
Author Date Id Revision
r1698 r1863 4 4 // | Copyright (C) 2003-2007 PhpWebGallery Team - http://phpwebgallery.net | 5 5 // +-----------------------------------------------------------------------+ 6 // | branch : BSF (Best So Far) 7 // | file : $URL: svn+ssh://rvelices@svn.gna.org/svn/phpwebgallery/trunk/action.php $ 8 // | last update : $Date: 2006-12-21 18:49:12 -0500 (Thu, 21 Dec 2006) $ 9 // | last modifier : $Author: rvelices $ 10 // | revision : $Rev: 1678 $ 6 // | file : $Id$ 7 // | last update : $Date$ 8 // | last modifier : $Author$ 9 // | revision : $Revision$ 11 10 // +-----------------------------------------------------------------------+ 12 11 // | This program is free software; you can redistribute it and/or modify | … … 85 84 $this->_end_prev(false); 86 85 $value = (string)$value; 87 $need_cdata = (strpos($value, "\r")!==false)?true:false; 88 if ($need_cdata) 89 { 90 $this->_output( '<![CDATA[' . $value . ']]>' ); 91 } 92 else 93 { 94 $this->_output( htmlspecialchars( $value ) ); 95 } 86 $this->_output( htmlspecialchars( $value ) ); 87 } 88 89 function write_cdata($value) 90 { 91 $this->_end_prev(false); 92 $value = (string)$value; 93 $this->_output( 94 '<![CDATA[' 95 . str_replace(']]>', ']]>', $value) 96 . ']]>' ); 96 97 } 97 98 … … 164 165 return $ret; 165 166 } 166 167 //parent::flattenResponse($response);168 167 169 168 $this->_writer = new PwgXmlWriter(); -
Property
svn:keywords
set to
Note: See TracChangeset
for help on using the changeset viewer.