$id = $_GET['openid_identity']; $url = "/^http:\\/\\/steamcommunity\\.com\\/openid\\/id\\/(7[0-9]{15,25}+)\$/"; preg_match($url, $id, $match); $_SESSION['steam'] = $match[1]; header('Location: ' . $_GET['openid_return_to']); } return true; } else { if (isset($_GET['openid_identity']) && !empty($_GET['openid_identity'])) { header('Location: ' . $_GET['openid_return_to']); } return false; } } } steam::auth() ? steam::login() : ""; class steamInfo { public static $steamid; public static $username; public static $avaFll; public static $avaMed; public static $avaSml; public function __construct() { $this::$steamid = $_SESSION['steam']; $xml = simplexml_load_string(file_get_contents("http://steamcommunity.com/profiles/" . $this::$steamid . "?xml=1")); $this::$username = $xml->steamID; $this::$avaFll = $xml->avatarFull; $this::$avaMed = $xml->avatarMedium; $this::$avaSml = $xml->avatarIcon;