Friday, 1 March 2019

how to upload website in cpanel


how to upload website in cpanel

upload website in cpanel


how to upload website in cpanel. It is so very simple. First you need to create zip file of all file and folder. And you required to login in cpanel. if you have login your cpanel and go inside in your cpanel. you will go in cpanel folders. There are so many folders and check public html folder and check your domain name folder in this folder. If you find your domain folder please open that folder and go to upload button click on that button and select your zip file and click upload button after some time your file will be uploaded after upload your website and unzip. And after that set all details. And your site will run and this is a simple way to upload your site in cpanel.


Monday, 25 February 2019

Compiler and Interpreter


Compiler and Interpreter


What is compiler and Interpreter?

Differentiate between in Compiler and Interpreter.

There is some difference in compiler and interpreter both are converter. Compiler work is convert full code in machine language and give result. But interpreter work like line by line first read one line and give result then goes to another line. Both are work is same they do convert high label to low label and low label to high label.

Source Code → Compiler Machine Code→ Output

Source Code → Interpreter  Output
Example:
Compiler work in C, C++ etc.
Interpreter work in Java etc.



Friday, 22 February 2019

how to make menu bar in html

how to make menu bar in html

menu bar

menu.html  file
<html>
<head>
<title>menu</title>
<link rel="stylesheet" type="text/css" href="menu.css"/>

<body>
<div id="menu">
<ul>
<li><a href="#">student</a>
<ul>
<li><a href="#">Student entry</a></li>
<li><a href="#">View student</li>
</ul>
</li>
<li><a href="#">Teachers</a>
<ul>
<li><a href="#">teacher entry</a></li>
<li><a href="#">View teachers</li>
</ul>
</li>
<li><a href="#">Faculty</a>
<ul>
<li><a href="#">Faculty entry</a></li>
<li><a href="#">View Faculty</li>
</ul>
</li>
<li><a href="#">Subject</a>
<ul>
<li><a href="#">Subject entry</a></li>
<li><a href="#">View subject</li>
</ul>
</li>
<li><a href="#">Score</a>
<ul>
<li><a href="#">Score entry</a></li>
<li><a href="#">View Score</li>
</ul>
</li>
<li><a href="#">Attendances</a>
<ul>
<li><a href="#">Attendace entry</a></li>
<li><a href="#">Monthle Stats</li>
<li><a href="#">Students Status</li>
</ul>
</li>
<li><a href="#">Users</a>
<ul>
<li><a href="#">users entry</a></li>
<li><a href="#">View users</li>
</ul>
</li>
<li><a href="#">Contact</a></li>
</ul>
</div>
</body>
</head>
</html>


menu.css      css file

*{
margin:0px;
padding:0px;
}
body{background:grey;}
#menu ul
{
list-style:none;
}
#menu li
{
background:red;
border: solid 1px white;
width:180px;
height:50px;
line-height:50px;
float:left;
text-align:center;
position:relative;
text-transform:uppercase;
border-radius: 12px;
}
#menu ul li a
{
text-decoration:none;
color:white;
display:block;
}
#menu ul li a:hover
{
background-color:green;
border-radius:12px; 
}
#menu ul ul
{
position:absolute;
display:none;
}
#menu ul li:hover > ul
{
display:block;
}
#menu ul ul ul
{
margin-left:180px;
top:0px;
}
.list
{
width: 660px;
    height: 400px;
    margin-left: 339px;
    float: left;
    margin-top: 26px;
    border: solid cadetblue;
}
@media screen and (max-width:700px)
{
.list
{
float:left;
margin-left:-20px;
}
#menu ul
{
flex-direction:column;
display:block;
}
}

@media screen and (max-width:640px) {
#menu ul li{
max-width: 100%;
}
}

@media screen and (max-width:775px) {
#menu ul li{
max-width: 100%;
padding: 0px 5px 0px 5px;
float: none;
text-align: center;
}
}

@media screen and (max-width:980px) {
#menu ul  li{
max-width: 100%;
}
}
#list
{
width:auto;
margin-top:40px;
}
.slist
{
height:400px;
}
.tlist
{
height: 32px;
    width: 205px
}
#area
{
height: 100px;
    width: 207px;
}
.btn
{
width:100px;
height: 40px;
    border-radius: 11px;
    border: solid #4050c1;
}
#content
{
text-align:justify;
margin:10px;
padding:10px;
}

please comment  on this post 

Saturday, 16 February 2019

how to upload image in php

<html>
<head>
<title>insert data</title>
<body>
<form action="" method="POST" enctype="multipart/form-data">
Name<input type="text" name="name"><br><br>
Age<input type="text" name="age"><br><br>
Contact No.<input type="text" name="contact"><br><br>
Upload Img<input type="file" name="image"><br><br>
<input type="submit" name="submit" value="submit">
</form>
</body>
</head>
</html>
<?php

    $name=$_POST['name'];
$age=$_POST['age'];
$contact=$_POST['contact'];

if(isset($_POST['submit']))
{
//this code use for upload images
$fnm=$_FILES["image"]["name"];
    $dst="./images/".$fnm;
    move_uploaded_file($_FILES["image"]["tmp_name"],$dst);
if($name!=""&& $age!="" && $contact!="" && $fnm!="")
{
$query="INSERT INTO stud(name,age,contact,image)VALUES('$name',$age,$contact,'$dst')";
$data=mysqli_query($con, $query);

if($data)
{
echo"dta submited";
}
}
else
{
echo "all field are required";
}
}
?>