Hmm, My cron.php is only 57 lines big? Am I misunderstanding something?
Hello, is it possible to adjust the size of the card in the user info box on messages? I'd like to increase (maybe double) the height to fit more text in.
Thanks!
<?php
/**
* This file is part of Steam Authentication for XenForo
*
* Written by Morgan Humes <morgan@lanaddict.com>
* Copyright 2012 Morgan Humes
*
* Steam Authentication for XenForo is free software: you can redistribute
* it and/or modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* Steam Authentication for XenForo is distributed in the hope that it
* will be useful, but WITHOUT ANY WARRANTY; without even the implied
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* See the GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SteamProfile. If not, see <http://www.gnu.org/licenses/>.
*/
class Steam_Cron {
public static function update() {
set_time_limit(0);
ignore_user_abort(1);
$options = XenForo_Application::get('options');
$gamestats = $options->steamGameStats;
if ($gamestats > 0)
{
$db = XenForo_Application::get('db');
$sHelper = new Steam_Helper_Steam();
$results = $db->fetchAll("SELECT user_id, steam_auth_id FROM xf_user_profile WHERE steam_auth_id > 0");
foreach($results as $row) {
$games = $sHelper->getUserGames($row['steam_auth_id']);
foreach($games as $id => $data) {
// game info
$db->query("INSERT IGNORE INTO xf_steam_games(game_id, game_name, game_logo, game_link) VALUES($id, '{$data['name']}', '{$data['logo']}', '{$data['link']}');");
// update
$r = $db->fetchRow("SELECT * FROM xf_user_steam_games WHERE user_id = {$row['user_id']} AND game_id = $id;");
if($r == NULL) {
// Insert
$db->insert("xf_user_steam_games", array('user_id'=>$row['user_id'], 'game_id'=>$id, 'game_hours'=>$data['hours'], 'game_hours_recent'=>$data['hours_recent']));
} else {
// Update
$db->query("UPDATE xf_user_steam_games SET game_hours = {$data['hours']}, game_hours_recent = {$data['hours_recent']} WHERE user_id = {$row['user_id']} AND game_id = $id;");
}
}
}
}
}
}
I'm answer: The true man decorates modesty. So, you're true man.Morgan laid the ground work, I just tidied up a little bit.
Pretty sure I am I even re downloaded your package from the resource manager and its the same. Even better, this is whats in the zip downloaded from the resource manager:
<snip>
I installed this but having a minor issue, mostly due to the image of the sign in button. I installed with TMS and have the social auth beta 2 in.
Issue:
http://i48.tinypic.com/2b18jc.jpg
How can i align the images correctly?
Also does anyone know where or how i can obtain the better sign in with steam image found in this post:
http://xenforo.com/community/threads/steam-authentication-integration.42694/page-10#post-494055
Hi,
i'm willing to install this add-on on my forum but i have some question.
What happens to existent users that have steam-ID account ? They could login using xenforo account OR steam account data ? What happen in xenforo ?
New users that already have a steam account must anyway create an xenforo account before using this mod, right ?
I'm not registered to Steam but one of my staff member is registered and already bought something so i guess he got an API KEY. Can i ask him the API KEY and use it in the forum ? Or API Key contain very confidential data related to the user account ?
Thanks in advance,
Not sure if it was a quirk of my forum, but the Steam tab didn't show up until I allowed all user groups to view statistics. It is all sorted and working now, great add-on!
Okay, thought I was crazy. Was not seeing it, couldn't find it. Finally decided to check permissions. Was in there. Are the API requests bad enough that I should turn it off any particular part?
We use essential cookies to make this site work, and optional cookies to enhance your experience.