PHP Developers Network

A community of PHP developers offering assistance, advice, discussion, and friendship.
 
Loading
It is currently Thu Oct 19, 2017 1:13 pm

All times are UTC - 5 hours




Post new topic Reply to topic  [ 1 post ] 
Author Message
PostPosted: Fri Jun 02, 2017 1:54 am 
Offline
Forum Newbie

Joined: Fri Jun 02, 2017 1:47 am
Posts: 1
i have PHP coding, at this I want to transform this code to jquery in my application. If there is anyone who could exchange the knowledge.

$xmlString;
if (isset($_POST['xmlString'])){
$filename = $_POST['xmlFilename'];
$xmlString = stripslashes($_POST['xmlString']);

$newFile = "_data/".$filename.".edit.xml";

//write new data to the file, along with the old data
$handle = fopen("../".$newFile, "w");
if (fwrite($handle, $xmlString) === false) {
echo "{error:\"Couldn't write to file.\"}";
}
else {
echo "{filename:\"".$newFile."\"}";
}
fclose($handle);
}


Last edited by requinix on Fri Jun 02, 2017 2:57 am, edited 1 time in total.
removed spam


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: Bing [Bot], Exabot [Bot], Google [Bot] and 16 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group