Make Your Own Spoiler

Amy Munirah | Thursday, October 20, 2011 | 0Comments |
Assalamualaikum. esok ada ceramah sekolah teknik,na pergi ke tak ea. rasa macam malas,tapi pergi ja la,asek tak datang sekolah ja,nanti dapat surat baru tawu.hehe:)
hari ni amy na buat tuto spoiler macam gambar dekat bawah nih.
korang tengok gambar nih,ada paham ape-ape ke ? haha XD . act,spoiler ni fungsi dy untuk kemas kan blog. bila tekan,dy keluar anak-anak dy tuh:)
1) Mula-mula pergi dashboard->design->page element->add gadget->html/javascripts.
2) Ringankan tangan untuk copy code ni
<center><div id="spoiler"><div><input onclick="if (this.parentNode.parentNode.getElementsByTagName(&#39;div&#39;)[&#39;show&#39;].style.display != &#39;&#39;) { this.parentNode.parentNode.getElementsByTagName(&#39;div&#39;)[&#39;show&#39;].style.display = &#39;&#39;; this.parentNode.parentNode.getElementsByTagName(&#39;div&#39;)[&#39;hide&#39;].style.display = &#39;none&#39;; this.innerText = &#39;&#39;; this.value = &#39;Hide Spoiler!&#39;; } else { this.parentNode.parentNode.getElementsByTagName(&#39;div&#39;)[&#39;show&#39;].style.display = &#39;none&#39;; this.parentNode.parentNode.getElementsByTagName(&#39;div&#39;)[&#39;hide&#39;].style.display = &#39;&#39;; this.innerText = &#39;&#39;; this.value = &#39;Show Spoiler!&#39;; }" value="TITLE" style="width:200px;font-size:12px;background-image:url(URL BACKGROUND);-moz-border-radius: 25px 10px / 10px 25px; border-radius: 25px 10px / 10px 25px;margin:10px;padding:0px;border-style: 2px solid#000000;" type="button" /><div id="show" style="display: none; background-color:transparent; background-repeat:repeat; margin: 0px;border-width:0px; padding:3px; width:98%">KANDUNGAN<div id="hide"></div>
3) And paste dekat kotak html/javascripts tadi tu ye.
4) Then,boleh la save,senang je kan ? :D
NOTA KAKI:
  1. title ni tajuk korang punya spoiler ni la etc;CREDIT.
  2. url background ni background title. boleh cari dekat sini.
  3. kandungan ni pulak,dy punya anak-anak tu lah,bila tekan keluar la kandungannye.

Thank you for reading

0 comment(s):