Install and Configure Apache2
1.sudo apt-get update
2.apt-get install apache2 apache2-utils
3.nano /etc/apache2/mods-enabled/dir.conf
4.<IfModule mod_dir.c>
DirectoryIndex index.php index.html index.cgi index.pl index.xhtml index.htm
</IfModule>
5.service apache2 restart
6.apt-get install mysql-server libapache2-mod-auth-mysql php5-mysql
7.mysql_install_db
8.mysql_secure_installation
9.apt-get install php5 php5-mysql php-pear php5-gd php5-mcrypt php5-curl
10.nano /var/www/html/phpinfo.php
11.<?php phpinfo(); ?>
12.nano /var/www/html/phpmysql.php
13.
<?php
$con = mysql_connect("localhost","root","password");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
else
{
echo "Congrats! connection established successfully";
}
mysql_close($con);
?>
0 Response to "Kegiatan 4 Maret 2016"
Posting Komentar