vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Member Archives (https://vborg.vbsupport.ru/forumdisplay.php?f=202)
-   -   [Release] Custom Image Under User Name (https://vborg.vbsupport.ru/showthread.php?t=5301)

12-08-2000 01:11 PM

You either set it to allow the user to UL an image OR you set it to allow them to type in an URL, not both at the same time. It is all a moot point as John has put Avatars in v2.0.

12-08-2000 01:26 PM

You're misunderstanding me. I'm not refusing the Avatar hack just 'cause I thought it doesn't have the img URL or 'cause it's too heavy for my db (even if my hoster db su*). I'm refusing it as I'm not a PHP profi and dunno which parts to cut/use/delete/etc. :)
Anyway, the hack by JimF is just OK for me. I've only to wait as I dunno how to crop the noimage code from the Avatar hack...

12-08-2000 01:36 PM

Quote:

Originally posted by freddie
Perhaps you guys can't read but my hack allows you to make the user specify a link for a picture OR allow them to upload a picture OR select a picture from the server. I do really think I covered it all. Perhaps I need to put all my hacks back in my sig as I see requests for stuff I have already done 3 months ago.
How'd you guess? How did I ever fool those SAT proctors?? :D

I think what you should have said was "Perhaps you guys didn't read past page 27 of the Avatar hack thread". Freddie, take a deep breath. Count to 10. We all feel better now, don't we?

Why didn't you mention your hack in the thread requesting this? You can read, right? If you had, I wouldn't have had to spend an afternoon working on a hack that I'll never use.

-jim

[Edited by JimF on 12-08-2000 at 11:53 AM]

12-08-2000 06:08 PM

Um because by the time I saw that thread you had already done it. I don't always come here every day as I am in a down period waiting for 2.0 to be released so I am not hacking 1.1.4 anymore.

12-09-2000 12:41 AM

Okay, cuz JimF was so kind to post the code
to have a picture under the username, without
having to install the bloated Avatar hack,
I wanted to do something back :)

With JimF's hack, when a user doesn't select
a picture, there's a red cross. I've fixed it :)


Open showthread.php

Find:

Code:

    $useremail="";
and place this under it:

Code:

    $custom_img="";
Find:

Code:

    if ($userinfo[imgurl]!="") {
      $custom_img=$userinfo[imgurl];
      eval("\$imgurl = \"".gettemplate("custom_img")."\";");
    } else {
      $custom_img="";
      $imgurl="";
    }

and replace it with:

Code:

    if ($userinfo[imgurl]!="") {
      $custom_img=($userinfo[imgurl]);
      $custom_img="<img src=\"$custom_img\" height=\"60\" width=\"60\" border=\"1\">";
      eval("\$imgurl = \"".gettemplate("custom_img")."\";");
    } else {
      $custom_img="";
      $imgurl="";
    }

Replace the 60's with the numbers you desire,
and if you don't want a border just remove the
border=\"1\" bit.

Save and Close showthread.php.

Open the postbit template

Find:

Code:

<img src="$custom_img" height="xx" width="xx">
the "xx" is what you filled in,
just search for a part of this line,
but do REPLACE THE WHOLE LINE!!

and replace it with:

Code:

$custom_img
Done :)

No ugly red crosses, not even with guest users :)

Feel free to comment, cuz this is the first time i've coded in php :)

Greetz.

[edit]
I've tested it on my board, and it works fine there, but i KNOW there MUST be some programming flaws in there, so if you see one, please post the fix... Thnx.. :)
[/edit]


[Edited by X-PhoeniX on 12-11-2000 at 05:21 PM]

12-09-2000 07:01 AM

Tnx man!
I didn't want to disturb JimF too and was waiting for a fix. :D
I'm gonna test it right now and if there're bugs I'll report it into 5 mins...

12-09-2000 01:23 PM

Quote:

Originally posted by Cr4z33
I'm gonna test it right now and if there're bugs I'll report it into 5 mins...

so, no bugs? :)

12-09-2000 01:39 PM

[QUOTE]Originally posted by X-PhoeniX
Quote:

so, no bugs? :)
I could not test it atm. The table "forumpermission" is corrupted and I'm still waiting for a reply by the support... :(
BTW do you know the syntax to use on phpMyAdmin to fix it? I only know that I've to use isamchk as the corrupted file is "forumpermission.ISM"...

12-09-2000 02:10 PM

[QUOTE]Originally posted by Cr4z33
Quote:

Originally posted by X-PhoeniX
Quote:

so, no bugs? :)
I could not test it atm. The table "forumpermission" is corrupted and I'm still waiting for a reply by the support... :(
BTW do you know the syntax to use on phpMyAdmin to fix it? I only know that I've to use isamchk as the corrupted file is "forumpermission.ISM"...
too bad..

(BTW: does anyone have the fix for this irritating quote bug, as you can see? when i quote someone who has quoted someone who has quoted someone etc.. there are like 3 quotes... they suck... but back to the point ;))

euh.. nope, sorry... never dealed with a corrupted db be4.. can't help ya m8..

12-09-2000 02:16 PM

Quote:

Originally posted by X-PhoeniX
too bad..

(BTW: does anyone have the fix for this irritating quote bug, as you can see? when i quote someone who has quoted someone who has quoted someone etc.. there are like 3 quotes... they suck... but back to the point ;))

euh.. nope, sorry... never dealed with a corrupted db be4.. can't help ya m8..


Np, as soon as I fix the problem I'll let ya know. :)
Could someone tell me if I can safely delete and recreate the table "forumpermission" without troubles on the board? Note that's the test board so I'm the only user there. :)


All times are GMT. The time now is 12:18 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.01159 seconds
  • Memory Usage 1,748KB
  • 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
  • (6)bbcode_code_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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