vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Signature Image System Hack - Version 3.0+... (https://vborg.vbsupport.ru/showthread.php?t=45310)

Chris M 04-20-2003 09:05 PM

@212rikanmofo :

Try searching for:

Code:

$signaturechecked[$bbuserinfo[signatureid]="checked";
Satan

C.Birch 04-20-2003 09:11 PM

anyone have any ideas why the sign's dont show for me in my topics?

212rikanmofo 04-21-2003 12:39 AM

hellsatan, nope it couldnt find that either... arghh, what gives... :(

kevinnguyen 04-25-2003 12:13 AM

just 4 words: "It ruined my site!"

LangTuDaTinh 04-25-2003 01:57 AM

HC, what's happen man...?

Chris M 04-25-2003 04:47 PM

I don't know why you get this problem, but other people do not:)

PHP Version perhaps?

Satan

Gemini 04-25-2003 09:31 PM

I am to find the following in member.php:

Quote:

=====
Find:
=====

$signaturechecked[$bbuserinfo[signatureid]="checked";
I cannot locate this code. I've looked for $signaturechecked in the hopes I could find some code that resembed what I am looking for, but cannot find it at all.

Suggestions... ?

Using VB 2.3.0

Edit: I cannot find anything related to signature in member.php with respects to what I am to find and replace. :(

212rikanmofo 04-26-2003 12:27 AM

gemini same here, i cannot find that anywhere, sigh... please help us out...

L-Mane 04-26-2003 03:58 AM

I just installed the hack and well it seems fine but when I goto my options to change my sig it says "The administrator has disabled the use of signature images." but in the CP I have the option for sigs turned on. Wasup wit this?

L-Mane 04-27-2003 03:01 PM

HELP

Gemini 04-28-2003 11:12 PM

bump...

LangTuDaTinh 05-04-2003 06:12 PM

LOOK FOR THIS
PHP Code:

        if ($post[showsignature] and $allowsignatures and trim($post[signature])!="" and ($bbuserinfo[userid]==or $bbuserinfo[showsignatures])) {
            if (!isset(
$sigcache["$post[userid]"])) {
                
$post[signature]=bbcodeparse($post[signature],0,$allowsmilies);
                eval(
"\$post[signature] = \"".gettemplate("postbit_signature")."\";");
                
$sigcache["$post[userid]"] = $post[signature];
            } else {
                
$post[signature] = $sigcache["$post[userid]"];

            }
        } else {

            
$post[signature] = "";
        } 



CHANGE TO THIS
PHP Code:


        
if ($post[showsignature] and $allowsignatures and trim($post[signature])!="" and ($bbuserinfo[userid]==or $bbuserinfo[showsignatures])) {
            if (!isset(
$sigcache["$post[userid]"])) {
                
$post[signature]=bbcodeparse($post[signature],0,$allowsmilies);
                eval(
"\$post[signature] = \"".gettemplate("postbit_signature")."\";");
                
$sigcache["$post[userid]"] = $post[signature];
            } else {
                
$post[signature] = '';
            }
        } else {
                if (
$signatureurl!="") {
                        eval(
"\$post[signature] = \"".gettemplate("postbit_signature")."\";"); 
                    }
        
//    $post[signature] = "";
        



as u ca see, i added a new code in the last "else" code and comment out the code in there

PHP Code:

                if ($signatureurl!="") {
                        eval(
"\$post[signature] = \"".gettemplate("postbit_signature")."\";"); 
                    } 

if there is any error , pls let me know
thanks

Dribbles 05-30-2003 01:49 AM

If you have a fairly large forum, does this hack negatively effect server load, etc?? thnx

Chris M 05-30-2003 08:37 AM

@Dribbles - Depending on the size of avatars allowed, post count required, number of users, the load will vary - Usually signature images are 100x400 at most, so imagine about 7 avatars per user (including their avatar) and then you will see how this can affect server load on a big board:)

@LangTuDaTinh - Thanks for that - That may correct lots of people's problems:D

@Gemini - You will have to add the references to signature into member.php:)

Satan

Dribbles 05-30-2003 12:34 PM

Hi ... avatar settings are 150x150 max dimensions with 20kb max size. I was thinking for sig images 100 max height with 400 max width. So the system is basically as taxing as the avatar system? (width and size allowances aside).

Chris M 05-30-2003 02:58 PM

As taxing if not potentially more or less...

Satan

007 06-01-2003 08:55 PM

Hey hellsatan, I tried making this "Lesane Store Compatible" which I assumed would be easy since it is done the same way as normal avatars, but for some reason users cannot upload their sigs when accessing this through the store???

Is there anything in this hack that is different from the standard avatar code besides replacing the word avatar with signature?

Thanks.

Chris M 06-02-2003 07:10 PM

Yes - It does use a modified version of my "Improved Avatar Settings" hack (for signatures obviously:p);)

That is about it really, apart from N9ne's template mods and a few bits of modified code in member.php:)

Satan

007 06-04-2003 04:58 AM

That could be it. Thanks. :)

Falkware 06-04-2003 06:21 PM

Call me stupid, but what file is this you're referring to? I went through all the files and couldn't find this, or part of it, anywhere. /boggle

Quote:

05-04-03 at 08:12 PM LangTuDaTinh said this in Post #212
LOOK FOR THIS
PHP Code:

        if ($post[showsignature] and $allowsignatures and trim($post[signature])!="" and ($bbuserinfo[userid]==or $bbuserinfo[showsignatures])) {
            if (!isset(
$sigcache["$post[userid]"])) {
                
$post[signature]=bbcodeparse($post[signature],0,$allowsmilies);
                eval(
"\$post[signature] = \"".gettemplate("postbit_signature")."\";");
                
$sigcache["$post[userid]"] = $post[signature];
            } else {
                
$post[signature] = $sigcache["$post[userid]"];

            }
        } else {

            
$post[signature] = "";
        } 



CHANGE TO THIS
PHP Code:


        
if ($post[showsignature] and $allowsignatures and trim($post[signature])!="" and ($bbuserinfo[userid]==or $bbuserinfo[showsignatures])) {
            if (!isset(
$sigcache["$post[userid]"])) {
                
$post[signature]=bbcodeparse($post[signature],0,$allowsmilies);
                eval(
"\$post[signature] = \"".gettemplate("postbit_signature")."\";");
                
$sigcache["$post[userid]"] = $post[signature];
            } else {
                
$post[signature] = '';
            }
        } else {
                if (
$signatureurl!="") {
                        eval(
"\$post[signature] = \"".gettemplate("postbit_signature")."\";"); 
                    }
        
//    $post[signature] = "";
        



as u ca see, i added a new code in the last "else" code and comment out the code in there

PHP Code:

                if ($signatureurl!="") {
                        eval(
"\$post[signature] = \"".gettemplate("postbit_signature")."\";"); 
                    } 

if there is any error , pls let me know
thanks


Chris M 06-04-2003 06:31 PM

I believe that is the functions.php file:)

Satan

Falkware 06-14-2003 03:50 PM

Thanks Satan ;)

And thanks LangTuDaTinh that fixed it! /bow

Chris M 06-16-2003 03:56 PM

No problems:)

Satan

tmapm 06-20-2003 02:50 AM

I tried installing this hack and I recieved this error. Can anyone help me out?

PHP Code:

mysql error number1054 

EDIT: Found my answer on page 10. Forogt to run:
ALTER TABLE user ADD signatureid smallint(6) NOT NULL

This hack is SWEET. Thanks for your hard work!

This didn't work for me:

Quote:

12-06-02 at 08:11 PM Palyntir said this in Post #136
found it. it was in usercp.php

the section beginning

// ############################### start signature ###############################

$bbuserinfo[signatureurl]=getsignatureurl($bbuserinfo[userid]);
if ($bbuserinfo[signatureurl]=="") {
$bbuserinfo[signatureurl]="http://images/clear.gif";
}

needed to be replaced with this:


// ############################### start signature ###############################

$bbuserinfo[signatureurl]=getsignatureurl($bbuserinfo[userid]);
if ($bbuserinfo[signatureurl]=="") {
$bbuserinfo[signatureurl]="images/clear.gif";
}


where "images" = {"imagesfolder"} without "" (this board wont let me type in the exact code.


I had to use:

PHP Code:

  // ############################### start signature ###############################

$bbuserinfo[signatureurl]=getsignatureurl($bbuserinfo[userid]);
  if (
$bbuserinfo[signatureurl]=="") {
    
$bbuserinfo[signatureurl]=$bburl "/{imagesfolder}/clear.gif";
  } 


Chris M 06-21-2003 08:31 AM

Hmm...

Then your { imagesfolder } variable is not configured correctly...:confused:

Satan

Brandon 06-23-2003 05:23 AM

Quote:

05-30-03 at 02:37 AM hellsatan said this in Post #214

@Gemini - You will have to add the references to signature into member.php:)
I may sound stupid for asking, but WHERE are we supposed to add them? And by references do you mean the part that were looking for or the part that we are supposed to add. I am on vB 2.3.0 as well.

Chris M 06-25-2003 02:37 PM

The part you are supposed to add...

And after where it specifies in the install file;):)

Satan

Dribbles 06-25-2003 03:04 PM

lol

Pikok 07-15-2003 03:44 AM

How do yo uget the signature image to show up in PMs?!? :confused:

scri 07-15-2003 10:00 AM

this is exactly what i'm looking for. I shall install this when i get home. I take it this allows certain user groups to be able to use images in their sigs?

Would it be possible to use an if statement to only make those images visable in particular forums?

thanks so much :)

Pikok 07-16-2003 02:38 PM

Nobody knows how to get the signature image to show up int PMs along with the signature text?!? :( I tried the following, but didn't work..

In "root/private.php" find:
PHP Code:

        if ($post[avatarid]!=0) {
          
$avatarurl=$post[avatarpath];
        } else {
          if (
$post[hascustomavatar] and $avatarenabled) {
            
$avatarurl="avatar.php?userid=$post[userid]&dateline=$post[avatardateline]";
          } else {
            
$avatarurl="";
          }
        }
        if (
$avatarurl=="") {
    
$post[avatar]="";
} else {
    eval(
"\$post[avatar] = \"".gettemplate("postbit_avatar")."\";");
  } 

And Add After:
PHP Code:

// START SIGNATURE IMAGE
        
if ($post[signatureid]!=0) {
            
$signatureurl=$post[signaturepath];
        } else {
            if (
$post[hascustomsignature] and $signatureenabled) {
                
$signatureurl="signature.php?userid=$post[userid]&dateline=$post[signaturedateline]";
            } else {
                
$signatureurl="";
            }
        }
        if (
$signatureurl=="" or ($bbuserinfo[userid]>and !($bbuserinfo[showsignatures]))) {
            
$post[signatureimg]="";
        } else {
            eval(
"\$post[signatureimg] = \"".gettemplate("postbit_signatureimg")."\";");
        }
// END SIGNATURE IMAGE 

But that didn't fix it either. :confused: Any help?

LangTuDaTinh 07-16-2003 03:10 PM

u need to add a JOIN queries to the original PM queries for signature too....like the one in the showthread.

Pikok 07-16-2003 03:29 PM

Quote:

Today at 05:10 PM LangTuDaTinh said this in Post #232
u need to add a JOIN queries to the original PM queries for signature too....like the one in the showthread.
I'd thought about that after I posted that last message. :o I was just gonna look and see what queries needed to be run. Thanks for the help, works great! :D

I added both parts for the queries and also added the "postbit_signatureimg" template to the required templates. For those of you who don't know exactly what to add where to get the sig image to show in PMs, do the following..


In "root/private.php" do the following 4 things..

Find:
PHP Code:

privfolder,postbit_avatar 

And Replace With:
PHP Code:

privfolder,postbit_avatar,postbit_signatureimg 

Find:
PHP Code:

                                 user.*,userfield.*".iif($avatarenabled,",avatar.avatarpath,customavatar.dateline AS avatardateline,NOT ISNULL(customavatar.avatardata) AS hascustomavatar ","")." 

And Add Below:
PHP Code:

                                 ".iif($signatureenabled,",signature.signaturepath,NOT ISNULL(customsignature.signaturedata) AS hascustomsignature,customsignature.dateline AS signaturedateline","")." 

Find:
PHP Code:

                                 ".iif ($avatarenabled,"LEFT JOIN avatar ON avatar.avatarid=user.avatarid
                                                        LEFT JOIN customavatar ON customavatar
.userid=user.userid ","")." 

And Add Below:
PHP Code:

                                 ".iif ($signatureenabled,"LEFT JOIN signature ON signature.signatureid=user.signatureid
                                                           LEFT JOIN customsignature ON customsignature
.userid=user.userid","")." 

Find:
PHP Code:

if ($post[avatarid]!=0) { 
          
$avatarurl=$post[avatarpath]; 
        } else { 
          if (
$post[hascustomavatar] and $avatarenabled) { 
            
$avatarurl="avatar.php?userid=$post[userid]&dateline=$post[avatardateline]"
          } else { 
            
$avatarurl=""
          } 
        } 
        if (
$avatarurl=="") { 
    
$post[avatar]=""
} else { 
    eval(
"\$post[avatar] = \"".gettemplate("postbit_avatar")."\";"); 
  } 

And Add Below:
PHP Code:

        if ($post[signatureid]!=0) {
            
$signatureurl=$post[signaturepath];
        } else {
            if (
$post[hascustomsignature] and $signatureenabled) {
                
$signatureurl="signature.php?userid=$post[userid]&dateline=$post[signaturedateline]";
            } else {
                
$signatureurl="";
            }
        }
        if (
$signatureurl=="" or ($bbuserinfo[userid]>and !($bbuserinfo[showsignatures]))) {
            
$post[signatureimg]="";
        } else {
            eval(
"\$post[signatureimg] = \"".gettemplate("postbit_signatureimg")."\";");
        } 

Perhaps this should be included in the installation instructions. ;) Thanks again LangTuDaTinh!

sabret00the 08-07-2003 05:53 PM

beautiful hack, pity the queries wern't auto or the templates weren't in different txt files, would've cut installation time into shreads, gonna install this later

Harlequin 08-19-2003 03:42 AM

I'm using vB 2.3.2 and I've installed this hack with no problems whatsoever, however, there was a pretty big problem with the fact that the graphic itself didn't show. It has a nice, big X.

I've went through about ten pages of this thread hoping to grab on to an answer, but I don't think I've passed by anyone that's got quite the same problem I do.

Not only does the graphic not display in the usercp, it doesn't display on a post either (the text is there for the signature, the graphic comes up, again, as an X.)

The <img src=" is returning the following:

signature.php?userid=1&dateline=1061267928


Any clues?


I've reinstalled this thing twice already -- but I'll install it again if that's what it takes. :) It looks like a great hack -- hope I can use it soon.

(Could just be it's reeeeal late at night while I'm tryin' to get this on. ;))

Dark_Wizard 09-09-2003 12:53 PM

Quote:

08-19-03 at 12:42 AM Harlequin said this in Post #235
I'm using vB 2.3.2 and I've installed this hack with no problems whatsoever, however, there was a pretty big problem with the fact that the graphic itself didn't show. It has a nice, big X.

I've went through about ten pages of this thread hoping to grab on to an answer, but I don't think I've passed by anyone that's got quite the same problem I do.

Not only does the graphic not display in the usercp, it doesn't display on a post either (the text is there for the signature, the graphic comes up, again, as an X.)

The <img src=" is returning the following:

signature.php?userid=1&dateline=1061267928


Any clues?


I've reinstalled this thing twice already -- but I'll install it again if that's what it takes. :) It looks like a great hack -- hope I can use it soon.

(Could just be it's reeeeal late at night while I'm tryin' to get this on. ;))


I'm having issues with this as well and I don't get any sig showing and yes everyting is enabled. Problem is there are too many steps to go through to find the problem. I will have to remove this for now until Hellsatan finds the bugs.

sabret00the 09-14-2003 11:27 AM

does this hack still work or shall i leave it for another day?

PAINTBALLM 10-07-2003 02:50 AM

any way to add the option of using a image sig, or a text sig? (via radio button)

NightWalk8r 10-13-2003 04:22 PM

hey.....great hack!!!

but as everyone asked, is there a way to have either or both image and text sig??

how about just add another field for the text sig??

LangTuDaTinh 11-22-2003 03:14 PM

This is a great hack and I have installed it for a long time but the more members are using it in a big forum, your forum will be much more slower. After removed this from showthread and store avatar and sig image on web harddisk instead of on the database, my forum speed is much much faster.

So if you have a big forum and would like to use this or multi avatar feature then I would recommend not to store on database.

and the best part is i don't use any queries for both avatars and sig image. i even removed all avatars and sig image from big get post queries in showthread.

what i do is allow members to upload to a directory and set their userid as filename. if user uploaded avatar or sig image then i would change the field avatarid and signatureid to 1, then in function.php, i would add sigimage by check weather those field is one or not. if it's 1 then the avatar and sig will display.

i will add a multi avatars later


All times are GMT. The time now is 03:22 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01667 seconds
  • Memory Usage 1,928KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (18)bbcode_php_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete