Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function convert_steamid_to_accountid($steamid)
- {
- $toks = explode(":", $steamid);
- $odd = (int)$toks[1];
- $halfAID = (int)$toks[2];
- $authid = ($halfAID*2) + $odd;
- echo $authid;
- }
- <INPUT TYPE = "Text" VALUE ="ENTER STEAM:ID" NAME = "idform">
- <?PHP
- $_POST['idform'];
- $steamid = $_POST['idform'];
- ?>
- <form method="POST" action="foo.php">
- <input type="text" value="ENTER STEAM:ID" name="idform" />
- <input type="submit" />
- </form>
- <?php
- function convert_steamid_to_accountid($steamid)
- {
- $toks = explode(":", $steamid);
- $odd = (int)$toks[1];
- $halfAID = (int)$toks[2];
- $authid = ($halfAID*2) + $odd;
- echo $authid;
- }
- $id = $_POST['idform'];
- convert_steamid_to_accountid($id)
- ?>
- if ($_SERVER['REQUEST_METHOD']=='POST'){
- // your php code here that should be executed when the form is submitted.
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement