Membuat tulisan terbalik

denggi

freshman
Joined
Jun 25, 2008
Messages
114
Points
16
hi semua warga WC..

di sini saya nak kongsi kan macam mana nak buat tulisan terbalik. saya selalu gunakan ketika komen di facebook.mmg menarik bagi org penin nak baca..>:)
contoh:
selamat berpuasa -> ɐsɐndɹǝq ʇɐɯɐlǝs

Code:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Membuat Tulisan Terbalik</title>
<style type="text/css">
textarea { font-family: "Arial Unicode MS", terbalik }
</style>
<script language="JavaScript">
function flip() {
var result = flipString(document.f.original.value.toLowerCase());
document.f.flipped.value = result;
}
function flipString(aString) {
var last = aString.length - 1;
var result = new Array(aString.length)
for (var i = last; i >= 0; --i) {
var c = aString.charAt(i)
var r = flipTable[c]
result[last - i] = r != undefined ? r : c
}
return result.join('')
}
var flipTable = {
a : '\u0250',
b : 'q',
c : '\u0254',
d : 'p',
e : '\u01DD',
f : '\u025F',
g : '\u0183',
h : '\u0265',
i : '\u0131',
j : '\u027E',
k : '\u029E',
//l : '\u0283',
m : '\u026F',
n : 'u',
r : '\u0279',
t : '\u0287',
v : '\u028C',
w : '\u028D',
y : '\u028E',
'.' : '\u02D9',
'[' : ']',
'(' : ')',
'{' : '}',
'?' : '\u00BF',
'!' : '\u00A1',
"\'" : ',',
'<' : '>',
'_' : '\u203E',
'\\' : '/',
';' : '\u061B',
'\u203F' : '\u2040',
'\u2045' : '\u2046',
'\u2234' : '\u2235'
}
for (i in flipTable) {
flipTable[flipTable[i]] = i
}
</script>
</head>
<body linkifytime="0" linkified="0" linkifying="false">
<h1>Membuat Tulisan Terbalik</h1>
<form name="f">
Tulisan Asli: <br>
<textarea rows="6" cols="50" name="original" onkeyup="flip()"></textarea>

<br>
Tulisan Terbalik: <br>
<textarea rows="6" cols="50" name="flipped"></textarea>
</form>
</body>
</html>

1. copy code di atas ke notepad
2. then save sebagai namafile.php
3. run file yg di save tersebut dgn web browser anda.

SELAMAT MENCUBA!

Kredit kpd Finderonly.com
 
Last edited:

the_risks

freshman
Joined
Aug 15, 2010
Messages
147
Points
0
cuba bagi detail skit... tak berapa paham la... masi newbie lagi nie
 

the_risks

freshman
Joined
Aug 15, 2010
Messages
147
Points
0
ok2... saya da faham... save as .html pun leh kan....
ni hasilnya ---------------> &#592;&#670;&#592;&#670;&#592;&#670;&#592;&#670;&#592;&#670;&#592;&#670;&#592;&#670;&#592;&#653; &#729;&#729;&#729;&#729;&#670;&#305;l&#592;q&#633;&#477;&#647; &#592;s&#305;q &#592;pu&#592; &#670;&#592;&#647;o &#305;&#647;u&#592;u
&#729;&#729;&#729;&#305;u&#305; u&#592;s&#305;ln&#647; &#592;&#596;&#592;q &#670;&#305;&#654;s&#592; nl&#592;l&#633;&#477;&#647; u&#592;&#387;u&#592;&#638;
 

the_risks

freshman
Joined
Aug 15, 2010
Messages
147
Points
0
(= &#729;&#729;&#729;&#729;&#633;&#477;&#613;&#647;o&#633;q &#477;&#633;&#592;&#613;s &#477;&#596;&#305;u
 

faezil

Newbie
Joined
Oct 2, 2007
Messages
7,061
Points
38
ok2... saya da faham... save as .html pun leh kan....
ni hasilnya ---------------> &#592;&#670;&#592;&#670;&#592;&#670;&#592;&#670;&#592;&#670;&#592;&#670;&#592;&#670;&#592;&#653; &#729;&#729;&#729;&#729;&#670;&#305;l&#592;q&#633;&#477;&#647; &#592;s&#305;q &#592;pu&#592; &#670;&#592;&#647;o &#305;&#647;u&#592;u
&#729;&#729;&#729;&#305;u&#305; u&#592;s&#305;ln&#647; &#592;&#596;&#592;q &#670;&#305;&#654;s&#592; nl&#592;l&#633;&#477;&#647; u&#592;&#387;u&#592;&#638;
Ya..... save as html lebih mudah kerana jika save as php, kena upload ke server atau localhost.

Lagipun takde php code yang digunakan... hanya html dan js..... maka boleh save as html. boleh run terus dari pc tanpa upload ke Internet
 

mfahmi

Newbie
Joined
Dec 22, 2006
Messages
1,399
Points
36
&#729;&#729;&#729;&#729;&#592;l &#647;s&#477;q &#387;u&#592;&#623;&#477;&#623;&#729;&#729;&#729;&#592;&#613;&#592;&#613;&#592;&#613;
 

Abu Hanis

Senior
Joined
Oct 9, 2007
Messages
2,247
Points
38
&#305;&#387;&#387;u&#477;p pu&#592; uo&#305;&#1503;&#477;pu&#592;p no&#654; &#670;u&#592;&#613;&#647;
 

denggi

freshman
Joined
Jun 25, 2008
Messages
114
Points
16
kalau save as .php ..then open with web browser anda la..
save as .html pun boleh aje..:)
 
Last edited:

NasirBP

freshman
Joined
Jun 23, 2010
Messages
1,186
Points
0
ingatkan kacap terlabik ..rupe2nya ayat nya betul2 terbalik ..heheheh terpaksa la aku terbalikan lappy ni gak :D
 

lelouch

freshman
Joined
Aug 8, 2010
Messages
36
Points
0
&#729;&#729;&#729;o&#633;q &#387;u&#305;&#633;&#592;&#613;s &#633;o&#607; b&#647;&#729;&#729;&#729;&#613;&#592;l&#670;&#305;&#592;q&#633;&#477;&#647;&#729;&#729;&#729;&#592;&#613;&#592;&#613;
 
Top