Page 1 of 1

Working with MySqldump to PHP. HOW?{SOLVED}

Posted: Sat Feb 25, 2006 4:23 am
by khaki_monster
hi! again!...

how do i invoke mysqldump with php script to make a backup, such as bellow sample code in some form of text file? i know how to work with mysqldump in a shell/"command" but i dont have any idea to work with php.

Code: Select all

-- 
-- Table structure for table `myTable`
-- 

CREATE TABLE `myTable` (
  `id` int(10) NOT NULL auto_increment,
  `message` text NOT NULL,
  `author` varchar(80) NOT NULL default '',
  `email` varchar(50) NOT NULL default '',
  `date` varchar(50) NOT NULL default '',
  `ip` varchar(20) NOT NULL default '',
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=2 ;

-- 
-- Dumping data for table `myTable`
-- 

INSERT INTO `myTable` VALUES (1, 'this is a test', 'Victor', 'Your E-Mail', '12.07.05', '127.0.0.1');
hope to recieved a nice feedback's from you guyz :)

and tanx in advanced...

cheerz! :D

Posted: Sat Feb 25, 2006 9:59 am
by feyd