Click here to Skip to main content
15,900,110 members
Home / Discussions / Linux, Apache, MySQL, PHP
   

Linux, Apache, MySQL, PHP

 
GeneralRe: How to round Pin
EliottA28-Jul-09 2:45
EliottA28-Jul-09 2:45 
GeneralRe: How to round Pin
udch29-Jul-09 2:22
udch29-Jul-09 2:22 
QuestionForm Display Functions Pin
madan patil27-Jul-09 1:43
madan patil27-Jul-09 1:43 
AnswerRe: Form Display Functions Pin
Marc Firth27-Jul-09 22:07
Marc Firth27-Jul-09 22:07 
QuestionHow to use if condition in php Pin
udch25-Jul-09 22:14
udch25-Jul-09 22:14 
AnswerRe: How to use if condition in php Pin
Marc Firth26-Jul-09 22:41
Marc Firth26-Jul-09 22:41 
QuestionCan we use wild card in php Pin
udch25-Jul-09 9:44
udch25-Jul-09 9:44 
AnswerRe: Can we use wild card in php Pin
fly90425-Jul-09 10:52
fly90425-Jul-09 10:52 
Is this a result of using the previous code given to you? In which case you do know that you can specify the location that you are saving the new file eg. 'yodo/newFile.txt'

Also you can skip the copying of the file from one site to yours, which I suggested earlier, by simply reading the file straight from the other site.

function copyOldFileToNewFile($oldLocation, $destinationFolder)
{
	//Get Name of File
	$splitted = explode('/', $oldLocation);
	$newLocation = $destinationFolder.$splitted[count($splitted) - 1]; //Directory + new filename
	
	//Open filewriter
	$fh = fopen($newLocation, 'x')
		or die("unable to open file");
		
	//Foreach row in the file
	foreach (file($oldLocation) as $oldLine)
		//replace '" "'
		fwrite($fh, str_replace('" "', '', $oldLine));
		
	//Close the file writer
	fclose($fh);
}

copyOldFileToNewFile('http://www.ab.com/ab.txt', 'yodo/');


If at first you don't succeed, you're not Chuck Norris.

QuestionReg: sql premier database file Pin
nithicbee24-Jul-09 17:18
nithicbee24-Jul-09 17:18 
QuestionExecute DOS command with PHP Pin
ivo7524-Jul-09 9:02
ivo7524-Jul-09 9:02 
AnswerRe: Execute DOS command with PHP Pin
Adam Maras24-Jul-09 20:36
Adam Maras24-Jul-09 20:36 
GeneralRe: Execute DOS command with PHP Pin
ivo7524-Jul-09 22:28
ivo7524-Jul-09 22:28 
QuestionHot write txt file in php ? Pin
udch23-Jul-09 23:11
udch23-Jul-09 23:11 
AnswerRe: Hot write txt file in php ? Pin
Muhammad Mazhar23-Jul-09 23:39
Muhammad Mazhar23-Jul-09 23:39 
GeneralRe: Hot write txt file in php ? Pin
udch24-Jul-09 0:05
udch24-Jul-09 0:05 
GeneralRe: Hot write txt file in php ? Pin
Marc Firth26-Jul-09 22:45
Marc Firth26-Jul-09 22:45 
AnswerRe: Hot write txt file in php ? Pin
fly90424-Jul-09 0:26
fly90424-Jul-09 0:26 
GeneralRe: How write txt file in php ? Pin
udch24-Jul-09 8:22
udch24-Jul-09 8:22 
GeneralRe: How write txt file in php ? Pin
fly90424-Jul-09 8:58
fly90424-Jul-09 8:58 
GeneralRe: How write txt file in php ? Pin
udch25-Jul-09 9:46
udch25-Jul-09 9:46 
QuestionBuild a service chat the same Yahoo web chat Pin
AlienPham23-Jul-09 22:48
AlienPham23-Jul-09 22:48 
AnswerRe: Build a service chat the same Yahoo web chat Pin
Marc Firth26-Jul-09 22:49
Marc Firth26-Jul-09 22:49 
Questioninsert field from other table Pin
pallavi shrivastava22-Jul-09 22:44
pallavi shrivastava22-Jul-09 22:44 
Question[Message Deleted] Pin
<<Tash18>>22-Jul-09 0:22
<<Tash18>>22-Jul-09 0:22 
AnswerRe: Trying Phish Pin
fly90422-Jul-09 0:38
fly90422-Jul-09 0:38 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.