[MODDB] Steam Mod

A place for MOD Authors to post and receive feedback on MODs still in development. No MODs within this forum should be used within a live environment!
Suggested Hosts
eric0279
Registered User
Posts: 244
Joined: Fri Apr 13, 2007 9:22 pm

Re: [RC] Steam Mod

Post by eric0279 » Fri Nov 26, 2010 4:36 am


User avatar
Prosk8er
Registered User
Posts: 1444
Joined: Sun Mar 12, 2006 3:30 am
Location: Rochester, NY
Name: Tyler
Contact:

Re: [RC] Steam Mod

Post by Prosk8er » Fri Nov 26, 2010 5:13 am

already found a fix
*mod updated

if you have it installed already do the edits below
Open: styles/prosilver/template/memberlist_view.html
Find:

Code: Select all

			<div class="steam" style="border-top:none; margin-top: 0;"><a href="http://steamcommunity.com/id/{STEAM}"><img src="http://steamprofile.com/profile/extended/steam/{STEAM}.png" border="0" /></a></div>
Replace With:

Code: Select all

			<div class="steam" style="border-top:none; margin-top: 0;"><a href="http://steamcommunity.com/id/{STEAM}"><img src="http://badges.steamprofile.com/profile/extended/steam/{STEAM}.png" border="0" /></a></div>
Open: styles/prosilver/template/viewtopic_body.html
Find:

Code: Select all

  			<!-- IF postrow.U_STEAM --><a href="http://steamcommunity.com/id/{postrow.U_STEAM}"><img src="http://steamprofile.com/profile/simple/steam/{postrow.U_STEAM}.png" border="0" width=160 height=45 /></a><!-- ENDIF -->
Replace With:

Code: Select all

  			<!-- IF postrow.U_STEAM --><a href="http://steamcommunity.com/id/{postrow.U_STEAM}"><img src="http://badges.steamprofile.com/profile/simple/steam/{postrow.U_STEAM}.png" border="0" width=160 height=45 /></a><!-- ENDIF -->
Open: styles/subsilver2/template/memberlist_view.html
Find:

Code: Select all

					<div class="steam" style="border-top:none; margin-top: 0;"><a href="http://steamcommunity.com/id/{STEAM}"><img src="http://steamprofile.com/profile/extended/steam/{STEAM}.png" border="0" /></a></div>
Replace With:

Code: Select all

					<div class="steam" style="border-top:none; margin-top: 0;"><a href="http://steamcommunity.com/id/{STEAM}"><img src="http://badges.steamprofile.com/profile/extended/steam/{STEAM}.png" border="0" /></a></div>
Open: styles/subsilver2/template/viewtopic_body.html
Find:

Code: Select all

			<!-- IF postrow.U_STEAM and S_USER_LOGGED_IN -->&nbsp;<a href="http://steamcommunity.com/id/{postrow.U_STEAM}"><img src="http://steamprofile.com/profile/simple/steam/{postrow.U_STEAM}.png" border="0" width=160 height=45 /></a><!-- ENDIF -->
Replace With:

Code: Select all

			<!-- IF postrow.U_STEAM and S_USER_LOGGED_IN -->&nbsp;<a href="http://steamcommunity.com/id/{postrow.U_STEAM}"><img src="http://badges.steamprofile.com/profile/simple/steam/{postrow.U_STEAM}.png" border="0" width=160 height=45 /></a><!-- ENDIF -->

User avatar
Gazanimal
Registered User
Posts: 106
Joined: Wed Jun 22, 2005 5:15 pm
Contact:

Re: [RC] Steam Mod

Post by Gazanimal » Fri Nov 26, 2010 7:14 pm

When I run the db_update.php on my local testboard & also via my web testboard it says I don't have access to run the update even though I am logged in as an Admin.

All edits are done, but I can't run the update.php

Can you tell me the SQL code so I can manually run it in phpMyAdmin

Cheers.
Image

User avatar
Prosk8er
Registered User
Posts: 1444
Joined: Sun Mar 12, 2006 3:30 am
Location: Rochester, NY
Name: Tyler
Contact:

Re: [RC] Steam Mod

Post by Prosk8er » Fri Nov 26, 2010 9:01 pm

^here you go

Code: Select all

ALTER TABLE phpbb_users ADD user_steam VARCHAR( 255 ) NOT NULL DEFAULT '';

User avatar
Gazanimal
Registered User
Posts: 106
Joined: Wed Jun 22, 2005 5:15 pm
Contact:

Re: [RC] Steam Mod

Post by Gazanimal » Fri Nov 26, 2010 10:34 pm

bprsk8r4272 wrote:^here you go

Code: Select all

ALTER TABLE phpbb_users ADD user_steam VARCHAR( 255 ) NOT NULL DEFAULT '';
Cheers!
Image

eric0279
Registered User
Posts: 244
Joined: Fri Apr 13, 2007 9:22 pm

Re: [RC] Steam Mod

Post by eric0279 » Mon Nov 29, 2010 5:32 am

Thanks !

and how to make this field required registration?

User avatar
Prosk8er
Registered User
Posts: 1444
Joined: Sun Mar 12, 2006 3:30 am
Location: Rochester, NY
Name: Tyler
Contact:

Re: [RC] Steam Mod

Post by Prosk8er » Mon Nov 29, 2010 5:34 pm

eric0279 wrote:Thanks !

and how to make this field required registration?
i'll look in to this later on today

eric0279
Registered User
Posts: 244
Joined: Fri Apr 13, 2007 9:22 pm

Re: [RC] Steam Mod

Post by eric0279 » Sat Dec 04, 2010 5:50 am

Hello,

And how to make it mandatory after the members are enrolled (forced users to edit their profile) :?:

User avatar
Mess
Registered User
Posts: 985
Joined: Wed Jul 01, 2009 6:37 am
Name: Kim

Re: [RC] Steam Mod

Post by Mess » Sat Dec 04, 2010 2:32 pm

eric0279 wrote:Hello,

And how to make it mandatory after the members are enrolled (forced users to edit their profile) :?:
http://www.phpbb.com/community/viewtopi ... &t=1726675

:)

User avatar
Prosk8er
Registered User
Posts: 1444
Joined: Sun Mar 12, 2006 3:30 am
Location: Rochester, NY
Name: Tyler
Contact:

Re: [RC] Steam Mod

Post by Prosk8er » Sat Dec 04, 2010 6:12 pm

eric0279 wrote:Thanks !

and how to make this field required registration?
sorry havent had time to look into that yet i'll try to get to it soon
*i got it done thanks to this post http://www.phpbb.com/community/viewtopi ... 6&t=598049 and tested it
*i'll add this to the download as a option in the contrib folder later

open: includes/ucp/ucp_register.php
Find:

Code: Select all

		$cp = new custom_profile();
After Add:

Code: Select all

		// steam mod
		$user->add_lang('mods/steam');
Find:

Code: Select all

		$data = array(
			'username'			=> utf8_normalize_nfc(request_var('username', '', true)),
			'new_password'		=> request_var('new_password', '', true),
After Add:

Code: Select all

// Steam Required For Registration
			'steam'				=> request_var('steam', '', true),
// Steam Required For Registration
Find:

Code: Select all

				'password_confirm'	=> array('string', false, $config['min_pass_chars'], $config['max_pass_chars']),
				'email'				=> array(
					array('string', false, 6, 60),
					array('email')),
				'email_confirm'		=> array('string', false, 6, 60),
After Add:

Code: Select all

// Steam Required For Registration
				'steam'				=> array('string', false, 2, 60),
// Steam Required For Registration
Find:

Code: Select all

				$user_row = array(
					'username'				=> $data['username'],
					'user_password'			=> phpbb_hash($data['new_password']),
					'user_email'			=> $data['email'],
After Add:

Code: Select all

// Steam Required For Registration
					'user_steam'            => $data['steam'],
// Steam Required For Registration
Find:

Code: Select all

		$template->assign_vars(array(
			'ERROR'				=> (sizeof($error)) ? implode('<br />', $error) : '',
			'USERNAME'			=> $data['username'],
			'PASSWORD'			=> $data['new_password'],
			'PASSWORD_CONFIRM'	=> $data['password_confirm'],
After Add:

Code: Select all

// Steam Required For Registration
			'STEAM'				=> $data['steam'],
			'STEAM_EXPLAIN'		=> sprintf($user->lang['STEAM_EXPLAIN'], '<a href="' . append_sid("{$phpbb_root_path}faq.$phpEx") . '">', '</a>'),
// Steam Required For Registration
Open: styles/prosilver/template/ucp_register.html
Find:

Code: Select all

	<dl>
		<dt><label for="password_confirm">{L_CONFIRM_PASSWORD}:</label></dt>
		<dd><input type="password" tabindex="5" name="password_confirm" id="password_confirm" size="25" value="{PASSWORD_CONFIRM}" class="inputbox autowidth" title="{L_CONFIRM_PASSWORD}" /></dd>
	</dl>
After Add:

Code: Select all

	<dl>
		<dt><label for="steam">{L_STEAM}:</label><br /><span>{STEAM_EXPLAIN}</span></dt>
		<dd><input type="text" name="steam" id="steam" size="25" maxlength="255" value="{STEAM}" class="inputbox autowidth" title="{L_STEAM}" /></dd>
	</dl>
Open: styles/subsilver2/template/ucp_register.html
Find:

Code: Select all

<tr>
	<td class="row1"><b class="genmed">{L_CONFIRM_PASSWORD}: </b></td>
	<td class="row2"><input class="post" type="password" name="password_confirm" size="25" value="{PASSWORD_CONFIRM}" /></td>
</tr>
After Add:

Code: Select all

<tr>
	<td class="row1"><b class="genmed">{L_STEAM}: </b><br /><span class="gensmall">{STEAM_EXPLAIN}</span></td>
	<td class="row2"><input class="post" type="text" name="steam" size="25" maxlength="255" value="{STEAM}" /></td>
</tr>
Last edited by Prosk8er on Sat Dec 04, 2010 7:40 pm, edited 1 time in total.

User avatar
Prosk8er
Registered User
Posts: 1444
Joined: Sun Mar 12, 2006 3:30 am
Location: Rochester, NY
Name: Tyler
Contact:

Re: [RC] Steam Mod

Post by Prosk8er » Sat Dec 04, 2010 7:40 pm

Mess wrote:
eric0279 wrote:Hello,

And how to make it mandatory after the members are enrolled (forced users to edit their profile) :?:
http://www.phpbb.com/community/viewtopi ... &t=1726675

:)
yeah try that and let me know how it goes

eric0279
Registered User
Posts: 244
Joined: Fri Apr 13, 2007 9:22 pm

Re: [RC] Steam Mod

Post by eric0279 » Mon Dec 06, 2010 12:46 pm

I've done this part, it is only when members register on the forum to make the required field, I asked you how to force members already enrolled to complete the field SteamID.

Forcing editing the field SteamID for members already registered, do you understand?

User avatar
Mess
Registered User
Posts: 985
Joined: Wed Jul 01, 2009 6:37 am
Name: Kim

Re: [RC] Steam Mod

Post by Mess » Mon Dec 06, 2010 1:38 pm

eric0279 wrote:I've done this part, it is only when members register on the forum to make the required field, I asked you how to force members already enrolled to complete the field SteamID.

Forcing editing the field SteamID for members already registered, do you understand?
Did you try the link I gave you?

User avatar
Prosk8er
Registered User
Posts: 1444
Joined: Sun Mar 12, 2006 3:30 am
Location: Rochester, NY
Name: Tyler
Contact:

Re: [RC] Steam Mod

Post by Prosk8er » Mon Dec 06, 2010 3:03 pm

eric0279 wrote:I've done this part, it is only when members register on the forum to make the required field, I asked you how to force members already enrolled to complete the field SteamID.

Forcing editing the field SteamID for members already registered, do you understand?
you asked how to make it required by registartion a few posts up then you also asked how to force it for members which mess already answered

eric0279
Registered User
Posts: 244
Joined: Fri Apr 13, 2007 9:22 pm

Re: [RC] Steam Mod

Post by eric0279 » Mon Dec 06, 2010 6:34 pm

you asked how to make it required by registartion a few posts up
solved
then you also asked how to force it for members which mess already answered
Yes ;)

Locked

Return to “[3.0.x] MODs in Development”