LCKB
[Release] Potenz Calculator - Printable Version

+- LCKB (https://lckb.dev/forum)
+-- Forum: ** OLD LCKB DATABASE ** (https://lckb.dev/forum/forumdisplay.php?fid=109)
+--- Forum: Website Scripting & Security (https://lckb.dev/forum/forumdisplay.php?fid=197)
+---- Forum: Webmasters Help & Talk (https://lckb.dev/forum/forumdisplay.php?fid=142)
+---- Thread: [Release] Potenz Calculator (/showthread.php?tid=1326)



- xNiceEinz - 11-29-2012


Small Release!

 

Have done it for Fun, for a school Projekt for Math

 

Here is the Code

 

 

Please give me a Thanks if you like it

 

<form method="POST" action="potenz.php">
<input name="zahl1" size=6>
<select name="rz">
<option value="$">²</option>
</select>
<input name="zahl2" size=6><br>

<br>
<input type=submit name=submit value="Rechnen">
</form>
<?php
if (!empty($_POST["submit"])) {
$_zahl1 = $_POST["zahl1"];
$_zahl2 = $_POST["zahl2"];
$_rz = $_POST["rz"];
if ($_rz == "$") $c = bcpow($_zahl1, $_zahl2);
echo $_zahl1 . $_rz . $_zahl2 . " = " . $c;
} ?>