Advertisement
P22DX

Byksw Terjemah

Mar 21st, 2018
240
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.78 KB | None | 0 0
  1. <?php
  2. function terjemah() {
  3.     echo '
  4.     <center>
  5.     <form method="post">
  6.     <h2>Normal</h2>
  7.     <textarea name="text"></textarea><br />
  8.     <input type="submit" name="submit" value="terjemah" />
  9.     </form>
  10.     <h2>Autis</h2>
  11.     <textarea readonly>';
  12. if($_POST["submit"] == "terjemah") {
  13.     $text=$_POST["text"];
  14.     $output=str_replace("e","w",$text);
  15.     $output2=str_replace("o","w",$output);
  16.     $output3=str_replace("a","w",$output2);
  17.     $output4=str_replace("u","w",$output3);
  18.     $output5=str_replace("i","y",$output4);
  19.     // huruf gede
  20.     $output6=str_replace("E","W",$output5);
  21.     $output7=str_replace("O","W",$output6);
  22.     $output8=str_replace("A","W",$output7);
  23.     $output9=str_replace("U","W",$output8);
  24.     $output10=str_replace("I","Y",$output9);
  25.     echo $output10;
  26.     }
  27. echo "</textarea></center>";
  28. }
  29. terjemah();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement