Rabu, 28 Januari 2009

Membuat tulisan di HTML






Type your summary here


baris pertama

baris kedua

jenis arial

jenis tahoma

jenis courier new

biru

merah

ukuran 1



ukuran 2



ukuran 3



ukuran 4



ukuran 5


ukuran 6


di atas garis


di bawah garis





1.isi pertama
2.isi kedua


3.isi ketiga
4.isi keempat


Type rest of the post here

Rabu, 17 Desember 2008

Cara buat Guestbook dgn PHP

Bagi anda yang ingin belajar PHP, maka anda bisa mencoba membuat sebuah program sederhana yaitu buku tamu (guestbook). berikut langkah-langkahnya :
Type your summary here

1. Buatlah database “guesbook”



CREATE TABLE `guestbook` (
`id` int(4) NOT NULL auto_increment,
`name` varchar(65) NOT NULL default ”,
`email` varchar(65) NOT NULL default ”,
`comment` longtext NOT NULL,
`datetime` varchar(65) NOT NULL default ”,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

2. Buat file guestbook.php







Test Sign Guestbook





























Name:
Email:
Comment:
  






View Guestbook


3. Buatlah file addguestbook.php



$host=”localhost”; // Host name
$username=”"; // Mysql username
$password=”"; // Mysql password
$db_name=”test”; // Database name
$tbl_name=”guestbook”; // Table name



// Connect to server and select database.
mysql_connect(”$host”, “$username”, “$password”)or die(”cannot connect server “);
mysql_select_db(”$db_name”)or die(”cannot select DB”);

$datetime=date(”y-m-d h:i:s”); //date time

$sql=”INSERT INTO $tbl_name(name, email, comment, datetime)VALUES(’$name’, ‘$email’, ‘$comment’, ‘$datetime’)”;
$result=mysql_query($sql);

//check if query successful
if($result){
echo “Successful”;
echo “
”;
echo “View guestbook”; // link to view guestbook page
}

else {
echo “ERROR”;
}

mysql_close();
?>

4. Buat file viewguestbook.php





View Guestbook | Sign Guestbook





$host=”localhost”; // Host name
$username=”"; // Mysql username
$password=”"; // Mysql password
$db_name=”test”; // Database name
$tbl_name=”guestbook”; // Table name

// Connect to server and select database.
mysql_connect(”$host”, “$username”, “$password”)or die(”cannot connect server “);
mysql_select_db(”$db_name”)or die(”cannot select DB”);

$sql=”SELECT * FROM $tbl_name”;
$result=mysql_query($sql);

while($rows=mysql_fetch_array($result)){
?>






























ID:
Name:
Email:
Comment:
Date/Time :



}
mysql_close(); //close database
?>

Selamat mencoba.....Good Luck!!

Type rest of the post here

Cara Boeat Counter di Blog

Mau tau ??

1.Login Ke Blog Anda lalu masuk ke tata letak
2.Klik tambah gadtget lalu pilih HTML , lalu pilih tambah
3.Buka new tab lalu buka http://www.hit-counts.com/ lalu muncul kayak gini..


Type your summary here

4.Pilih style counter hit lalu isi form di bawahnya



5.Centang term and conditions
6.klik generate
7.Copy script hit counter ke windows HTML
8.Klik simpan...
9.Tara...maka muncullah hit counter anda..

Contoh :






Good Luck!!
Type rest of the post here