Welcome, Guest. Please Login or Register.
May 14, 2025, 05:37:58 PM
Home Help Search Log in Register
News: If you are still using YaBB SE, please consider upgrading to SMF as soon as possible.

YaBB SE Community  |  Development  |  Mod Ideas and Creation  |  Requested: Three mods... « previous next »
Pages: 1 [2] Reply Ignore Print
Author Topic: Requested: Three mods...  (Read 5451 times)
Douglas
aka The Bear
Support Team
YaBB God
*****
Posts: 1050


Bears rule! Llamas rule too!

WWW
Re:Requested: Three mods...
« Reply #15 on: July 28, 2003, 05:52:37 PM »
Reply with quote

::chuckles::  Okay, that's not what I expected for the Hide Avatar and Hide Sig mod.  It hides mine from myself, however, I can see everyone else's, ROFL!
Logged

Need help? Please SEARCH first.  No need for a bad attitude, we like helping positive minded people.
ComeHit.us Short URL  redirection svcs with YSE powered forums, COMING SOON!
Want to say thanks?  Check out http://comehit.us/?u=3
Anguz
YaBB God
*****
Posts: 641


llama me?!

WWW
Re:Requested: Three mods...
« Reply #16 on: July 28, 2003, 06:39:10 PM »
Reply with quote

lol

you made me laugh Douglas  ;D
Logged

My Mods: Avatar & Sig Size Control, No Show Msg Subject, Msg URL Composer, Built-in Avatar Rand, Built-in Sig Rand, Remove New-lines Excess, Show All Stars, Search Bar, Smart URLs
Grudge
Global Moderator
Full Member
*****
Posts: 178


Damn llama's don't like me :(

Re:Requested: Three mods...
« Reply #17 on: July 28, 2003, 06:44:47 PM »
Reply with quote

doh!

Can you tell me:

Does it hide the sig and avatar regardless of what option you have selected in the profile or does it only hide them when you have the hige option selected?

Hopefully it's the last cause that should mean its an easy fix :D
Logged
Grudge
Global Moderator
Full Member
*****
Posts: 178


Damn llama's don't like me :(

Re:Requested: Three mods...
« Reply #18 on: July 28, 2003, 06:53:43 PM »
Reply with quote

Whoops - found the error!!!

Here's a full mod file for the last two mods Douglas requested. You will need to add the two columns to your database too though (as mentioned in my first post here)


<edit file>
sources/profile.php
</edit file>

<search for>
   $request = mysql_query("
      SELECT passwd, realName, emailAddress, websiteTitle, websiteUrl,

signature, posts, memberGroup, ICQ, AIM, YIM, gender, personalText, avatar,

dateRegistered, location, birthdate, timeFormat, timeOffset, hideEmail, ID_MEMBER,

usertitle, karmaBad, karmaGood, lngfile, MSN, secretQuestion, secretAnswer
</search for>

<add after>
,hideavs,hidesigs
</add after>

<search for>
   $memsettings = mysql_fetch_array($request);
</search for>

<add after>
$memsettings['hideavs'] = ($memsettings['hideavs'] == 1 ? ' checked' : '');
$memsettings['hidesigs'] = ($memsettings['hidesigs'] == 1 ? ' checked' : '');

</add after>

<search for>
                     <tr>
                        <td width="45%"><font

size="2"><b>' . $txt[721] . '</b></font></td>
                        <td><input type="checkbox"

name="hideemail"' . $memsettings['hideEmail'] . ' /></td>
                     </tr>';
</search for>

<add before>
<tr>
<td width="45%"><font size="2"><b>Hide Signatures?</b></font></td>
<td><input type="checkbox" name="hidesigs"' . $memsettings['hidesigs'] . ' /></td>
</tr>
<tr>
<td width="45%"><font size="2"><b>Hide Avatars?</b></font></td>
<td><input type="checkbox" name="hideavs"' . $memsettings['hideavs'] . ' /></td>
</tr>
</add before>

<search for>
      $hideEmail = 0;
      if (isset($member['hideemail']))
         $hideEmail = 1;
</search for>

<add after>
$hidesigs = 0;
if (isset($member['hidesigs']))
$hidesigs = 1;
$hideavs = 0;
if (isset($member['hideavs']))
$hideavs = 1;

</add after>

<search for>
         SET $queryPasswdPart $customTitlePart realName='$member[name]',

emailAddress='$member[email]', websiteTitle='$member[websitetitle]',

websiteUrl='$member[websiteurl]', signature='$member[signature]',

posts=$member[settings6], memberGroup='$member[settings7]', ICQ='$member[icq]',

MSN='$member[msn]', AIM='$member[aim]', YIM='$member[yim]', gender='$member[gender]',

personalText='$member[usertext]', avatar='$member[userpic]',

$member[dr]location='$member[location]', birthdate='$member[bday]',

lngfile='$member[language]', " . ($username == $member['user'] ? "memberIP='$memIP', " :

'') . "timeFormat='$member[usertimeformat]', timeOffset=$timeOffest,

secretQuestion='$member[secretQuestion]', secretAnswer='$member[secretAnswer]',

hideEmail=$hideEmail$karmaStr
</search for>

<add after>
,hidesigs=$hidesigs,hideavs=$hideavs
</add after>

<edit file>
sources/load.php
</edit file>

<search for>
      $request = mysql_query("SELECT passwd, realName, emailAddress,

websiteTitle, websiteUrl, signature, posts, memberGroup, ICQ, AIM, YIM, gender,

personalText, avatar, dateRegistered, location, birthdate, timeFormat, timeOffset,

hideEmail, ID_MEMBER, memberName, MSN, lngfile FROM {$db_prefix}members WHERE

ID_MEMBER='$username' LIMIT 1;") or database_error(__FILE__, __LINE__);
</search for>

<replace>
      $request = mysql_query("SELECT passwd, realName, emailAddress,

websiteTitle, websiteUrl, signature, posts, memberGroup, ICQ, AIM, YIM, gender,

personalText, avatar, dateRegistered, location, birthdate, timeFormat, timeOffset,

hideEmail, ID_MEMBER, memberName, MSN, lngfile,hideavs,hidesigs FROM {$db_prefix}members

WHERE ID_MEMBER='$username' LIMIT 1;") or database_error(__FILE__, __LINE__);
</replace>

<edit file>
sources/display.php
</edit file>

<search for>
      $userinfo =
               $usernamelink . '<br />
               <font size="1">
</search for>

<add before>
   if($settings[24]>0)
      $userprofile[$mname]['avatar']='';
   if($settings[25]>0)
      $userprofile[$mname]['signature']='';
</add before>


Sorry for going around the block a few times on this one - that's what I get for not testing this stuff :D
« Last Edit: July 28, 2003, 07:57:47 PM by Grudge » Logged
Douglas
aka The Bear
Support Team
YaBB God
*****
Posts: 1050


Bears rule! Llamas rule too!

WWW
Re:Requested: Three mods...
« Reply #19 on: July 28, 2003, 11:08:14 PM »
Reply with quote

I'm LOVING this Mod, THANK YOU, GRUDGE!
Logged

Need help? Please SEARCH first.  No need for a bad attitude, we like helping positive minded people.
ComeHit.us Short URL  redirection svcs with YSE powered forums, COMING SOON!
Want to say thanks?  Check out http://comehit.us/?u=3
Pages: 1 [2] Reply Ignore Print 
YaBB SE Community  |  Development  |  Mod Ideas and Creation  |  Requested: Three mods... « previous - next »
 


Powered by MySQL Powered by PHP YaBB SE Community | Powered by YaBB SE
© 2001-2003, YaBB SE Dev Team. All Rights Reserved.
SMF 2.1.4 © 2023, Simple Machines
Valid XHTML 1.0! Valid CSS

Page created in 0.168 seconds with 20 queries.