Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 09-14-2002, 02:56 AM
HeadBopMusic HeadBopMusic is offline
 
Join Date: Sep 2002
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Another new jack ineed of help

Hello, I need some help with my VBB.

I recentley lost my webmaster, so im on my own with setting up my messageboard. I pretty much have most of it down, but i need help doing 2 things..

1. I need to make avatars automatically asign to users when they register..

2. I need a Mini top 10 most recent messages board on my front page of my website.

"I used to have one, but lost it when my site crashed"

Now i'm so new to this technical side of web site stuff its not funny.. Please can some one help me with these issues in as clear of a "non tech" language as posible...

Much thanks in advance.. Sidious HeadBopMusic

check out the website and look at the messageboard to see a example of my avatar question. I've been manualy asigning avatars.. also if you look at the front page, you'll see a empty space in the bttom left side of the page where the top 10 most recent board was.. These are examples to maybe help you understand what im talking about....
Reply With Quote
  #2  
Old 09-14-2002, 10:41 AM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

1.
Open register.php find this:
PHP Code:
  $homepage trim($homepage);
  if (
$homepage) {
    if (
preg_match('#^www\.#si'$homepage)) {
      
$homepage "http://$homepage";
    } else if (!
preg_match('#^[a-z0-9]+://#si'$homepage)) {
      
// homepage doesn't match the [url]http://-style[/url] format in the beginning -- possible attempted exploit
      
$homepage ''
    }
  }
  
$DB_site->query("INSERT INTO user (userid,username,password,email,".$newstylefield."parentemail,coppauser,homepage,icq,aim,yahoo,signature,adminemail,showemail,invisible,usertitle,joindate,cookieuser,daysprune,lastvisit,lastactivity,usergroupid,timezoneoffset,emailnotification,receivepm,emailonpm,options,birthday,maxposts,startofweek,ipaddress,pmpopup,referrerid,nosessionhash,avatarid) VALUES (NULL,'".addslashes(htmlspecialchars($username))."','".addslashes(md5($password))."','".addslashes(htmlspecialchars($email))."',".$newstyleval."'".addslashes(htmlspecialchars($parentemail))."','$coppauser','".addslashes(htmlspecialchars($homepage))."','".addslashes(htmlspecialchars($icq))."','".addslashes(htmlspecialchars($aim))."','".addslashes(htmlspecialchars($yahoo))."','".addslashes($signature)."','$adminemail','$showemail','$invisible','".addslashes($usertitle)."','".time()."','$cookieuser','".addslashes($prunedays)."','".time()."','".time()."','$newusergroupid','".addslashes($timezoneoffset)."','$emailnotification','$receivepm','$emailonpm','$options','".addslashes($birthday)."','".addslashes($umaxposts)."','".addslashes($startofweek)."','".addslashes($ipaddress)."','$pmpopup','".addslashes($testreferrerid['userid'])."','$nosessionhash','$avatarid')");
  
$userid=$DB_site->insert_id(); 
just before add:
PHP Code:
if($avatarid==0$avatarid=x
Reply With Quote
  #3  
Old 09-15-2002, 02:14 AM
HeadBopMusic HeadBopMusic is offline
 
Join Date: Sep 2002
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmmm "Open register.php" where can i find that? In my V bulletin controll panel?
Reply With Quote
  #4  
Old 09-15-2002, 02:38 AM
DrkFusion's Avatar
DrkFusion DrkFusion is offline
 
Join Date: Nov 2001
Posts: 1,926
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

FTP to your site
Go to where you forum is uploaded, there you will find the file called register.php download it to your harddrive and edit it with a software like notepad, and make the changes Xenon has mentiond.
Reply With Quote
  #5  
Old 09-15-2002, 02:59 AM
HeadBopMusic HeadBopMusic is offline
 
Join Date: Sep 2002
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

ok im there i found it and what xenon said to look for, now my only question is to past the EDIT INFO "if($avatarid==0) $avatarid=x;"directley in fornt of "the info xenon metioned on the same line.

or do I past it on the line above? or dose it matter.. ?
Reply With Quote
  #6  
Old 09-15-2002, 03:06 AM
HeadBopMusic HeadBopMusic is offline
 
Join Date: Sep 2002
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

also after i've done that.. How dose the board know what avatar to assign? I have the avatar on my hard drive.
Reply With Quote
  #7  
Old 09-15-2002, 09:00 AM
Dean C's Avatar
Dean C Dean C is offline
 
Join Date: Jan 2002
Location: England
Posts: 9,071
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

upload it to your webspace and where xenon gave you this line to put:

PHP Code:
if($avatarid==0$avatarid=x
replace the "x" with the web address to your default avatar....

- Mist
Reply With Quote
  #8  
Old 09-15-2002, 08:02 PM
HeadBopMusic HeadBopMusic is offline
 
Join Date: Sep 2002
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmm ok i did that, and th ewhen i tryed to register it brought aup a Error.. so put back the orignal register.php anyone know why i got a error,, here exactly what i have there.

if($avatarid==0) $avatarid=http://www.headbopmusic.com/board/hblogosm.gif;
$homepage = trim($homepage);
if ($homepage) {
if (preg_match('#^www\.#si', $homepage)) {
$homepage = "http://$homepage";
} else if (!preg_match('#^[a-z0-9]+://#si', $homepage)) {
// homepage doesn't match the http://-style format in the beginning -- possible attempted exploit
$homepage = '';
Reply With Quote
  #9  
Old 09-15-2002, 11:44 PM
HeadBopMusic HeadBopMusic is offline
 
Join Date: Sep 2002
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok i think I did everthing right. My earlyer problem with the error was fixed. insted of:



if($avatarid==0) $avatarid=http://www.headbopmusic.com/board/hblogosm.gif;
$homepage = trim($homepage);
if ($homepage) {
if (preg_match('#^www\.#si', $homepage)) {
$homepage = "http://$homepage";
} else if (!preg_match('#^[a-z0-9]+://#si', $homepage)) {
// homepage doesn't match the http://-style format in the beginning -- possible attempted exploit
$homepage = '';



I chenged it to:




if($avatarid==0) $avatarid= http://www.headbopmusic.com/board/hblogosm.gif;$homepage = trim($homepage);
if ($homepage) {
if (preg_match('#^www\.#si', $homepage)) {
$homepage = "http://$homepage";
} else if (!preg_match('#^[a-z0-9]+://#si', $homepage)) {
// homepage doesn't match the http://-style format in the beginning -- possible attempted exploit


Now it allows registration agin with no error. But it still dosent link the the avatar automatically. when registering you can choose the avatar. its there uploaded on the server, the user would have to choose to use it. I'm trying to have it be a standered that the same avatar is used for all members the register. upon they're first post it should be there. with out them or me choosing it.. can this be done?

Or is this what your trying to have me do and im simpley not doing it right?


Thanks for you time & Help..
Reply With Quote
  #10  
Old 09-16-2002, 12:47 AM
HeadBopMusic HeadBopMusic is offline
 
Join Date: Sep 2002
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

ok ok A lot of posts i know....

I think what i'm trying to do is set the avatar option to default "always" leaving no option to change it.. And the avatar i uploaded to my server needs to be the DEFALUT.

right now the avatar option in the user registeration screen is giving the user a option to choose a avatar, and when they drop down the menu to choose, the avatar i uploaded is there, as a option..

again I followed the instructions the best i could from you guy's info and the above example of the changes i made to the "register.php" are still in effect..

I also "inside administrative options" turned off the users abilitys to upload or add a avatar in anyway.. and the min. amount of post required to use a avatar is set to zero..

hopefully this helps explain my problem a little better.. ok thanks again.....
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 05:50 PM.


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.04734 seconds
  • Memory Usage 2,280KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (3)bbcode_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete