Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
The Ultimate Random Header Mod Details »
The Ultimate Random Header Mod
Mod Version: 1.0.0, by Jaxel (Coder) Jaxel is offline
Developer Last Online: Sep 2013 I like it Show Printable Version Email this Page

vB Version: 3.8.x Rating: (7 votes - 5.00 average) Installs: 51
Released: 28 Apr 2009 Last Update: 28 Apr 2009 Downloads: 234
Not Supported Template Edits Additional Files  

This mod has been rewritten for vB4x here: http://www.vbulletin.org/forum/showthread.php?t=240629

THIS SCRIPT DOES NOT USE JAVASCRIPT!

I wrote this mod for my own website last year (http://www.8wayrun.com/). I was looking for a way to create a random header situation, while also letting people select the random header through their UserCP and FORCE a header depending on what forum they are on. If you go to my website (http://www.8wayrun.com/), a random character will appear on your header, if you ctrl+refresh, a new character will show up... if you go to our character specific forums, the character in the random header will be FORCED to the character of that specific forum... I have done my best to make this script as simple as possible.

Product Demo:
http://www.8wayrun.com/
http://www.8wayrun.com/customstyles/...der/header.php
Installation Procedure:
  1. Create a dedicated folder on your server where you will be putting your random images.
  2. Put the included "header.php" script into the folder you created previously in step 1.
  3. Put the images you want randomized into the folder you created previously in step 1.
Optional Switches:
  1. OPTIONAL: If you want, you can set this script to FORCE a header on specific forum. Its simple, when naming the files for your random images, simply name the file as the forum ID of that forum. So if you want a specific image forced when viewing forum 38, name the file 38.png.
    .
  2. OPTIONAL: If you want, you can let users SELECT which header they want on places where the script would normally randomize.
    1. Create a new "Single-Selection Menu" profile field in your adminCP, set title and description to whatever you want. If you use numbered filenames like those in step 2, you may want to use the description field to let people know what they are selecting. (see screenshot)
    2. For each selection option, enter an image's filename WITHOUT the extension, so wolves.png will be just "wolves".
    3. Set Default: None
    4. Field Required: No
    5. Field Editable: Yes
    6. Private Field: No
    7. Field Searchable on Members List: No
    8. Show on Members List: No
    9. Display Page: Options: Other
    After you submit, this field will be given a name (ex: field9). Make sure to remember this name.
    .
  3. OPTIONAL: Open up the included "header.php" script and go to the section flagged "// VALIDATE CURRENT IMAGE DATA, CHECK FID, CHECK PID". By default, the image randomizer will find ANY image with the JPG, PNG or GIF extension. However, the FORCED and SELECT settings will always look for PNG images. If you would like to change this to either JPG or GIF, you must change the two isntances of PNG to the appropriate format. Only ONE filetype is usable with the FORCED or SELECT options.
    .
  4. The script has a heirarchy of importance when searching for images. The first thing it will look for is the FORCED image from step 1. If it doesn't find a forced image, it will use the user defined image in step 2. If the user doesn't have a defined image, it will pick an image at random from the folder it resides in.
Usage Procedure:
  1. Anywhere you want to use this random script, just link to this script, instead of an image.
    • <img src="DIRECTORY/header.php?fid=$forumid&pid=$bbuserinfo[field9]" />
    • <table background="DIRECTORY/header.php?fid=$forumid&pid=$bbuserinfo[field9]"></table>
    .
  2. The text in BLUE above is the switch for forcing an image based on the forumid. If you don't want to force images depending on the forum, you dont need to include that switch.
    .
  3. The text in RED above is the switch for forcing an image based on user control panel selection. If you don't want to give users the option to select an image manually, you dont need to include the switch. Notice that this switch has a variable called "field9"; this may not be the same in your forum. This variable should be changed to the field name I had you make note of in a previous step.
Don't forget to click INSTALL!

If you want to donate, I'm all for it... as I'm an unemployed computer programmer...

Download Now

Only licensed members can download files, Click Here for more information.

Screenshots

Click image for larger version

Name:	1.jpg
Views:	1284
Size:	247.0 KB
ID:	98437   Click image for larger version

Name:	2.jpg
Views:	977
Size:	199.8 KB
ID:	98438   Click image for larger version

Name:	3.jpg
Views:	672
Size:	213.7 KB
ID:	98439  

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • If you like this modification support the author by donating.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
  #31  
Old 05 Jul 2009, 16:10
applebeef applebeef is offline
 
Join Date: Jun 2009
Actually, upon further inspection, it seems to be a standard part of Vbulletin code?

The sites (not mine) that I looked at all have this. In fact VB.org has this if you view page source their home page.

Even your forum has this!:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Granted it differs from mine in that the value "0" is present instead of "-1" (no idea what that means)

Edit: Further more reading, this is hardcoded into the forum home of Vbulletin, which explains that. It is not present for example, on a random forum page on my forum.


So is this really the problem?

Last edited by applebeef; 05 Jul 2009 at 16:43.
Reply With Quote
  #32  
Old 12 Jul 2009, 23:15
Tilly Tilly is offline
 
Join Date: Sep 2007
How do you link the code to your homepage? Like link the image back to your forum home?
Reply With Quote
  #33  
Old 20 Aug 2009, 13:28
odln018's Avatar
odln018 odln018 is offline
 
Join Date: Mar 2006
Jaxel -
I'm using your mod in conjunction with VB 3.8.4. I upgrade my PHP from 5.2.9 to 5.3, and this mod no longer functions.

I'm not receiving any errors, just no banners at all. When I revert back to 5.2.9, all functions normally again. I'm not receiving any errors, just no banners at all. When I revert back to 5.2.9, all functions normally again.
Reply With Quote
  #34  
Old 20 Aug 2009, 13:30
odln018's Avatar
odln018 odln018 is offline
 
Join Date: Mar 2006
Jaxel -
I'm using your mod in conjunction with VB 3.8.4. I upgrade my PHP from 5.2.9 to 5.3, and this mod no longer functions.

I'm not receiving any errors, just no banners at all. When I revert back to 5.2.9, all functions normally again.
Reply With Quote
  #35  
Old 09 Sep 2009, 04:39
tafreeh's Avatar
tafreeh tafreeh is offline
 
Join Date: May 2008
Location: Canada
Real name: DON
works great... but i have a lil issue...
check out this image
http://images.tafreehmela.com/showor...5/untitled.jpg

there is unwanted free white space above my logo? how is that?
__________________
Vb Forum
Reply With Quote
  #36  
Old 24 Sep 2009, 20:46
chris&barb chris&barb is offline
 
Join Date: Sep 2009
Does this mod work on 3.8.4? I did exactly as said and nothing happened. Where exactly is everyone placing the folder?
Reply With Quote
  #37  
Old 10 Oct 2009, 00:27
goxy63 goxy63 is offline
 
Join Date: Oct 2008
Is there any way to use this mod with flash animations(SWF) as Iam using them for my forums as a header?

Thanks for answer

Cheers
__________________
VB5-- WHO HAS VISITED TODAY(last 24h) PLEASE VOTE HERE
VB5--FIRST POST ON EVERY PAGE PLEASE VOTE HERE
Reply With Quote
  #38  
Old 25 Mar 2010, 05:31
Gamelobby's Avatar
Gamelobby Gamelobby is offline
 
Join Date: Jul 2007
If i just want a rotating header (completely random) do i need to use these at all.?
I'm guessing i do or it wouldn't know how to connect to the images. lol (header.php)
  • <img src="DIRECTORY/header.php?fid=$forumid&pid=$bbuserinfo[field9]" />
  • <table background="DIRECTORY/header.php?fid=$forumid&pid=$bbuserinfo[field9]"></table>
But i did add both to my header teamplate, but nothing works.?
My header template is weird, so im not sure if it is my template, or the 3.8.5 version.?

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Is there a more simplified code i could use to just randomize the header..?
Also does this work with 3.8.5.?

Thanks
Reply With Quote
  #39  
Old 22 Jun 2010, 11:16
psychonikeo psychonikeo is offline
 
Join Date: Nov 2009
working fantastic on 3.8.4!!! I was looking for this, so this helped me out so much!!
Reply With Quote
  #40  
Old 04 Jul 2010, 17:53
john102774 john102774 is offline
 
Join Date: Aug 2008
Great Mod! Installed on 3.8.5.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

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


New To Site? Need Help?

All times are GMT. The time now is 02:26.

Layout Options | Width: Wide Color: