webssolutions
10-25-2010, 01:45 PM
Hello im using a php file to write and read a xml, but when i fill the information into the file.php this dont write anything into the file.xml. Please some help.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Add a Video</title>
<style>
body{
font:13px Arial, Helvetica, sans-serif;
color:#000;
text-align:center;
}
body, h1, h2, h3, h4, h5, p, table, table th, form, a img, ul {
border: none;
margin: 0px;
padding: 0px;
}
#page{ margin:0 auto; padding:0px; width:980px; text-align:left; background:#fff; }
form{ margin:0 auto; padding:0px; text-align:left; }
form td{ padding:0px 10px 10px 0px; vertical-align:top; }
form .inputtext{ border:solid 1px #c0c0c0; width:300px; padding:3px; }
form textarea{ border:solid 1px #c0c0c0; width:600px; height:150px; padding:3px; }
form #submit{ background:#292A2C; color:#fff; border:0px; padding:5px; cursor:pointer; }
form h2{ padding:20px 0px 20px 0px; color:#344EB6; }
form input, form textarea{ font:13px Arial, Helvetica, sans-serif; }
.green{ color: #46800d; padding-bottom:20px; font-weight:bold; }
</style>
<script src="script.js" type="text/javascript"></script>
</head>
<body>
<div id="page">
<form action="<?=$_SERVER['PHP_SELF'];?>" method="post" name="form" id="form" onsubmit="return addvideo();">
<h2>Add a video</h2>
<p><?=$message?></p>
<table cellpadding="0" cellspacing="0">
<tr><td>Team:</td><td><input type="text" id="team" name="team" value="" class="inputtext" /></td></tr>
<tr><td>Video ID:</td><td><input type="text" id="videoid" name="videoid" value="" class="inputtext" /></td></tr>
<tr><td>Title</td><td><input type="text" id="title" name="title" value="" class="inputtext" /></td></tr>
<tr><td>The Idea</td><td><textarea name="theidea" id="theidea"></textarea></td></tr>
<tr><td>Credits</td><td><textarea name="credits" id="credits"></textarea></td></tr>
<tr><td></td><td><input type="submit" name="submit" id="submit" value="Submit" /></td></tr>
</table>
</form>
</div>
</body>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Add a Video</title>
<style>
body{
font:13px Arial, Helvetica, sans-serif;
color:#000;
text-align:center;
}
body, h1, h2, h3, h4, h5, p, table, table th, form, a img, ul {
border: none;
margin: 0px;
padding: 0px;
}
#page{ margin:0 auto; padding:0px; width:980px; text-align:left; background:#fff; }
form{ margin:0 auto; padding:0px; text-align:left; }
form td{ padding:0px 10px 10px 0px; vertical-align:top; }
form .inputtext{ border:solid 1px #c0c0c0; width:300px; padding:3px; }
form textarea{ border:solid 1px #c0c0c0; width:600px; height:150px; padding:3px; }
form #submit{ background:#292A2C; color:#fff; border:0px; padding:5px; cursor:pointer; }
form h2{ padding:20px 0px 20px 0px; color:#344EB6; }
form input, form textarea{ font:13px Arial, Helvetica, sans-serif; }
.green{ color: #46800d; padding-bottom:20px; font-weight:bold; }
</style>
<script src="script.js" type="text/javascript"></script>
</head>
<body>
<div id="page">
<form action="<?=$_SERVER['PHP_SELF'];?>" method="post" name="form" id="form" onsubmit="return addvideo();">
<h2>Add a video</h2>
<p><?=$message?></p>
<table cellpadding="0" cellspacing="0">
<tr><td>Team:</td><td><input type="text" id="team" name="team" value="" class="inputtext" /></td></tr>
<tr><td>Video ID:</td><td><input type="text" id="videoid" name="videoid" value="" class="inputtext" /></td></tr>
<tr><td>Title</td><td><input type="text" id="title" name="title" value="" class="inputtext" /></td></tr>
<tr><td>The Idea</td><td><textarea name="theidea" id="theidea"></textarea></td></tr>
<tr><td>Credits</td><td><textarea name="credits" id="credits"></textarea></td></tr>
<tr><td></td><td><input type="submit" name="submit" id="submit" value="Submit" /></td></tr>
</table>
</form>
</div>
</body>
</html>