Kegiatan 4 Maret 2016

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

 default web page apache2 ubuntu 

6.apt-get install mysql-server libapache2-mod-auth-mysql php5-mysql

 configuring mysql-server-5.5 

7.mysql_install_db

 create database directory structure 

8.mysql_secure_installation

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(); ?>

 Test the php script 

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);
?>

Test the php mysql script

0 Response to "Kegiatan 4 Maret 2016"

Posting Komentar