在尝试让特定的页面使用SteamAuth来收集SteamID时,我遇到了很大的困难,但我不确定要将这些文件放在文件夹结构中的什么位置才能使其与Wordpress一起工作
只需要登录“商店”页面。
发布于 2020-05-02 18:05:50
从文档判断,我建议您将文件结构放在主题的根目录中,然后从functions.php文件中调用steamauth/steamauth.php以使其在您的站点上运行。
然后在登录页面上,使用其受密码保护的代码片段:
<?php
if(!isset($_SESSION['steamid'])) {
loginbutton(); //login button
} else {
include ('steamauth/userInfo.php'); //To access the $steamprofile array
//Protected content
logoutbutton(); //Logout Button
}
?>https://stackoverflow.com/questions/61553367
复制相似问题