Simple Translation / Terjemahan Mudah

May 5, 2009
rais

Salam,

Sekali lagi kamus online kamus online memberikan kemudahan baru dalam terjemahan. Caranya mudah anda cuma perlu taip url http://mykamus.my/eng/carian_anda -> untuk Bahasa Inggeris kepada Bahasa Melayu dan http://mykamus.my/mal/carian_anda -> untuk Bahasa Melayu kepada Bahasa Inggeris.

Selamat mencuba.

Once again online dictionary online dictionary give some facilities. You can make translation by typing this urls :
http://mykamus.my/eng/your_search -> for translate english to Malay and http://mykamus.my/mal/your_search -> for malay to english.

Adios ;)

 

Morhabshi – Minyak Herba Serbaguna.

April 14, 2009
rais

Minggu lepas, seorang murid saya datang ke sekolah dengan pipi yang bengkak. Sebelum sempat saya menyangka kanak-kanak itu telah menjadi mangsa dera, ibunya memberitahu bahawa kanak-kanak itu sakit gigi.

Maka saya segera mengambil Minyak Morhabshi dan menyuruh ibunya memasukkan ke dalam lubang gigi kanak-kanak itu menggunakan cebisan tisu.

Keesokan harinya……

Baca selanjutnya di http://morhabshi.blogspot.com
Laman web rasmi di http://morhabshi.com

Posted in: Umum

 

Online Kids Store

April 3, 2009
rais

Salam,

Check this out. Online Kids Store. Sell cloth for your child.
Kedai pakaian kanak-kanak termudah di internet.

http://www.mykids.com.my

 

Link for Bookmark / Bookmark menggunakan link

February 27, 2009
rais

Salam,

This is simple example using javascript to create a link for bookmark your website.
Ini merupakan contoh mudah membuat link untuk pengunjung bookmark laman web anda.

Paste this code in after and before
<script type="text/javascript">
function bookmark(address,sitename) {
if (window.sidebar) {
window.sidebar.addPanel(sitename, address,"");
} else if( document.all ) {
window.external.AddFavorite(address, sitename);
} else if( window.opera && window.print ) {
return true;
}
}
</script>

And paste this code for create the link.

< a href="#" onclick="bookmark('http://www.hujungjari.com/','Hujung Jari')">Bookmark our site!< /a>

 

Online dictionary / Kamus Online (Malay – english – Melayu)

February 17, 2009
rais

Salam,

One of most popular online dictionary to tranlate english to malay. online dictionary

Antara kamus yang popular dalam menterjemah bahasa inggeris kepada bahasa melayu.kamus online

online dictionary

 

Forex 5 minutes and 15 minutes scalping

January 9, 2009
rais

Pair : EUR/USD, GBP/USD, USD/CAD, USD/CHF, NZD/USD, AUD/USD
Timeframe : 5 minutes or 15 minutes
Take Profit : 10 Pips
Stop Loss : Depend
Entry Sell : Sell at open price bar after down arrow in orangered color
Entry Buy : Buy at open price bar after up arrow in lime color

File : indicator, template

myscalping

Posted in: forex
Tags: ,

 

Simple form validate


rais

Salam,

Ini adalah simple fom validate aku buat sendirik. So sesapa nak try buleh copy dan paste jer.

function-function yang terlibat :
//pastikan email adalah valid
function valid_email($address){
if(ereg("^[a-zA-Z0-9_]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$", $address)){
//return true;
} else {
echo '<script type="text/JavaScript">';
echo 'alert(\'Please key-in valid email address\')';
echo '</script>';
echo '<script type="text/JavaScript">';
echo 'history.go(-1)';
echo '</script>';
exit();
}
}

//pastikan upload adalah valid
function valid_upload($fail,$field){
$tmpfail = $_FILES[$field]['tmp_name'];
if(is_uploaded_file($tmpfail)){
//return true;
} else {
echo '<script type="text/JavaScript">';
echo 'alert(\'No file selected fo upload\')';
echo '</script>';
echo '<script type="text/JavaScript">';
echo 'history.go(-1)';
echo '</script>';
exit();
}
}

//pastikan field tidak kosong
function not_empty_field($field){
foreach($field as $key => $value){
$value = trim($value);

if(!empty($value)){
$err_msg[n] .= $value;
//return true;//ada data
} else {
$err_msg[y] .= 'Field ['.$key.'] cannot empty\n';
//return false;//field kosong
}

}
return $err_msg;
}

//back jika field tidak valid
function go_back($search_array){
if (array_key_exists('y', $search_array)) {
echo '<script type="text/JavaScript">';
echo 'alert(\''.$search_array['y'].'\')';
echo '</script>';
echo '<script type="text/JavaScript">';
echo 'history.go(-1)';
echo '</script>';
exit();
} else {
//echo 'form valid';
}
}

Dan macam mana nak guna dan panggil function :
$get_value = array(
'textfiel'=>$_POST['textfield_name1'],
'Field of Study'=>$_POST['textfield_name2'],
'Topic of Research'=>$_POST['textfield_name2']
);
}

//form validate
go_back(not_empty_field($get_value));

Posted in: Javascript, php

 

LDAP Login

May 22, 2008
rais

Salam, Code below is an example how to make your system login using LDAP.

<form name="form1" method="post" action="<?=$_SERVER['PHP_SELF'];?>">
<table width="400" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#000000">
<tr>
<td><table width="100%" border="0" cellspacing="1" cellpadding="3">
<tr bgcolor="#FFFFFF">
<td colspan="2">Beta Version LDAP Login 4 UTHM Web Application </td>
</tr>
<tr bgcolor="#FFFFFF">
<td>User</td>
<td><input type="text" name="user"></td>
</tr>
<tr bgcolor="#FFFFFF">
<td>Password</td>
<td><input type="password" name="pass"></td>
</tr>
<tr bgcolor="#FFFFFF">
<td colspan="2"><div align="center">
<input type="hidden" name="log" value="true">
<input type="submit" name="submit" value="Submit">
</div></td>
</tr>
</table></td>
</tr>
</table>
</form>

<?
/*///////////////////////////////////////
/ Creator : Muhamad Rais Abd Halim /
/ Email : rais@n9.my /
/ What is : Simple LDAP Login /
///////////////////////////////////////*/
ini_set('display_errors', 'off');
$user = $_POST['user'];
$pass = $_POST['pass'];
$binddn = "uid=$user,ou=people,o=n9.my,dc=n9,dc=my";
$ldapBase = 'DC=kuittho,DC=edu,DC=my';
$host = "ldap.test.com"

if(!empty($_POST['user']) && !empty($_POST['pass'])){
$conn = ldap_connect("$host") or die("Could not connect to server. Error is " . ldap_error($conn));

$root_dn ="$binddn";
$root_pw = "$pass";

if($conn){
$r = ldap_bind($conn, $root_dn, $root_pw);
if($r){
$ldapSearch = ldap_search($conn, $ldapBase, "(uid=$user)");
$ldapResults = ldap_get_entries($conn, $ldapSearch);
//kalau login berjaya g sini
echo "<br>Login Success<br>";
echo "No Pekerja anda ialah ".$ldapResults[0]['employeenumber'][0]."<br>";
exit(0);
} else {
echo "<br>Login Fail<br>";
exit(0);
}

ldap_close($conn);
} else {
echo "Could not connect to server";
exit(0);
}
} else {//if not null
if(!empty($_POST['log'])){
if(empty($_POST['user'])) echo "<br>no user input";
if(empty($_POST['pass'])) echo "<br>no password input";
}
}
?>

Posted in: php

 

Confirmation popup using javascript

April 6, 2008
rais

Hi,

Just write in your HTML code ;)

<script type="text/JavaScript">
confirm('Are You \nSure?')
</script>

Posted in: Javascript

 

Changing your website background using button

March 12, 2008
rais

Salam,

Maybe You still searching how to changing your website background color using button?
You can try this below javascript.

Sedang mencari button untuk dijadikan navigation terjumpa pula bagaimana nak tukar background website dengan menggunakan button dan javascript.

Boleh mencuba seperti kod di bawah.

<FORM>
<INPUT type="button" value="Change to Yellow!" name="button3" onClick="document.bgColor='yellow'">
</FORM>

Posted in: Javascript

 

Older Entries »