<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
<h1>This is a Heading</h1>
<p>This is a paragraph.</p>
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<style>
#myname {
border:7px solid #8877cc;
}
</style>
</head>
<body>
<div id='myname'>
salam.
</div>
</body>
</html>
#myname {
border:7px solid #fff733;
border-radius:25px;
font-size:70px;
margin-right:150px;
margin-left:150px;
padding-top:30px;
padding-bottom:30px;
padding-left:30px;
background-color:rgba(250,130,30,1);
}
font-color:rgba(140,130,20,1);
body
{
background-color:rgba(140,240,130,1);
}
background-image: url('images/myimage.jpg');
<?php
$db_name = "epiz_9999999_name";
$mysql_username = "epiz_999909";
$mysql_password ="pppppppppp";
$server_name = "sql313.epizy.com";
$ccoonn = mysqli_connect($server_name, $mysql_username, $mysql_password,$db_name);
if (!$ccoonn)
{
die("Connection error: " . mysqli_connect_error());
}
?>
<a href="myphpfile.php">boro be file php man</a>
<a href="http://www.example.com/">This is a Link</a>
<a href="http://www.example.com/"><img src="URL" alt="Alternate Text"></a>
<img src="boat.gif" alt="Big Boat" />
<p>This is a paragraph</p>
<br /> (line break)
<hr /> (horizontal rule)
<pre>This text is preformatted</pre>
<!DOCTYPE html>
<html>
<style>
table, th, td {
border:1px solid black;
}
</style>
<body>
<h2>A basic HTML table</h2>
<table style="width:100%">
<tr>
<th>Company</th>
<th>Contact</th>
<th>Country</th>
</tr>
<tr>
<td>Alfreds Futterkiste</td>
<td>Maria Anders</td>
<td>Germany</td>
</tr>
<tr>
<td>Centro comercial Moctezuma</td>
<td>Francisco Chang</td>
<td>Mexico</td>
</tr>
</table>
<p>To understand the example better, we have added borders to the table.</p>
</body>
</html>
<html>
<body>
<form action="welcome.php" method="post">
Name: <input type="text" name="name"><br>
E-mail: <input type="text" name="email"><br>
<input type="submit">
</form>
</body>
</html>
<html>
<body>
Welcome <?php echo $_POST["name"]; ?><br>
Your email address is: <?php echo $_POST["email"]; ?>
</body>
</html>
<html>
<body>
Welcome
<?php
echo $_POST["name"];
?>
<br>
Your email address is:
<?php
echo $_POST["email"];
?>
</body>
</html>
if( isset ($_POST['action'] ) )
{
$var=$_POST["varrrr"];
}
<form id='myform' action="<?php echo $_SERVER['PHP_SELF']; ?>" method = 'POST'>
<button type="button" style=" font-size:35px; height:55px; width:120px" >f5</button>
style=" font-size:35px; height:55px; width:120px"
<form id='myform' action="<?php echo $_SERVER['PHP_SELF']; ?>" method = 'POST'>
Name: <input type="text" name="name"><br>
E-mail: <input type="text" name="email"><br>
<input type="submit" name='action_2' value="Submit">
</form>
<?php
if(isset($_POST['action_2']))
{
echo $_POST["name"];
echo $_POST["email"];
}
?>
<html>
<body>
<?php
if( !isset($_POST['action_2']))
{
?>
<form id="myform" action="<?php echo $_SERVER["PHP_SELF"]; ?>" method = "POST">
Name: <input type="text" name="name"><br>
E-mail: <input type="text" name="email"><br>
<input type="submit" name='action_2' value="Submit">
</form>
<?php
}
if(isset($_POST['action_2']))
{
$name=$_POST["name"];
$email=$_POST["email"];
echo "name= ".$name;
echo"<br>";
echo "email= ".$email;
require "ccoonn.php";
mysqli_set_charset($ccoonn, "utf8");
$sql = "INSERT INTO `name_email` (`number`,`name`, `email`) VALUES ('2','$name','$email')";
$result = mysqli_query($ccoonn ,$sql);
echo"<br><br>ghesmate sabt dar database";
}
?>
</body>
</html>
<html>
<body>
<?php
if( !isset($_POST['action_2']))
{
?>
<form id="myform" action="<?php echo $_SERVER["PHP_SELF"]; ?>" method = "POST">
Name: <input type="text" name="name"><br>
E-mail: <input type="text" name="email"><br>
<input type="submit" name='action_2' value="Submit">
</form>
<?php
}
if(isset($_POST['action_2']))
{
$name=test_input($_POST["name"]);
$email=test_input($_POST["email"]);
echo "name= ".$name;
echo"<br>";
echo "email= ".$email;
require "ccoonn.php";
mysqli_set_charset($ccoonn, "utf8");
$sql = "INSERT INTO `name_email` (`number`,`name`, `email`) VALUES ('2','$name','$email')";
$result = mysqli_query($ccoonn ,$sql);
echo"<br><br>ghesmate sabt dar database";
}
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
</body>
</html>
<html>
<body>
<?php
require "ccoonn.php";
mysqli_set_charset($ccoonn, "utf8");
$sql = "SELECT * FROM name_email";
$result = mysqli_query($ccoonn ,$sql);
echo"<center>";
echo"<table border=1>";
while($info = mysqli_fetch_array( $result ))
{
echo"<tr>";
$name=$info['name'];
$email=$info['email'];
echo"<td>"; echo $name; echo"</td>";
echo"<td>"; echo $email; echo"</td>"; echo"</tr>";
}
echo"</table>";
echo"</center>";
if( !isset($_POST['action_2']))
{
?>
<form id="myform" action="<?php echo $_SERVER["PHP_SELF"]; ?>" method = "POST">
Name: <input type="text" name="name"><br>
E-mail: <input type="text" name="email"><br>
<input type="submit" name='action_2' value="Submit">
</form>
<?php
}
if(isset($_POST['action_2']))
{
$name=test_input($_POST["name"]);
$email=test_input($_POST["email"]);
echo "name= ".$name;
echo"<br>";
echo "email= ".$email;
mysqli_set_charset($ccoonn, "utf8");
$sql = "INSERT INTO `name_email` (`number`,`name`, `email`) VALUES ('2','$name','$email')";
$result = mysqli_query($ccoonn ,$sql);
echo"<br><br>ghesmate sabt dar database";
}
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
</body>
</html>
<!DOCTYPE html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html dir="rtl">
<meta charset="UTF-8">
<head>
<title>add text</title>
</head>
<body>
<?php
require "../base/ccoonn.php";
mysqli_set_charset($ccoonn, "utf8");
$sql = "SELECT * FROM texts";
$result = mysqli_query($ccoonn ,$sql);
echo"<center>";
echo"<table border=1>";
while($info = mysqli_fetch_array( $result))
{
echo"<tr>";
echo"<td>"; echo $info['number']; echo"</td>";
echo"<td>"; echo $info['comment']; echo"</td>";
echo"<td>"; echo $info['my_text']; echo"</td>";
echo"</tr>";
}
echo"</table>";
echo"</center>";
echo"<br>";
echo"<br>";
?>
<center>
<form id='myform' action="<?php echo $_SERVER['PHP_SELF']; ?>" method = 'POST'>
number: <input type="text" name="number" ><br><br>
comment: <input type="text" name="comment" ><br><br>
text: <input type="text" name="text" ><br><br>
<input type="submit" name='action1' value="Submit">
</form>
</center>
<?php
if(isset($_POST['action1'])) // add one text at end
{// if action
echo"action";
$number=$_POST["number"];
$comment=$_POST["comment"];
$text=$_POST["text"];
mysqli_set_charset($ccoonn, "utf8");
$sql = "INSERT INTO `texts` (`number`,`comment`,`my_text`) VALUES ('$number','$comment','$text')";
$result = mysqli_query($ccoonn ,$sql);
}// if action
?>
</body>
</html>
<!DOCTYPE html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html dir="rtl">
<meta charset="UTF-8">
<head>
<title>add text</title>
</head>
<body>
<?php
require "../base/ccoonn.php";
mysqli_set_charset($ccoonn, "utf8");
$sql = "SELECT * FROM texts";
$result = mysqli_query($ccoonn ,$sql);
echo"<center>";
echo"<table border=1>";
while($info = mysqli_fetch_array( $result))
{
echo"<tr>";
echo"<td>"; echo $info['number']; echo"</td>";
echo"<td>"; echo $info['comment']; echo"</td>";
echo"<td>"; echo $info['my_text']; echo"</td>";
echo"</tr>";
}
echo"</table>";
echo"</center>";
echo"<br>";
echo"<br>";
?>
<center>
<form id='myform' action="<?php echo $_SERVER['PHP_SELF']; ?>" method = 'POST'>
number: <input type="text" name="number" ><br><br>
comment: <input type="text" name="comment" ><br><br>
text: <input type="text" name="text" ><br><br>
<input type="submit" name='action1' value="Submit">
</form>
</center>
<?php
if(isset($_POST['action1'])) // add one text at end
{// if action
echo"action";
$number=test_input($_POST["number"]);
$comment=test_input($_POST["comment"]);
$text=test_input($_POST["text"]);
mysqli_set_charset($ccoonn, "utf8");
$sql="INSERT INTO `texts` (`number`,`comment`,`my_text`) VALUES ('$number','$comment','$text')";
$result = mysqli_query($ccoonn ,$sql);
}// if action
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
</body>
</html>
<?php
function writeMsg( $number) {
global $ccoonn;
echo"<br>";
mysqli_set_charset($ccoonn, "utf8");
$sql = "SELECT my_text FROM texts WHERE number=$number ";
$result = mysqli_query($ccoonn ,$sql);
while($info = mysqli_fetch_array( $result ))
{
$str=$info['my_text'];
}
return $str;
}//func
?>
<?php
session_start();
?>
<!DOCTYPE html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html dir="rtl">
<head>
<title>saalek110</title>
<style>
</style>
</head>
<body>
<?php
require "../base/ccoonn.php";
include "../functions/functions.php";
$str=writeMsg(2) ;
echo $str;
echo"<br>";
echo"<br>";
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
</body>
</html>
<!DOCTYPE html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html dir="rtl">
<meta charset="UTF-8">
<head>
<title>add post</title>
</head>
<body>
<?php
require "../base/ccoonn.php";
mysqli_set_charset($ccoonn, "utf8");
$sql = "SELECT * FROM posts";
$result = mysqli_query($ccoonn ,$sql);
echo"<center>";
echo"<table border=1>";
while($info = mysqli_fetch_array( $result))
{
echo"<tr>";
echo"<td>"; echo $info['number']; echo"</td>";
echo"<td>"; echo $info['news']; echo"</td>";
echo"</tr>";
}
echo"</table>";
echo"</center>";
echo"<br>";
echo"<br>";
?>
<center>
<form id='myform' action="<?php echo $_SERVER['PHP_SELF']; ?>" method = 'POST'>
news: <input type="text" name="news" ><br><br>
<input type="submit" name='action1' value="Submit">
</form>
</center>
<?php
if(isset($_POST['action1'])) // add one text at end
{// if action
echo"action";
$news=test_input($_POST["news"]);
mysqli_set_charset($ccoonn, "utf8");
$sql="INSERT INTO `posts` (`news`) VALUES ('$news')";
$result = mysqli_query($ccoonn ,$sql);
}// if action
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
</body>
</html>
require "base/ccoonn.php";
mysqli_set_charset($ccoonn, "utf8");
$sql = "SELECT * FROM posts";
$result = mysqli_query($ccoonn ,$sql);
echo"<center>";
echo"<table border=1>";
while($info = mysqli_fetch_array( $result))
{
echo"<tr>";
echo"<td>"; echo $info['number']; echo"</td>";
echo"<td>"; echo $info['news']; echo"</td>";
echo"</tr>";
}
echo"</table>";
echo"</center>";
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html dir="rtl">
<meta charset="UTF-8">
<head>
<title>new post</title>
</head>
<body>
<?php
require "../base/ccoonn.php";
mysqli_set_charset($ccoonn, "utf8");
$sql = "SELECT * FROM posts";
$result = mysqli_query($ccoonn ,$sql);
echo"<center>";
echo"<table border=1>";
while($info = mysqli_fetch_array( $result))
{
echo"<tr>";
echo"<td>"; echo $info['number']; echo"</td>";
echo"<td>"; echo $info['news']; echo"</td>";
echo"</tr>";
}
echo"</table>";
echo"</center>";
echo"<br>";
echo"<br>";
?>
<center>
<form id='myform' action="<?php echo $_SERVER['PHP_SELF']; ?>" method = 'POST'>
post: <input type="text" name="news" ><br><br>
<input type="submit" name='action1' value="Submit">
</form>
</center>
<?php
if(isset($_POST['action1'])) // add one text at end
{// if action
echo"action";
$news=test_input($_POST["news"]);
mysqli_set_charset($ccoonn, "utf8");
$sql="INSERT INTO `posts` (`news`) VALUES ('$news')";
$result = mysqli_query($ccoonn ,$sql);
}// if action
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
</body>
</html>