Archive for the ‘Programming’ Category
Wednesday, October 22nd, 2008
![]()
The usage of quotation mark in script PHP very often we meet, maybe can be every script that we make existed the usage of quotation mark referred.
In PHP the usage of quotation mark differentiated between single quotation mark and double quote. This Difference is made not without meaning and its use each can we apply in a script PHP we so it’s make script PHP we become quicker execute its.
Single Quotation mark
Use single quotation mark just for strings that not existed variable in it, so strings that produced among quotation mark referred is same precisely ...
Posted in PHP | No Comments »
Monday, October 20th, 2008
![]()
This function randomizes the order of the elements in an array also used together with srand() function.
shuffle() example:
$ar_value = range('A','F'); // create and fill the elements of $sar_value = array('A','B',...'F');
echo "First value:
\n”;
WHILE(list($key,$value) = each($ar_value)){
echo “Index[ {$key} ] => $value
\n”;
}
echo “
\n”;
echo “After shuffle():
\n”;
srand((float)microtime()*1000000);
shuffle($ar_value);
WHILE(list($key,$value) = each($ar_value)){
echo “Index[ {$key} ] => $value
\n”;
}
And the result of the code above:
First value:
Index[ 0 ] => A
Index[ 1 ] => B
Index[ 2 ] => C
Index[ 3 ] => D
Index[ 4 ] => E
Index[ 5 ] => F
After shuffle():
Index[ 0 ] => C
Index[ 1 ] => B
Index[ 2 ] => ...
Posted in PHP | No Comments »
Sunday, October 19th, 2008
![]()
Apa sich teknologi web service itu? web service adalah sebuah sistem yang dirancang untuk dapat mendukung interaksi komunikasi antar mesin-mesin pada suatu jaringan (w3c.org). Teknologi web service memungkinkan kita dapat menghubungkan berbagai jenis software yang memiliki platform dan sistem operasi yang berbeda. Jadi, kita tetap mendapatkan sebuah potongan informasi dari suatu website tanpa harus mengunjungi website tersebut, cukup dengan mengetahui fungsi/method web service yang disediakan oleh web itu. Kita dapat mengakses potongan informasi itu dengan meletakkan fungsi/method itu pada aplikasi kita. Contoh penggunaan dari teknologi web service adalah pada mesin pencarian Google yang menyediakan tiga ...
Posted in PHP, Web Service | 2 Comments »