forked from SmItH197/SteamAuthentication
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathexample.php
More file actions
29 lines (24 loc) · 698 Bytes
/
example.php
File metadata and controls
29 lines (24 loc) · 698 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<?php
require ('steamauth/steamauth.php');
# You would uncomment the line beneath to make it refresh the data every time the page is loaded
// $_SESSION['steam_uptodate'] = false;
?>
<html>
<head>
<title>page</title>
</head>
<body>
<?php
if(!isset($_SESSION['steamid'])) {
echo "welcome guest! please login \n \n";
steamlogin(); //login button
} else {
include ('steamauth/userInfo.php');
//Protected content
echo "Welcome back " . $steamprofile['personaname'] . "</br>";
echo "here is your avatar: </br>" . '<img src="'.$steamprofile['avatarfull'].'" title="" alt="" />'; // Display their avatar!
logoutbutton();
}
?>
</body>
</html>