Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
vBaffiliates5 - Allow Users to Add & Edit their Own Affiliate Links!!! Details »»
vBaffiliates5 - Allow Users to Add & Edit their Own Affiliate Links!!!
Version: 1.00, by Chris M Chris M is offline
Developer Last Online: Feb 2013 Show Printable Version Email this Page

Version: 2.3.x Rating:
Released: 12-25-2002 Last Update: Never Installs: 26
 
No support by the author.

Please do the following before attempting to install:

1.) Backup your Files before doing anything
2.) Be aware that although I have tested this myself, there may still be problems...If you do not backup your files, I cannot condone your install of this hack...
3.) If you want to Backup your Database, You can - There shouldn't be any need to...

The file you should have is:

vBaffiliates5.zip

Install Info:
Hack Version: 5.0 [Final]
Files to edit: 2
Templates to add:13 (New Install) / 0 (Upgrade from v4)
Templates to edit: As Many as needed (New Install) / Minimum of 1 (Upgrade)
Queries to Run: 6 (New Install) / 0 (Upgrade from v4)
Time to install: Approx 8-10 Minutes
Included files: There are 2 install files included - One is for upgrading from v4, and the other is for a new install - Do not mix them up

Credits
Requested by - DarkDraco07 here & Sinecure

Support - I am offering Support in this Thread ONLY...I unfortunately cannot be here during the coming weeks (Mon-Fri), so therefore you will have to rely on others for assitance, should it be urgent...If you do require assitance, please - Only reply in this thread

Hack info

What does it do? - Basically, you can allow registered board users to add Affiliation Links to the database, which have to be moderated by you...You can then display a Random Banner generated totally at random wherever you like, and it will be linked to the site of the submitter...Also it stores the Image Height and Width in the database, and you can limit the size of the Banners they can upload...If they change the image (located on their server) without editing their Banner, then it will not show up their Banner, Link, Hit Count, Edit Link or Site Name...They must then ask an Admin to update the Banner...Now there is also a List of the Banners on the site, and their Moderated Status...You can also choose how many Banners to show in the list

Testing

You can see the BETA Release here...

Changes since BETA
  • Changed the way that Links are shown
  • Added another Template to add

Changes since 1.0[Final]
  • Added missing re-direct template
  • Added another Template to add
  • Added image size restriction
  • Changed a template
  • Added an intelligent Image check to see if they changed the size of the image in an attempt to cheat the system

Changes since 2.0[Final]
  • Corrected forum/global.php mishap
  • Added a Hit Counter
  • Added a "User Edit" Screen
  • Changed a template
  • Update the Intelligent Image check to see if they changed the size of the image in an attempt to cheat the system

Changes since 3.0[Final]
  • Updated forum/global.php to show a Admin CP Options controlled number of Banners
  • Added a Banner List page, showing all the Banners and their Moderated Status
  • Added a Banner List page Banner Limit, to show only the number of Banners Randomnly that you want
  • Update the Intelligent Image check to see if they changed the size of the image in an attempt to cheat the system and put it in a while loop

Changes since 4.0[Final]
  • Updated forum/vbaffiliates.php to work with register_globals off, and modified code structure slightly
  • Updated admin/affiladmin.php to work with register_globals off, and modified code structure slightly

Additional Info/Updates

2.0[Final] - 2.0[Final] has just been released...This includes an Image Size restriction, and a clever system for those who think they can get around the system - It stores the image's height and width, and uses HTML to code the width and height of the image - If they change it, it will show a red "no image found" image instead...

3.0[Final] - 3.0[Final] has just been released...This includes an update to the Image Size restriction, and an update for the clever system for those who think they can get around the system - It stores the image's height and width, and uses HTML to code the width and height of the image - If they change it, it will not show their Banner, Link, Site Name, Edit Link or Hit Count...

4.0[Final] - 4.0[Final] has just been released...This includes an update to the Image Size restriction, and an update for the clever system for those who think they can get around the system - It stores the image's height and width, and uses HTML to code the width and height of the image - If they change it, it will not show their Banner, Link, Site Name, Edit Link or Hit Count...Now there is also a List of the Banners on the site, and their Moderated Status...You can also choose how many Banners to show in the list

5.0[Final] - 5.0[Final] has just been released...This release includes a new set of .php files which have been re-coded to work with register_globals off, and also the coding structure has been changed...

The next release is a List of "User's Banners" page, and a then a Timed function to set the Moderated status to 0 (No) when the time period expires...

Screenshots/Live Demo

There are NEW screenshots provided in the next post, in vBaffiliates5-screenshots.zip

Enjoy!

Satan

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #22  
Old 12-27-2002, 02:29 PM
NTLDR's Avatar
NTLDR NTLDR is offline
Coder
 
Join Date: Apr 2002
Location: Bristol, UK
Posts: 3,644
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I've an idea to rectify that
Reply With Quote
  #23  
Old 12-27-2002, 03:01 PM
Smoothie Smoothie is offline
 
Join Date: Oct 2001
Location: New York
Posts: 1,834
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Does the current system link the banner? I'd rather upload the banner to my own server, and have it displayed from there.
Reply With Quote
  #24  
Old 12-27-2002, 03:16 PM
Smoothie Smoothie is offline
 
Join Date: Oct 2001
Location: New York
Posts: 1,834
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just looked at the screen shots, very nice.
Reply With Quote
  #25  
Old 12-27-2002, 03:41 PM
Chris M's Avatar
Chris M Chris M is offline
 
Join Date: Dec 2001
Location: Northampton, England
Posts: 6,186
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yes it does link the banner...I am working on the Hits version (v3) next, and then the "timed banner" addon for you

Satan
Reply With Quote
  #26  
Old 12-27-2002, 05:24 PM
alkatraz alkatraz is offline
 
Join Date: Oct 2002
Location: Vancouver, Canada
Posts: 384
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Cool hack!
Reply With Quote
  #27  
Old 12-27-2002, 05:31 PM
Smoothie Smoothie is offline
 
Join Date: Oct 2001
Location: New York
Posts: 1,834
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by hellsatan
Yes it does link the banner...I am working on the Hits version (v3) next, and then the "timed banner" addon for you

Satan
I was wondering, would it be possible to allow an upload of the banner, instead of linking?

Something like this hack, which allows banner uploads. I really don't want someones banner slowing our site down.

Check it out:
https://vborg.vbsupport.ru/showthrea...hlight=vblinks
Reply With Quote
  #28  
Old 12-27-2002, 05:31 PM
Chris M's Avatar
Chris M Chris M is offline
 
Join Date: Dec 2001
Location: Northampton, England
Posts: 6,186
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks alkatraz - v3 is very near to release

I just need to test the major new feature, which is "User Editability"

Satan
Reply With Quote
  #29  
Old 12-27-2002, 05:34 PM
Chris M's Avatar
Chris M Chris M is offline
 
Join Date: Dec 2001
Location: Northampton, England
Posts: 6,186
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

@Smoothie - It is possible...I just need to learn how to do a good Upload script that complies with the limitations set by each board...

Satan
Reply With Quote
  #30  
Old 12-27-2002, 07:39 PM
Dean C's Avatar
Dean C Dean C is offline
 
Join Date: Jan 2002
Location: England
Posts: 9,071
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This looks nice satan...
Reply With Quote
  #31  
Old 12-27-2002, 09:00 PM
Mystis's Avatar
Mystis Mystis is offline
 
Join Date: Jul 2002
Location: Minnesota
Posts: 72
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by hellsatan
@Smoothie - Controlling the Banner is proving to be difficult - Seeing as the url is stored, not the image, it is hard to find a way to limit the size of the banner...

Satan
That would be a simple one to get around.

PHP Code:
/* Add to functions.php */
function checkimagesize($imageurl){
    global 
$maxwidth$maxheight;
    
$size getimagesize($imageurl);
    if(
$size[0]>=$maxwidth&&$size[1]>=$maxheight){
        return 
true;
    }else{
        return 
false;
    }
}

/* Usage */
if(checkimagesize($image)){
    
//display
}else{
    
//skip this ad and get another one

Code's untested, but it should work.
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 03:22 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.12252 seconds
  • Memory Usage 2,320KB
  • Queries Executed 25 (?)
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)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)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_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