Wednesday, April 29, 2009

Script Edit Profil dot PHP

<?
include"koneksi.inc.php";

if($_POST[editprofil])
{
$urlstr=substr("$_POST[url]",0,7);
if($_POST[nama_dpn]=="" || $_POST[email]=="" || $_POST[url]=="")
{
?>
<script>
alert('nama, email, url tidak boleh kosong');
window.location="http://abgamal.blogspot.com/?mode=editprofil";
</script>
<?
}
elseif(!ereg("^.+\..+$",$_POST[email]))
{
?>
<script>
alert("~~~ Warning!! ~~~ \n\n INVALID PENULISAN EMAIL")
window.location="http://abgamal.blogspot.com/?mode=editprofil";
</script>
<?
}
elseif($urlstr!="http://")
{
?>
<script>alert('salah penulisan url')
window.location="http://abgamal.blogspot.com/?mode=editprofil";
</script>
<?
}
else
{
$updateprofil=mysql_query("UPDATE user SET realname='$_POST[nama_dpn]',email='$_POST[email]',url='$_POST[url]' WHERE id='$_POST[id]'");

if($updateprofil)
{
header('location:http://abgamal.blogspot.com');
}
else
{
?>
<script>alert('eksekusi database gagal')
window.location="http://abgamal.blogspot.com";
</script>
<?
}

}
}
else
{
header('location:http://abgamal.blogspot.com');
}
?>

<----------Batas Copy----------->
Ganti text warna merah dengan alamat blog anda

File Manager di UEUO COM

Login Ke Web based FTP client



Ganti FTP Server, UserName sesuai alamat web anda di ueuo.com

Tuesday, April 21, 2009

Memberlist PHP Multi Kolom

<?
Header("content-type: application/x-javascript");
include"koneksi.inc.php";
session_start();

$numcols = 3;
$numcolsprinted = 0;

$sql=mysql_query("SELECT * FROM user order by nama ASC");
$juml=mysql_num_rows($sql);
echo"document.write('<table width=\"100%\" style=\"font-family:verdana;font-size:10px\">');";

echo"document.write('<tr><td colspan=\"3\">Total Members : $juml</td></tr>');";
$i=0;
while($hsl=mysql_fetch_array($sql))
{
$in= $hsl[1];
$i++;
if ($numcolsprinted == $numcols) {
print "document.write('</tr><tr>');";
$numcolsprinted = 0;
}
echo"document.write('<td>$i</td><td width=\"30%\"><a href=\"$hsl[url]\" target=\"_blank\" style=\"text-decoration:none\"><img src=\"http://www.blogger.com/img/b16-rounded.gif\" border=\"0\"></a> <a href=\"http://blogproject.ueuo.com/jumpmemberarea.php?id=$hsl[id]\" style=\"text-decoration:none\">$in</a></td>');";
$numcolsprinted++;
}
$colstobalance = $numcols - $numcolsprinted;
for ($i=1; $i<=$colstobalance; $i++) {

}
print "document.write('<TD></TD>');";
echo"document.write('</table>');";
?>

<-------- Batas Copy ------------>
Catatan :
Jika ingin melihat demo klik link ini demo Memberlist Multi Kolom

Thursday, April 16, 2009

Jump Member Area

<?
include"koneksi.inc.php";
session_start();
$sql=mysql_query("SELECT * FROM user WHERE id='$_GET[id]'");
$hsl=mysql_fetch_array($sql);

if($_GET[acc]=="hapcook")
{
setcookie("idyou","");
header('location:http://ueuodotcom.blogspot.com');
}
elseif($_GET[acc]=="konfirmasi")
{
if($_SESSION[namauser]=="$hsl[nama]")
{
setcookie("idyou","$_GET[id]");
header('location:http://ueuodotcom.blogspot.com');
}
else
{
?>
<script>
alert('Anda harus Login sebagai member');
window.location='http://ueuodotcom.blogspot.com';
</script>
<?
}
}
else
{
setcookie("idyou","$_GET[id]");
header('location:http://ueuodotcom.blogspot.com');
}
?>

<-------------Batas akhir area copy ------------ >
Ganti text warna merah dengan alamat blog anda

Script Member Area

<?
Header("content-type: application/x-javascript");
include"koneksi.inc.php";
session_start();

if($_COOKIE[idyou]=="")
{
echo"document.getElementById('memberarea').style.display='none';";
}
else
{
echo"document.getElementById('memberarea').style.display='block';";
echo"document.write('<div align=\"right\"><a href=\"http://blogproject.ueuo.com/jumpmemberarea.php?acc=hapcook\">[ Close ]</a></div>');";

$sql=mysql_query("SELECT * FROM user WHERE id='$_COOKIE[idyou]'");
$hsl=mysql_fetch_array($sql);
$anda="<fieldset style=\"padding: 2;width:420px;border:1px solid #bbbbbb\">";
$anda .="<legend>Profil</legend>";
$anda .="<table cellpadding=\"2\" cellspacing=\"2\" width=\"100%\" style=\"font-family:verdana;font-size:10px\">";
$anda .="<tr><td colspan=\"2\" style=\"font-family:verdana;font-size:16px\"><b>PROFIL KAWAN</b></td></tr>";
$anda .="<tr><td>Nama ID</td><td><b>$hsl[nama]</b></td></tr>";
$anda .="<tr><td>Nama Lengkap</td><td><b>$hsl[realname]</b></td></tr>";
$anda .="<tr><td>Email</td><td><b>$hsl[email]</b></td></tr>";
$anda .="<tr><td>Url</td><td><a href=\"$hsl[url]\" target=\"_blank\"><b>$hsl[url]</b></a></td></tr>";
$anda .="</table></fieldset>";

echo"document.write('$anda');";
}
?>

<----------- Batas Akhir Area Copy ------------>
Bagian yang berwarna merah ganti dengan alamat anda di ueuo.com

Tuesday, April 14, 2009

Form Mail

Form Mailnya saya sederhanakan seperti ini

<form enctype="multipart/form-data" action="http://abdgamal.ueuo.com/sendemail.php" method="post" accept-charset="UTF-8">
<br/>
<font face="Verdana" color="#000000" size="2">Your Name*</font><br/>
<input maxlength="100" value="" name="FieldData0" size="45" type="text"/><br/>
<font face="Verdana" color="#000000" size="2">Your Email Address*</font><br/>

<input maxlength="100" value="" name="FieldData1" size="45" type="text"/><br/>
<font face="Verdana" color="#000000" size="2">Website Url</font><br/>
<input maxlength="100" value="" name="FieldData2" size="45" type="text"/><br/>
<td nowrap><font face="Verdana" color="#000000" size="2">Ads Title*</font><br/>
<input maxlength="100" value="" name="FieldData3" size="45" type="text"/><br/>
<font face="Verdana" color="#000000" size="2">Your Ads*</font><br/>
<textarea rows="10" cols="34" name="FieldData5"></textarea><br/>
<input value="Send" name="submit" type="submit"/> <input value=" Clear " name="Clear" type="reset"/>
</form>


Save form ini dimana saja pada blog anda
Ganti alamat yang berwarna merah dengan alamat di ueuo.com
langkah selanjutnya adalah buat script sendemail.php di ueuo.com

scriptnya adalah

<?
if($_POST[submit])
{
$pesan=urldecode($_POST[FieldData5]);
$pesan=str_replace('\"','"',$pesan);
$pesan=str_replace("\'","'",$pesan);

$kirim="Dear $_POST[FieldData0]".","."\n";
$kirim .="Anda Mendapat Kiriman Email"."\n\n";
$kirim .="Email Pengirim".":"."$_POST[FieldData1]"."\n";
$kirim .="Url Pengirim".":"."$_POST[FieldData2]"."\n\n";
$kirim .="Ads Title".":"."$_POST[FieldData3]"."\n\n";
$kirim .="Your Ads : $pesan"."\n\n";

$sendi= mail("abdgamal16@gmail.com","PESAN BUAT ANDA","$kirim\n\n", "FROM:\"AbdGamal\"<abdgamal16@gmail.com>\n"."X-IP-Address: $_SERVER[REMOTE_ADDR]\n"."X-Referer: $_SERVER[HTTP_REFERER]\n");

if($sendi)
{
header('location:http://abgamal.blogspot.com');
}
else
{
?>
<script>
alert('gagal kirim email');
window.location="http://abgamal.blogspot.com";
</script>
<?
}
}
?>


Ganti yang biru sesuai email dan blog anda. Save as sendemail.php
semoga berhasil.

Monday, March 23, 2009

Member List

Memberlist dot PHP Terdaftar

Script Memberlist Dot PHP

<?
Header("content-type: application/x-javascript");
include"koneksi.inc.php";
session_start();

$sql=mysql_query("SELECT * FROM user order by nama ASC");
$juml=mysql_num_rows($sql);
echo"document.write(\"<table width='100%' style='font-family:verdana;font-size:10px'>\");";
echo"document.write(\"<tr><td>Total Members : $juml</td></tr>\");";
while($hsl=mysql_fetch_array($sql))
{
echo"document.write(\"<tr><td><a href='$hsl[url]' target='_blank' style='text-decoration:none'>$hsl[nama]</a></td></tr>\");";

}
echo"document.write(\"</table>\");";
?>

Create File Memberlist dot PHP

Thursday, March 19, 2009

Hasil Form Forgot Password

Edit script Login dot PHP

Forgotpass dot PHP terdaftar

Script Forgotpass Dot PHP

<?
include"koneksi.inc.php";
session_start();
function makeRandomcaptcha() {
$salt ="abch123efgABCDEFhjkm4LMNP567npqGHIJKrstuvwxyz89";
srand((double)microtime()*1000000);
$i = 0;
while ($i <= 5) {
$num = rand() % 33;
$tmp = substr($salt, $num, 1);
$pass = $pass . $tmp;
$i++;
}
return $pass;
}

$captcha_word = makeRandomcaptcha();

if($_GET[tampil]=="1")
{
$im = imagecreate(100, 30);

$hitam = imagecolorallocate( $im,255,255,255);
$putih = imagecolorallocate( $im,0,0,0);
$ukuran_font = 5;

imageline($im, 0, 15, 99, 15, $putih);


$pos_x = (imageSX($im) - strlen($_GET[cod]) * imagefontwidth($ukuran_font))/2;
$pos_y =(imageSY($im) - imagefontheight($ukuran_font))/2;

imagestring($im, $ukuran_font, $pos_x, $pos_y, $_GET[cod], $putih);


header("Content-Type: image/jpeg");
imageJPEG($im);
imagedestroy($im);
}

echo"<fieldset style=\"padding:4px;border:1px solid #bbbbbb;width:500px;font-family:verdana;font-size:11px\">";
echo"<legend align=right><b><i>LUPA PASSWORD</i></b></legend>";
echo"<div><form method=\"POST\" action=\"forgotpass.php\">";
echo"<input type=\"hidden\" name=\"words\" value=\"$captcha_word\">";
echo"<div>Masukkan NAMA ID Anda</div>";
echo"<div><input type=\"text\" name=\"namaid\"></div>";
echo"<div><img src=forgotpass.php?tampil=1&cod=$captcha_word></div>";
echo"<div>Masukkan Kode Unik ini</div>";
echo"<div><input type=\"text\" name=\"word\"></div>";
echo"<div><input type=\"submit\" name=\"submit\" value=\"submit\"> [ <a href=\"http://abgamal.blogspot.com\">back to BLOGPROJECT</a> ]</div>";
echo"</form></fieldset>";

if($_POST[submit])
{
$sql=mysql_query("SELECT * FROM user WHERE nama='$_POST[namaid]'");
$ada=mysql_num_rows($sql);

$hsl=mysql_fetch_array($sql);

if($_POST[namaid]=="")
{
echo"<script>alert('Nama ID anda belum diisi');</script>";
}
elseif($ada=="0")
{
echo"<script>alert('Nama ID anda belum terdaftar');</script>";
}
elseif($_POST[word]=="" || $_POST[word]!="$_POST[words]")
{
echo"<script>alert('Kode Unik belum diisi atau salah');</script>";
}
else
{
function password() {
$salt ="abch123efgABCDEFhJKrstuvwxyz89jkm4LMNP567npqGHI";
srand((double)microtime()*1000000);
$i = 0;
while ($i <= 5) {
$num = rand() % 33;
$tmp = substr($salt, $num, 1);
$pass = $pass . $tmp;
$i++;
}
return $pass;
}

$katakunci = password();
$katakuncix=md5($katakunci);

mysql_query("UPDATE user SET password='$katakuncix' WHERE nama='$_POST[namaid]'");

$welcome .="Dear $_POST[namaid]".","."\n";
$welcome .="Password Anda Telah Berubah"."\n\n";
$welcome .="LOGIN ID ANDA".":"."$_POST[namaid]"."\n";
$welcome .="PASSWORD ANDA".":"."$katakunci"."\n\n";
$welcome .="# author:BLOGPROJECT ABDGAMAL\n".
"# email: abdgamal16@gmail.com\n".
"# url :http://abgamal.blogspot.com";
$kirim= mail("$hsl[email]","PERUBAHAN PASSWORD","$welcome\n\n", "FROM:\"BLOGPROJECT ABDGAMAL\"<abdgamal16@gmail.com>\n"."X-IP-Address: $_SERVER[REMOTE_ADDR]\n"."X-Referer: $_SERVER[HTTP_REFERER]\n");

if($kirim)
{
?>
<script>alert("Password Anda telah kami kirim via Email Silahkan di Cek");
window.location="http://abgamal.blogspot.com";
</script>
<?
}
}
}
?>

INI BAGIAN YANG TIDAK TERMASUK YANG DI COPY
Ket : Ganti bagian yang berwarna merah sesuai dengan identitas anda masing-masing

Create File Forgotpass dot PHP

Friday, March 13, 2009

Sign Up pada Email



Sign Up

Signup dot PHP terdaftar

Script Signup Dot PHP

<?
session_start();
function makeRandomcaptcha() {
$salt ="abch123efgABCDEFhjkm4LMNP567npqGHIJKrstuvwxyz89";
srand((double)microtime()*1000000);
$i = 0;
while ($i <= 5) {
$num = rand() % 33;
$tmp = substr($salt, $num, 1);
$pass = $pass . $tmp;
$i++;
}
return $pass;
}

$captcha_word = makeRandomcaptcha();

if($_GET[tampil]=="1")
{
$im = imagecreate(100, 30);

$hitam = imagecolorallocate( $im,255,255,255);
$putih = imagecolorallocate( $im,0,0,0);
$ukuran_font = 5;

imageline($im, 0, 15, 99, 15, $putih);


$pos_x = (imageSX($im) - strlen($_GET[cod]) * imagefontwidth($ukuran_font))/2;
$pos_y =(imageSY($im) - imagefontheight($ukuran_font))/2;

imagestring($im, $ukuran_font, $pos_x, $pos_y, $_GET[cod], $putih);


header("Content-Type: image/jpeg");
imageJPEG($im);
imagedestroy($im);
}
include"koneksi.inc.php";
?>
<fieldset style="padding:4px;border:1px solid #bbbbbb;width:500px;font-family:verdana;font-size:11px">
<legend align=right><b><i>SILAHKAN DAFTAR</i></b></legend>
<table border=0 width=500px cellpadding=4 cellspacing=4 style="font-family:verdana;font-size:10px">
<form method=post action="daftar.php">
<tr>
<td><b>NAMA ID</b></td>
<td><input type=text name=nama_id size=30 maxlength="8" value="<? echo"$_POST[nama_id]"; ?>"></td>
</tr>
<tr>
<td><b>NAMA ANDA</b></td>
<td><input type=text name=nama_dpn size=30 maxlength="50" value="<? echo"$_POST[nama_dpn]"; ?>"></td>
</tr>
<tr>
<td><b>EMAIL</b></td>
<td><input type=text name=email size=50 maxlength="30" value="<? echo"$_POST[email]"; ?>"> <br> ( mis : abdgamal16@gmail.com )</td>
</tr>
<tr>
<td><b>URL</b></td>
<td><input type=text name=url size=50 maxlength="40" value="<? echo"$_POST[url]"; ?>"> <br> ( mis : http://abgamal.blogspot.com )</td>
</tr>
<tr>
<td><b>PASSWORD</b></td>
<td><input type=password name=password size=30 maxlength="8"></td>
</tr>
<tr>
<td><b>CONFIRM PASSWORD</b></td>
<td><input type=password name=passwordc size=30 maxlength="8"></td>
</tr>
<tr><td colspan=2><b>MASUKKAN KODE</b> </td></tr>
<tr><td colspan=2>
<? echo"<img src=daftar.php?tampil=1&cod=$captcha_word>"; ?>
</td>
</tr>
<tr><td colspan=2><input type=text name=word id="word"></td></tr>
<input type=hidden name=words id="words" value="<? echo"$captcha_word"; ?>"></td></tr>
<tr>
<td colspan=2 align=right>[ <a href="http://abgamal.blogspot.com">Kembali</a> ] <input type=submit name=subdaf value='Daftar'> <input type=reset value='Reset'></td>
</tr>
</form>
</table>
</fieldset>
<?
if($_POST[subdaf])
{
$nama_id=str_replace(" ","_",$_POST[nama_id]);
$urlstr=substr("$_POST[url]",0,7);
$check_anggota=mysql_query("SELECT nama FROM user WHERE nama='$nama_id'");
$col_anggota=mysql_fetch_array($check_anggota);

if(empty($nama_id))
{
?>
<script>
alert("~~~ Warning!! ~~~ \n\n NAMA ID TIDAK BOLEH KOSONG")
</script>
<?
}
elseif(!empty($col_anggota[nama]))
{
?>
<script>
alert("~~~ Warning!! ~~~ \n\n NAMA ID YANG ANDA GUNAKAN SUDAH EXIST \n SILAHKAN COBA YANG LAIN")
</script>
<?
}
elseif(empty($_POST[nama_dpn]))
{
?>
<script>
alert("~~~ Warning!! ~~~ \n\n NAMA ANDA TIDAK BOLEH KOSONG")
</script>
<?
}
elseif(empty($_POST[email]))
{
?>
<script>
alert("~~~ Warning!! ~~~ \n\n EMAIL TIDAK BOLEH KOSONG")
</script>
<?
}
elseif(!ereg("^.+\..+$",$_POST[email]))
{
?>
<script>
alert("~~~ Warning!! ~~~ \n\n INVALID PENULISAN EMAIL")
</script>
<?
}
elseif(empty($_POST[url]))
{
echo"<script>alert('url tidak boleh kosong')</script>";
}
elseif($urlstr!="http://")
{
echo"<script>alert('salah penulisan url')</script>";
}
elseif(empty($_POST[password]))
{
?>
<script>
alert("~~~ Warning!! ~~~ \n\n PASSWORD TIDAK BOLEH KOSONG")
</script>
<?
}
elseif($_POST[password]!="$_POST[passwordc]")
{
?>
<script>
alert("~~~ Warning!! ~~~ \n\n PASSWORD TIDAK MATCH")
</script>
<?
}
elseif($_POST[word]!=$_POST[words])
{
echo"<script>alert('kode salah')</script>";
}
else
{
$now=time();
$passwordc=md5($_POST[password]);
$register=mysql_query("INSERT INTO user (NAMA,PASSWORD,LEVEL,REALNAME,EMAIL,URL,WAKTU) VALUES('$_POST[nama_id]','$passwordc','2','$_POST[nama_dpn]','$_POST[email]','$_POST[url]','$now')");

if($register)
{
$welcome .="Dear $_POST[nama_dpn]".","."\n";
$welcome .="Welcome, Salam Kenal dengan Anda dan Selamat bergabung dengan kami"."\n\n";
$welcome .="LOGIN ID ANDA".":"."$_POST[nama_id]"."\n";
$welcome .="PASSWORD ANDA".":"."$_POST[password]"."\n\n";
$welcome .="# author:BLOGPROJECT ABDGAMAL\n".
"# email: abdgamal16@gmail.com\n".
"# url :http://abgamal.blogspot.com";
$kirim= mail("$_POST[email]","KEANGGOTAAN ANDA","$welcome\n\n", "FROM:\"BlogProject AbdGamal\"<abdgamal16@gmail.com>\n"."X-IP-Address: $_SERVER[REMOTE_ADDR]\n"."X-Referer: $_SERVER[HTTP_REFERER]\n");

}
?>
<script>alert("Thanks, Anda Sudah Menjadi Member Kami \n ID dan PASSWORD sudah kami kirim ke EMAIL Anda \n Silahkan di Cek");
window.location="http://abgamal.blogspot.com";
</script>
<?

}
}
?>


Bagian yang tidak termasuk untuk di copy
Keterangan
Ganti Text berwarna Merah dengan alamat anda di Blogspot
Yang Berwarna Biru, ganti sesuai dengan title, email dan url anda, sebagai informasi, bagian yang berwarna biru akan dikirim langsung ke Email pendaftar, jika registrasinya berhasil dieksekusi

Create Signup dot PHP

Friday, March 6, 2009

Uji Coba Form Login

Form Login

Insert Admin



Keterangan Gambar
ID : kosongkan saja
Nama : isi terserah anda (atau isi aja dengan kata "admin" )
Password : karena password di encript, anda harus encript dulu password anda di sini [encript password]. Hasil kode encript anda isikan di kolom password
Level : isi dengan angka 1
Real Name : isi dengan Nama Anda
Email : Isi dengan email anda
URL : isi dengan URL anda mis http://abgamal.blogspot.com
Waktu : isi dengan angka ini 1236148440

Seperti contoh gambar dibawah ini

Table User Mysql Terbentuk



kemudian kembali ke Main phpMyadmin dengan meng klik link database disisi kiri seperti contoh gambar



setelah klik akan muncul gambar Main phpMyadmin seperti ini

Insert Table User Mysql

Table User Mysql

CREATE TABLE `user` (
`id` int(10) NOT NULL auto_increment,
`nama` varchar(20) collate latin1_general_ci NOT NULL,
`password` varchar(100) collate latin1_general_ci NOT NULL,
`level` int(3) NOT NULL,
`realname` varchar(50) collate latin1_general_ci NOT NULL,
`email` varchar(100) collate latin1_general_ci NOT NULL,
`url` varchar(100) collate latin1_general_ci NOT NULL,
`waktu` int(20) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci AUTO_INCREMENT=6 ;

Query

Logout Dot PHP Terdaftar

Script Logout Dot PHP

<?
session_start();
session_destroy();

header("location:http://ueuodotcom.blogspot.com");
?>

Tidak termasuk yang di copy
Ganti Teks yang berwarna merah dengan alamat anda di blogspot

Kirim Dot PHP terdaftar

Script Kirim Dot PHP

<html>

<body>
<?
include"koneksi.inc.php";
session_start();

$passwordc=md5($_POST[password]);
$query="SELECT * FROM user WHERE nama='$_POST[namaid]' AND password='$passwordc'";
$hasil=@mysql_query($query);
$row=@mysql_fetch_array($hasil);

if(!empty($row[nama]) && !empty($row[password]))
{
session_register("namauser");
$_SESSION[namauser]="$row[nama]";

?>
<script>
window.location='http://ueuodotcom.blogspot.com';
</script>
<?
}
else
{
?>
<script>
alert("~~~ Warning!! ~~~ \n\n invalid NAMA_ID dan PASSWORD")
window.location ="http://ueuodotcom.blogspot.com";
</script>
<?
}
?>
</body>
</html>

Tidak Termasuk yang di copy
Catatan : Ganti text yang berwarna merah dengan alamat anda di blogspot.com

Login Dot PHP Terdaftar

Script Login Dot PHP

<?
Header("content-type: application/x-javascript");
include"koneksi.inc.php";
session_start();
$form="<form method='POST' action='http://blogproject.ueuo.com/kirim.php'>";
$form .="<table>";
$form .="<tr><td colspan=2><input type='text' name='namaid' value='login'></td></tr>";
$form .="<tr><td colspan=2><input type='password' name='password' value='******'></td></tr>";
$form .="<tr><td><input type='submit' name='submit' value='sign in'></td><td><a href='http://blogproject.ueuo.com/daftar.php'>Sign Up</a></td></tr>";
$form .="</table>";
$form .="</form>";

if($_SESSION[namauser]=="")
{
echo "document.write(\"$form\")";
}
else
{
$login="<table><tr>";
$login .="<td>$_SESSION[namauser]</td>";
$login .="<td><a href=\"http://blogproject.ueuo.com/logout.php\">[LOGOUT]</a></td></tr></table>";
echo "document.write('$login')";
}
?>

Tidak termasuk yang di copy
Catatan : Ganti bagian yang berwarna merah dengan alamat hosting anda sendiri

Create File Login Dot PHP

Monday, March 2, 2009

Bloglist dalam iframe blogger

Daftarkan Blog Anda disini

Edit script Bloglist

Cari script seperti ini untuk mengubah background halaman

<body bgcolor="#ffffff" leftmargin="0">
<table style="position:absolute;top:0;left:0px;z-index:100" width="1000px" height="270px" bgcolor="#ffffff"><tr><td> </td></tr></table>

Ganti bagian yang berwarna merah, #ffffff itu menunjukkan background warna putih, silahkan gunakan kode warna sendiri atau jika bingung, ganti saja dengan nama warna dalam bahasa inggris misalnya "blue", "green", "yellow" dst.

Cari script seperti ini untuk mengubah ukuran lebar (width) dan tinggi (height) view bloglist

<div style="position:absolute; overflow:auto;top:5;left:0px;z-index:101;font-size:11px;width:220px;height:400px;padding:3px;font-family:verdana">

Ganti bagian yang berwarna hijau dengan ukuran yang sesuai selera anda

Edit View Bloglist

Hasil ujicoba view bloglist

Uji Coba input form bloglist

Uji Coba add bloglist

Contoh View Bloglist

View Bloglist Terdaftar

View Bloglist dot PHP

Bagian Awal yang harus anda Copy

<html>

<? include"koneksi.inc.php";

$sqlj=mysql_query("SELECT * FROM bloglist");
$jum=mysql_num_rows($sqlj);

$sql=mysql_query("SELECT * FROM bloglist ORDER BY RAND() LIMIT $jum");
?>

<body bgcolor="#ffffff" leftmargin="0">
<table style="position:absolute;top:0;left:0px;z-index:100" width="1000px" height="270px" bgcolor="#ffffff"><tr><td> </td></tr></table>

<script type="text/javascript">
function myPopup2() {
window.open( "http://blogproject.ueuo.com/forminputbloglist.php", "myWindow",
"status = 1, height = 350, width = 400, resizable = 0,scrollbars=yes; left=10" )
}

</script>

<div style="position:absolute; overflow:auto;top:5;left:0px;z-index:101;font-size:11px;width:220px;height:400px;padding:3px;font-family:verdana">

<?
if($jum!="0")
{
echo"$jum BLOG<br><br>";
$x=0;
while($hsl=mysql_fetch_array($sql))
{
$x++;
$scroll[$x]="$hsl[ket]<br><a href=\"$hsl[link]\" target=\"_blank\"><b>$hsl[nama]</b></a>";
echo"$scroll[$x]<br><br>";
}
}
?>
</div>
<div style="position:absolute;top:420px;z-index:101;font-size:10px;font-family:verdana;width:170px" align="right"><button onClick="window.location.reload()" style="font-size:8pt">refresh</button><button onClick="myPopup2()" style="font-size:8pt">add</button>
</div>
</body>
</html>

Bagian Akhir

Catatan : text yang berwarna merah, ganti dengan alamat hosting anda

Create File View Bloglist

Thursday, February 26, 2009

Hasil Bloglist di phpMyadmin

Update Bloglist di phpMyadmin



Selanjutnya Klik bagian yang diberi lingkaran warna merah

Uji Coba Form Input Bloglist

Contoh Form Input Bloglist

Form Input Bloglist terdaftar

Form Input Bloglist dot PHP

<?
session_start();
function makeRandomcaptcha() {
$salt ="abch123efgABCDEFhjkm4LMNP567npqGHIJKrstuvwxyz89";
srand((double)microtime()*1000000);
$i = 0;
while ($i <= 5) {
$num = rand() % 33;
$tmp = substr($salt, $num, 1);
$pass = $pass . $tmp;
$i++;
}
return $pass;
}

$captcha_word = makeRandomcaptcha();

if($_GET[tampil]=="1")
{
$im = imagecreate(100, 30);

$hitam = imagecolorallocate( $im,255,255,255);
$putih = imagecolorallocate( $im,0,0,0);
$ukuran_font = 5;

imageline($im, 0, 15, 99, 15, $putih);


$pos_x = (imageSX($im) - strlen($_GET[cod]) * imagefontwidth($ukuran_font))/2;
$pos_y =(imageSY($im) - imagefontheight($ukuran_font))/2;

imagestring($im, $ukuran_font, $pos_x, $pos_y, $_GET[cod], $putih);


header("Content-Type: image/jpeg");
imageJPEG($im);
imagedestroy($im);
}

include"koneksi.inc.php" ?>

<table width="800px" height="100px" style="position:absolute;top:0px;z-index:100" bgcolor="#ffffff"><tr><td>
</td></tr></table>
<form method="POST" action="forminputbloglist.php" style="position:absolute;top:20px;z-index:101">
<table width=90% style="font-family:verdana;font-size:11px" cellpadding=2 cellspacing=4>
<tr bgcolor=#efefef><td>Input Link Blog</td></tr>
<tr><td>Title Blog</td></tr>
<tr><td><input type="text" name="nama" size="40" maxlength="20" value="<? echo"$_POST[nama]"; ?>"></td></tr>
<tr><td>URL (mis:http://abgamal.blogspot.com)</td></tr>
<tr><td><input type="text" name="urlx" value="<? echo"$_POST[urlx]"; ?>" size="40"></td></tr>
<tr><td>Keterangan (Max :100 karakter)</td></tr>
<tr><td><input type="text" name="ket" value="<? echo"$_POST[ket]"; ?>" maxlength="200" size="40"></td></tr>
<tr><td>MASUKKAN KODE </td></tr>
<tr><td>
<? echo"<img src=forminputbloglist.php?tampil=1&cod=$captcha_word>"; ?>
</td>
</tr>
<tr><td><input type=text name=word id="word"></td></tr>
<input type=hidden name=words id="words" value="<? echo"$captcha_word"; ?>"></td></tr>
<tr><td><input type="submit" name="submit" value="input"></td></tr>
</table>
</form>

<?


if($_POST[submit])
{
$urlstr=substr("$_POST[urlx]",0,7);
if(empty($_POST[nama]))
{
echo"<script>alert('title tidak boleh kosong')</script>";
}
elseif(empty($_POST[urlx]))
{
echo"<script>alert('url tidak boleh kosong')</script>";
}
elseif($urlstr!="http://")
{
echo"<script>alert('salah penulisan url')</script>";
}
elseif(empty($_POST[ket]))
{
echo"<script>alert('keterangan tidak boleh kosong')</script>";
}
elseif($_POST[word]!=$_POST[words])
{
echo"<script>alert('kode salah')</script>";
}
else
{
$nama=str_replace("'","",$_POST[nama]);
$ket=str_replace("'","",$_POST[ket]);
$urlx=str_replace("'","",$_POST[urlx]);


$now=time();
mysql_query("INSERT INTO bloglist (id,nama,link,ket) VALUES ('$now','$nama','$urlx','$ket')");
echo"<script>window.close()</script>";

}
}
?>
<div style=display:none>

Create File Form Input Bloglist

Login

View Bloglist

Form Input Bloglist