backup.php File Reference

Go to the source code of this file.

Functions

 do_backup ($gzip=0)
 _backup_dump_table ($tablename, $key)
 _backup_dump_structure ($tablename)
 _backup_get_field_names ($result, $num_fields)
 _backup_dump_contents ($tablename)
 gzip_PrintFourChars ($Val)
 do_restore ()
 _execute_queries ($sql_query)
 remove_remarks ($sql)
 split_sql_file ($sql)
 _evenNumberOfQuotes ($text)


Function Documentation

_backup_dump_contents ( tablename  ) 

_backup_dump_structure ( tablename  ) 

Definition at line 145 of file backup.php.

References mysql_fetch_array(), and mysql_query().

Referenced by _backup_dump_table().

_backup_dump_table ( tablename,
key 
)

Creates a dump for a single table ($tablename and $key are filled in by array_walk)

Definition at line 132 of file backup.php.

References _backup_dump_contents(), and _backup_dump_structure().

_backup_get_field_names ( result,
num_fields 
)

Returns the field named for the given table in the following format:

(column1, column2, ..., columnn)

Definition at line 218 of file backup.php.

Referenced by _backup_dump_contents().

_evenNumberOfQuotes ( text  ) 

Definition at line 489 of file backup.php.

Referenced by split_sql_file().

_execute_queries ( sql_query  ) 

Definition at line 352 of file backup.php.

References debug(), mysql_error(), mysql_query(), remove_remarks(), and split_sql_file().

Referenced by do_restore().

do_backup ( gzip = 0  ) 

Scripts to create/restore a backup of the Nucleus database

Based on code in phpBB (http://phpBB.sourceforge.net)

http://nucleuscms.org/license.txt GNU General Public License Copyright (C) 2002-2007 The Nucleus Group

Version:
Id
backup.php 1183 2007-07-15 15:06:31Z kaigreve
NucleusJP
backup.php,v 1.8.2.1 2007/08/08 05:23:31 kimitake Exp
This function creates an sql dump of the database and sends it to the user as a file (can be gzipped if they want)

no output may have preceded (new headers are sent)

Parameters:
gzip 1 = compress backup file, 0 = no compression (default)

Definition at line 33 of file backup.php.

References $manager, $nucleus, exit, mysql_fetch_object(), sql_query(), and sql_table().

Referenced by ADMIN::action_backupcreate().

do_restore (  ) 

Definition at line 301 of file backup.php.

References _execute_queries(), and postFileInfo().

Referenced by ADMIN::action_backuprestore().

gzip_PrintFourChars ( Val  ) 

Definition at line 291 of file backup.php.

remove_remarks ( sql  ) 

Definition at line 380 of file backup.php.

Referenced by _execute_queries().

split_sql_file ( sql  ) 

Definition at line 418 of file backup.php.

References _evenNumberOfQuotes().

Referenced by _execute_queries().



Generated on Wed Jun 25 17:25:59 2008 by  doxygen 1.5.5