LIPIA
Didalam Katagori: Ngalor-Ngidul
Salah satu keinginan ku yang sampai saat ini belum tercapai adalah…. "Pengen Kuliah di Lipia"
Didalam Katagori: Ngalor-Ngidul
Salah satu keinginan ku yang sampai saat ini belum tercapai adalah…. "Pengen Kuliah di Lipia"
Didalam Katagori: Aktual, CSS
Bismillah…
Masalah jadul yang biasanya ditemui web designer adalah seputar CSS yang tidak bisa crossing browser, khususnya kalo sudah ketemu sma IE (Internet Explorer 6). sebenarnya standarisasi javascript sudah mulai diterapkan di berbagai browser (Firefox, Opera, Safari, IE
versi terbaru. namun karena IE 6 lebih dulu booming dikalangan pengguna komputer mau tidak mau masalah crossing browser harus tetap menjadi perhatian.
Menurut statistik berbagai tracker web, IE 6 masih menempati posisi terbesar ke-dua setelah firefox. Nah sudah cukup basa basinya.
Mari Kita mulai tutorial pertama bagaimana cara meng-hacks CSS di IE 6.
perhatikan CSS berikut:
.merah{
color:red;
}
simpan script css diatas dengan nama style.css
lalu berikutnya buat file dengan nama misal:ie-hacks.html dan isi dengan script dibawah ini:
<html>
<head>
<title>IE 6++ Hacks Tutorial</title>
<link style="text/css" rel="stylesheet" href="style.css" />
</head>
<body>
<span class="merah">
HALLO DUNIA!!
</span>
</body>
</html>
Ketika file ie-hacks.html itu dibuka dengan firefox/ opera/ chrome maka akan menampulkan tulisan HALLO DUNIA!! dengan warna merah, begitu juga ketika di buka di IE (baik IE 6 atau yang terbaru).
Nah sekarang coba anda lakukan modifikasi di file style.css, menjadi seperti dibawah ini:
.merah{
color:red;
*color:blue;
}
Bagaimana hasilnya ketika di buka dengan browser (firefox/opera/chrome) dan IE??
di browser yang sudah standarisasi CSS (firefox/opera/chrome) warna tulisan HALLO DUNIA!! adalah merah, tapi ketika anda buka melalui IE, warna tulisan tersebut adalah biru
, kita bisa melakukan IE hacks dengan bantuan tanda Asterik (*).
Cara ini juga bisa diterapkan pada penamaan selector. misal:
.merah {
color:red;
}*.merah{
color:blue;
}
atau bisa juga
Jangan malas untuk mencoba ya!! soalnya… saya males bikin demonya#merah{
color:red;
}*#merah{
color:red;
}
Comments (0)Mungkin itu dulu aja, semoga bermanfaat…
![]()
Didalam Katagori: Uncategorized, Ngalor-Ngidul, kerja keras adalah energi kita
Pertamina sudah menjadi bagian dari Indonesia, Pertamina selalu menjadi sumber untuk mendapatkan BBM (itu bagi saya pribadi), walaupun kini bermunculan POM BBM lain dari luar, pertamina menurut saya pribadi tetap menjadi pilihan utama? kenapa??????
Mungkin itu sekelumit hal yang saya rasakan
Namun mungkin ada beberapa hal yang harus diwaspadai, karena semakin hari BBM akan semakin susah didapatkan, mungkin kepada pihak pertamina untuk mengupayakan bagaimana supaya bisa menghemat BBM, menggunakannya secara efektif dan efisien tapi hal ini juga bukan hanya dari pihak pertamina lho mungkin lebih tepatnya kepada seluruh warga yang menggunakannya, entah bagaimana caranya saya tidak tahu, tapi yang penting hal ini mulai dari pribadi saya sendiri dulu ..he..he..
dan juga yang baca artikel ini ![]()
dan satu lagi harapan pribadi saya, sekali lagi mudah-mudahan pertamina lebih bermanfaat lagi bagi semua yang menggunakannya. karena pertamina adalah hasil kerja keras kita (khusunya Bangsa Indonesia), sehingga hal itu akan terus menjadi energi bagi kita.
semoga bermanfaat…
Comments (3)Didalam Katagori: Internet
Salah satu tantangan bagi seorang web developer ketika membuat sistem, adalah kemampuan security yang handal, handal bukan berarti kuat dan tidak dapat dihack,,, dikatakan dalam sebuah buku tentang security, tingkat keamanan sebuah sistem dikatakan sangat aman ketika,
membutuhkan usaha, tenaga, waktu yang sangat besar untuk menghacknya bagi seorang hacker (cracker lebih cocoknya)
tidak ada satupun sistem yang aman didunia ini, kalau pun ada, maka itu bisa terjadi bila sebuah PC/ Komputer disimpan disebuah lemari besi, dikunci dengan kunci yang sangat kuat, kemudian dimasukan ke ruangan baja yang dikunci dengan kunci lebih kuat lalu dijaga oleh ratusan tentara
, dan putus koneksi internet didalamnya. (itu baru dikatakan aman 100% dari cracker), so, tidak ada sistem yang aman.
kemanan selalu berbanding terbalik dengan kenyamanan
hal ini seakan-akan menjadi rumus yang belum bisa terbantahkan, tanya kenapa?? atau barangkali ada yang tahu? silahkan share ![]()
Salah satu serangan yang dilakukan para cracker adalah DDOS, (Distributed Deniel of Service), adalah paket data2 yang dikirim ke server target dengan jumlah besar sehingga menyebabakan lalu lintas komputer target down biasanya menggunakan paket-paket SYN untuk melakukan serangan DDOS.
Jenis Serangan lainnya diantaranya adalah SQL Injection, ini adalah semacam kegiatan dengan menggunakan script atau perintah tertentu yang menyebabkan sebuah website/ target terupdate databasenya. jadi intinya databasenya di inject. sehingga kontentnya bisa diubah, dan biasanya cracker mengubah tampilan awal sebuah website.
jenis serangan pertama DDOS, bisa diatasi dengan meingnstall beberapa tools keamanan untuk mencegah serangan DDOS, sementara SQL Injection bisa dicegah dengan mengupdate script website (dan ini bisanya dilakukan oleh developer web itu sendiri atau yang bertanggun jawab terhadap aplikasi tersebut)
beberapa hal lain yang bisa digunakan untuk mencegah DDOS Attack:
Sumber http://id.wikipedia.org/wiki/Serangan_DoS
Comments (0)
Didalam Katagori: Uncategorized, Javascript
dalam javascript dikenal istilah Event, atau suatu aturan yang menangani semua interaksi user dengan aplikasi, dalam hal ini website.
salah satu event yang sering digunakan adalah onload().
silahkan lihat contoh pada script berikut:
<html>
<head>
<title>DOM</title>
</head>
<body>
<div id="text">Hello World!</div>
<script type="text/javascript">
window.onload = function(){
alert(document.getElementById(’text’).innerHTML);
}
</script>
</body>
</html>
script diatas akan menghasilkan prompt alert "Hello World"
sekarang kembali ke judul artikel ini, kita akan mengetahui dimana letak perbedaan antara menggunakan event window.onload() dengan yang tidak menggunakannya. perhatikan contoh dibawah yang tidak menggunakan event onload():
<html>
<head>
<title>DOM</title>
</head>
<body>
<div id="text">Hello World!</div>
<script type="text/javascript">
alert(document.getElementById(’text’).innerHTML);
</script>
</body>
</html>
Ternyata hasilnya tetap sama, dengan script sebelumnya (yang menggunakan event window.onload()), nah lalu dimana letak perbedaannya??
Oke sekarang perhatikan contoh selanjutnya:
<html>
<head>
<title>DOM</title>
</head>
<body>
<script type="text/javascript">
alert(document.getElementById(’text’).innerHTML);
</script>
<div id="text">Hello World!</div>
</body>
</html>
pada script diatas, posisi tag div saya pindahkan dibawah tag script, dan perhatikan bahwa script tersebut tanpa menggunakan event window.onload();, lihat bagaimana hasilnya??
YA! benar, hasilnya adalah error
document.getElementById("text") is null
tag dengan ID text tidak terdeteksi oleh script tersebut, itu dikarenakan letaknya tidak urut, karena secara default javascript akan diproses oleh browser dari atas ke bawah, Nah gimana?? ![]()
Untuk memperjelas perbedaannya (nya => judul ) , perhatikan (atau kalo gak males dicoba
) sekali lagi script dibawah,
<html>
<head>
<title>DOM</title>
</head>
<body>
<script type="text/javascript">
window.onload = function(){
alert(document.getElementById(’text’).innerHTML);
}
</script>
<div id="text">Hello World!</div>
</body>
</html>
script diatas saya tambahi event window.onload(). lihat hasilnya!!
kesimpulan :
Didalam Katagori: Javascript
Hari hari antara awal oktober hingga artikel ini ditulis, saya pribadi merasakan hari ini berbolak-balik, sering gak merasa puas dengan metode pemrograman yang saya pake, padahal sering improvisasi, tapi tetap saja belum merasakan kepuasan dengan beberapa framework yang saya kembangkan sendiri,
Akhirnya tanggal 14 Oktober kemarin, saya iseng2 mencoba mempelajari javascript OOP secara pure, tanpa pake framework JS apapun, karena awalnya saya biasa pake jQuery setelah memutuskan beralih dari prototype .
<script type="text/javascript">
// Person adalah nama Class beserta constructornya
function Person(){
this.name = "Didin Nurdin Ahmadi";
this.age = function(a){
return a;
}
}
Person.prototype.School = function(alamat){
this.Alamat = function(alamat){
return (alamat) ? alamat : "Margonda";
}
return "MI";
}
Person.prototype.Age = function(){
return (new Person().age(5));
}</script>
Potongan script diatas adalah implementasi OOP secara simple dengan javascript. Class tersebut bernama class Person, walaupun kelihatannya seperti function biasa, perlu diketahui, javascript mempunyai beberapa cara untuk membuat Class, dan salah satunya adalah dengan cara yang saya pakai.
perintah prototype berguna untuk meregister function/ method/ property ke dalam Class , sehingga penggunaannya adalahClassName.prototype.method = function(){
}
Selain dengan sintax prototype, register methode kedalam sebuah object bisa juga dengan menggunakan
this.method = function(){
}
bedanya, penggunaan kata this ini harus ada di dalam scope function.object. misalnya:
Person.prototype.School = function(alamat){
this.Alamat = function(alamat){
return (alamat) ? alamat : "Margonda";
}
return "MI";
}
Pada potongan script diatas, kita tahu bahwa dalam method School ada sebuah function/ methode lagi yang bernalam Alamat(arg);
Kedudukan methode Alamat() sama dengan School(), walaupun kelihatannya methode Alamat() berada didalam methode School(), itu karena rujukan this kembali ke Object Person (dalam contoh ini). jadi jika ingin mengakses method Alamat(), caranya sama dengan School(). misal:
man = new Person();
document.write(man.Alamat() + "<br/>");
document.write(man.School() + "<br/>");
dari Class Person yang telah dibuat diatas, kita bisa mengetahui methode/property apa saja yang ada didalamnya, kita bisa melihatnya dengan menggunakan funcion for in:
man = new Person();
for(a in man){
document.write(a + " = " +man[a] + "<br>");
}
OK sekian dulu, semoga bermanfaat…
Comments (0)
Didalam Katagori: JQuery
Bismillah…
Jquery merupakan framework javascript yang sampai saat ini paling banyak plugin-nya dibanding framework lain seperti mootols, prototype, dojo, dll.
diantara bagian penting jQuery (core), adalah function each.
each ini akan mengeksekusi elemen-elemen yang telah didefinisikan sebelumnya.
misal:
jQuery("p") .each(function(){
this.style.fontWeight = ‘bold’;
});
script diatas akan memproses semua tag html P , semua karakter diantara tag P akan ditebalkan.
misal lain:
var data = ["Bandung", "Jakarta", "Surabaya", "Malang"];
jQuery.each(data,function(key,kota){
alert("Saya jalan-jalan ke kota" + kota);
alert("Kota " + data[key] + " sangat indah");
});
pada script diatas, fungsi each lebih jelas sepert state foreach() di PHP, yakni semua element array data akan di extract satu persatu, sehingga akan membentuk proses perulangan sebanyak jumlah element array yang bersangkutan.
OK sekian dulu, insya allah disambung lagi nanti… silahkan komen kalo ada yang mau dishare
Comments (0)
Didalam Katagori: Uncategorized, referens
RFC2821 and RFC2822 state clearly that only 7bit ASCII characters are allowed in Internet mail addresses. The following list shows all the ASCII characters and explains whether they can or should be allowed in the local part of a mail address. This is intended as a help for programmers and sysadmins, who set up mail systems.
There is also a PDF version.
| 0-31 | 0x00-0x1f | Control chars | NO | Not allowed by RFC2822. |
| 32 | 0x20 | SPACE | NO | The SPACE character can be used in email addresses if quoted properly, but would be very confusing. Don’t use it. |
| 33 | 0x21 | ! | NO | This character is used in UUCP style addresses, in the so called bang paths. Example: host2 ! host1 ! user. Because there are still lots of mail systems who interpret this chars specially it should never be used in the local part of an email address. |
| 34 | 0x22 | " | NO | The double quotes are used for quoting. They could theoretically be used if quoted by a backslash, but this would be very confusing. Don’t use them. |
| 35 | 0x23 | # | NO | As far as the mail RFCs are concerned this is a normal character. But the hash sign is used in many configuration files to denote the beginning of a comment. Used in the configuration of most MTAs it would probably not work. Don’t use it. |
| 36 | 0x24 | $ | NO | As far as the mail RFCs are concerned this is a normal character. Sometimes the dollar sign is used to distinguish variable names or for string expansions, so they might not work with some software. Don’t use it. |
| 37 | 0x25 | % | NO | The percent sign is still in use for source routing in some systems. Although it is possible to use it in the local part of an email address, it might be interpreted specially by some email system. If it is used in a <mailto:> URL, it must be URL encoded. |
| 38 | 0x26 | & | MAYBE | As far as RFC2821 and RFC2822 are concerned this is a normal character. It is often used for company names like "Acme & Partners". Although this is hardly a reason, you may not want to use it, because the & sign is a UNIX shell special character. Another problem is that the & must be URL encoded when used in <mailto:> URLs. |
| 39 | 0x27 | ‘ | MAYBE | Commonly used for names like O’Reilly but might be dangerous because this character is often used for quoting, chances are it might get lost on the way. |
| 40-41 | 0x28-0x29 | ( and ) | NO | These chars are used in address header fields to denote comments. They are normally used to separate the email address from the real name of the sender or recipient. Example: ‘joe.doe@example.com (Joe Doe)’. RFC2822 allowes their use if they are inside double quotes, but this would be very confusing. Don’t use them in the local part. |
| 42 | 0x2a | * | MAYBE | The asterisk is widely used as a wild card character, often denoting "any local part" in a given domain. The use in an actual email address would preclude such a use. It is used by some mailing list servers to generate special addresses for detecting bounces. |
| 43 | 0x2b | + | OK | The plus sign is allowed in mail addresses and there is no reason not to use it. A common usage is for defining sub-addresses. Example: The user ‘joe’ with the mail address ‘joe@example.com’ can set up mail addresses like ‘joe+list@example.com’ if he needs more then one address. |
| 44 | 0x2c | , (comma) | NO | The comma is used in address header fields to separate email addresses from each other. Example: tarzan@jungle.org, jane@jungle.org. RFC2822 allowes their use if they are inside double quotes, but this would be very confusing. They are used in source routing, too. Don’t use them in the local part. |
| 45 | 0x2d | - (hyphen) | OK | Allowed in email addresses. Often used in mailing list addresses like list-request@example.com. Do not use as first character in email addresses, because it might look like a command line option to typical UNIX programs like sendmail. |
| 46 | 0x2e | . | OK | Allowed in email addresses. Often used for addresses with the format ‘firstname.lastname@example.com’. There is one restriction however: Two dots next to each other or a dot at the beginning or end of the local part are not allowed by RFC2822. The reason is that in RFC2822 the dot is used as a separator for tokenizing the mail address. Dots at the named locations would mean an empty token, which is not allowed. Still, there are people who use it. Some MTAs accept it, some don’t. |
| 47 | 0x2f | / | MAYBE | The forward slash is often used in email addresses used by X.400 gateways. Example: ‘PN=Joe/OU=X400/@gateway.com’. Because the slash is used as a directory separator in UNIX and other operating systems, it is probably not a good idea to use it in local parts. If you ever want to save the mail in a mailbox named after the local part, you will have problems. |
| 48-57 | 0x30-0x39 | 0-9 | OK | Allowed without restrictions. |
| 58 | 0x3a | : | NO | The colon is used in the source route syntax of RFC2821. Example: @mail.example.com:joe@sixpack.com. Although the colon is allowed if quoted properly, it could be very confusing. Don’t use it. |
| 59 | 0x3b | ; | NO | The semicolon could theoretically be used, but must be quoted. Because of this you should probably not use it. |
| 60 | 0x3c | < | NO | Used by RFC2821 and RFC2822 to enclose an email address. Example: <joe@sixpack.com>. Can be used if quoted, but would be very confusing. Don’t use it. |
| 61 | 0x3d | = | MAYBE | Really no reason not to use it. It is used by some mailing list servers to generate special addresses for detecting bounces. |
| 62 | 0x3e | > | NO | Used by RFC2821 and RFC2822 to enclose an email address. Example: <joe@sixpack.com>. Can be used if quoted, but would be very confusing. Don’t use it. |
| 63 | 0x3f | ? | MAYBE | If the question mark in an email address is used in a <mailto:> URL, it must be URL encoded. It could be confusing, because nobody expects it to be in an email address. Better not use it. |
| 64 | 0x40 | @ | NO | The @ is the separator between local part and domain. Can be used if quoted, but would be very confusing. Don’t use it. |
| 65-90 | 0x41-0x5a | A-Z | OK | Allowed without restrictions. |
| 91 | 0x5b | [ | NO | The [ can be used in email addresses if quoted properly, but would be confusing. Don’t use it. |
| 92 | 0x5c | \ | NO | The backslash is used for quoting special chars in RFC2821 and RFC2822. If it is used it must be quoted itself. Would be very confusing. Don’t use it. |
| 93 | 0x5d | ] | NO | The ] can be used in email addresses if quoted properly, but would be confusing. Don’t use it. |
| 94 | 0x5e | ^ | MAYBE | There is really no technical reason, why the caret should not be used, but it might be confusing for people, because it is sufficiently exotic that nobody would expect it to be part of an email address. |
| 95 | 0x5f | _ (underscore) | OK | Allowed without restrictions. Often used in mail addresses of the form firstname_lastname@example.com. |
| 96 | 0x60 | ` | NO | This character (the backtick) is used in shell scripting for executing an "embedded" command, inserting the output of this command and the place the command was found. This is very dangerous, if the command can be supplied by anybody. For this reason, many email systems will filter this character. Don’t use it. |
| 97-122 | 0x61-0x7a | a-z | OK | Allowed without restrictions. |
| 123 | 0x7b | { | MAYBE | There is really not much reason not to use this, although on the other hand, why should anyone want to have this in his email address. Could be confusing, because nobody expects it to be in an email address. |
| 124 | 0x7c | | | NO | The vertical bar (pipe symbol) is a UNIX shell special character used for combining commands into a pipe. In MTA config files it is often used to denote delivering into a program. Example: jane@jungle.com: | /usr/bin/vacation. Some MTAs will filter addresses with the pipe symbol, because it has been used in attacking email systems. Don’t use it. |
| 125 | 0x7d | } | MAYBE | There is really not much reason not to use this, although on the other hand, why should anyone want to have this in his email address. Could be confusing, because nobody expects it to be in an email address. |
| 126 | 0x7e | ~ | MAYBE | There is really no technical reason, why the tilde character should not be used, but it might be confusing for people, because it is sufficiently exotic that nobody would expect it to be part of an email address. |
| 127 | 0x7f | DEL | NO | Not allowed by RFC2822. |