当前位置: 首页>>代码示例>>PHP>>正文


PHP steamlogin函数代码示例

本文整理汇总了PHP中steamlogin函数的典型用法代码示例。如果您正苦于以下问题:PHP steamlogin函数的具体用法?PHP steamlogin怎么用?PHP steamlogin使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了steamlogin函数的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: steamlogin

    <style>
        .table {
            table-layout: fixed;
            word-wrap: break-word;
        }
    </style>
  </head>
  <body style="background-color: #EEE;">
    <div class="container" style="margin-top: 30px; margin-bottom: 30px; padding-bottom: 10px; background-color: #FFF;">
		<h1>SteamAuth Demo</h1>
		<span class="small pull-left" style="padding-right: 10px;">for SteamAuth 2.3</span>
		<hr>
		<?php 
if (!isset($_SESSION['steamid'])) {
    echo "<div style='margin: 30px auto; text-align: center;'>Welcome Guest! Please log in!";
    echo steamlogin();
    echo "</div>";
} else {
    include 'steamauth/userInfo.php';
    echo "<div style='float:left;'><a href='https://github.com/SmItH197/SteamAuthentication'><button type='button' class='btn btn-success' style='margin: 2px 3px;'>GitHub Repo</button></a><a href='https://github.com/SmItH197/SteamAuthentication/releases'><button type='button' style='margin: 2px 3px;' class='btn btn-warning'>Download</button></a></div><br><br>\n\t<h4 style='margin-bottom: 3px; float:left;'>Steam WebAPI-Output:</h4><span style='float:right;'><a href='steamauth/logout.php'>Log out</a></span>\n\t<table class='table table-striped'><tr><td><b>Variable name</b></td><td><b>Value</b></td><td><b>Description</b></td></tr>\n\t<tr><td>\$steamprofile['steamid']</td><td>" . $steamprofile['steamid'] . "</td><td>SteamID64 of the user</td></tr>\n\t<tr><td>\$steamprofile['communityvisibilitystate']</td><td>" . $steamprofile['communityvisibilitystate'] . "</td><td>1 - Account not visible; 3 - Account is public (Depends on the relationship of your account to the others)</td></tr>\n\t<tr><td>\$steamprofile['profilestate']</td><td>" . $steamprofile['profilestate'] . "</td><td>1 - The user has a Steam Community profile; 0 - if not</td></tr>\n\t<tr><td>\$steamprofile['personaname']</td><td>" . $steamprofile['personaname'] . "</td><td>Public name of the user</td></tr>\n\t<tr><td>\$steamprofile['lastlogoff']</td><td>" . $steamprofile['lastlogoff'] . "</td><td><a href='http://www.unixtimestamp.com/' target='_blank'>Unix timestamp</a> of the user's last logoff</td></tr>\n\t<tr><td>\$steamprofile['profileurl']</td><td>" . $steamprofile['profileurl'] . "</td><td>Link to the user's profile</td></tr>\n\t<tr><td>\$steamprofile['personastate']</td><td>" . $steamprofile['personastate'] . "</td><td>0 - Offline, 1 - Online, 2 - Busy, 3 - Away, 4 - Snooze, 5 - looking to trade, 6 - looking to play</td></tr>\n\t<tr><td>\$steamprofile['realname']</td><td>" . $steamprofile['realname'] . "</td><td>\"Real\" name</td></tr>\n\t<tr><td>\$steamprofile['primaryclanid']</td><td>" . $steamprofile['primaryclanid'] . "</td><td>The ID of the user's primary group</td></tr>\n\t<tr><td>\$steamprofile['timecreated']</td><td>" . $steamprofile['timecreated'] . "</td><td><a href='http://www.unixtimestamp.com/' target='_blank'>Unix timestamp</a> for the time the user's account was created</td></tr>\n\t<tr><td>\$steamprofile['avatar']</td><td><img src='" . $steamprofile['avatar'] . "'><br>" . $steamprofile['avatar'] . "</td><td>Adress of the user's 32x32px avatar</td></tr>\n\t<tr><td>\$steamprofile['avatarmedium']</td><td style=''><img src='" . $steamprofile['avatarmedium'] . "'><br>" . $steamprofile['avatarmedium'] . "</td><td>Adress of the user's 64x64px avatar</td></tr>\n\t<tr><td>\$steamprofile['avatarfull']</td><td><img src='" . $steamprofile['avatarfull'] . "'><br>" . $steamprofile['avatarfull'] . "</td><td>Adress of the user's 184x184px avatar</td></tr>\n\t</table>";
}
?>
	<hr>
	<div class="pull-right"><i>This page is powered by <a href="http://steampowered.com">Steam</a></i></div>
	<a href="https://github.com/SmItH197/SteamAuthentication">GitHub Repo</a><br>
	Demo page by <a href="https://github.com/blackcetha" target="_blank">BlackCetha</a></div>
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
    <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.0/js/bootstrap.min.js"></script>
  </body>
</html>
开发者ID:GoeGaming,项目名称:SteamAuthentication,代码行数:30,代码来源:demo.php

示例2: steamlogin

    <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css">
	<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
	<script type="text/javascript" src="js/noty/packaged/jquery.noty.packaged.min.js"></script>
	<script src="js/main.js"></script>
</head>
<body>
		<header id="header">
		<div style="  width: 1100px;  margin: auto;">
			<strong class="logo"><a href="/"><?php 
echo $title;
?>
</a></strong>	 
			<div style="float: right;">
				<?php 
if (!isset($_SESSION["steamid"])) {
    steamlogin();
    //echo '<div style="display: inline-block; margin: 35px 90px 0 0; color: #eee; font-size: 12pt;"><a href=en.php><img src=img/en.gif></a><a href=ru.php><img src=img/ru.gif></a></div>';
    echo "<a class=\"btns\">ВОЙТИ С ПОМОЩЬЮ </a>";
    echo "<a class=\"btn\" href=\"?login\">" . $msg[$lang]["login2"] . "</a>";
} else {
    //echo '<div style="display: inline-block; margin: 35px 90px 0 0; color: #eee; font-size: 12pt;"><a href=en.php><img src=img/en.gif></a><a href=ru.php><img src=img/ru.gif></a>    '.$msg[$lang]["loggedin"].' sf</div>';
    echo '<div style="display: inline-block; margin: 35px 110px 0 0; color: #eee; font-size: 12pt;">' . $msg[$lang]["loggedin"] . ' ' . $steamprofile['personaname'] . ' </div><div style="display: inline-block; position: absolute; margin-top: 28px; margin-left: -100px "><img src="' . $steamprofile['avatar'] . '"></div>';
    echo "<a class=\"btn\" href=\"steamauth/logout.php\">" . $msg[$lang]["logout"] . "</a>";
    mysql_query("UPDATE users SET name='" . $steamprofile['personaname'] . "', avatar='" . $steamprofile['avatarfull'] . "' WHERE steamid='" . $_SESSION["steamid"] . "'");
}
?>
    		</div>
		</div>
	    </header>
	<div id="wrapper">
			<div id="main">
开发者ID:Gunboybr,项目名称:FireCSGO.ru,代码行数:31,代码来源:index.php

示例3: getLoginForm

 /**
  * @return string HTML
  */
 public function getLoginForm()
 {
     return steamlogin();
 }
开发者ID:kk222hk,项目名称:1DV449_kk222hk,代码行数:7,代码来源:SteamAuthModel.php


注:本文中的steamlogin函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。