vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   vB Timeslip Database -for Automotive websites (https://vborg.vbsupport.ru/showthread.php?t=60945)

EvilLS1 01-29-2004 10:00 PM

vB Timeslip Database -for Automotive websites
 
This is the newest version of my Timeslip Database hack. If you don't have an automobile related website ya might as well stop reading here because this will probably be of no use to you.. But if you do, read on!

What does it do? This hack does a few things. First, it will add a separate "Vehicle Profile" page to your forum where your users can enter their type of vehicle, engine, tranny, tires, horsepower, best 60' time, 1/8 mile time, 1/4 mile time, upload thier timeslip and more. Once the data is entered the timeslips.php page will display the info sorted by the best times, highest trap speeds, highest horsepower #s, proof of ET, or ET brackets (user selectable).

You can also ban users from editing their Vehicle Profile. This comes in handy if you have some users who insist on entering false data into the Timeslip Database just to be funny. To use this feature, just click on the user's vehicle profile, then click "user options" and set "Can edit vehicle profile" to no. The user will still be able to edit his regular profile, but not his vehicle profile.


Features include:
*The ability to sort by:
-1/4 Mile ET
-1/4 Mile MPH
-1/8 Mile ET
-1/8 Mile MPH
-60' Time
-Horsepower
-Cars with proof of ET (actual timeslip)
-N/A cars only
-Username
-ET brackets
*Show the average ET, MPH, and HP for your site.
*Vehicle Profile (separate from user profile)
*Ability to ban users from editing their vehicle profile
*Users can upload their timeslip in the vehicle profile. (New!)
*Timeslip uploads can be disabled in the admincp. (New!)
*Admin can delete user's uploaded timeslip. (New!)
*Maximum width, height and filesize for timeslip uploads can be set in the admincp. (New!)
*Admin can set an ET for which a timeslip is required if user's ET is quicker. (New!)
*Installer


Demo:
http://modernmusclecars.net/forums/timeslips.php

vb.org member sites w/Timeslip Database installed:
http://srtforums.com/forums/timeslips.php
http://www.fordpower.net/forums/timeslips.php
http://www.al-club3g.org/forums/timeslips.php
http://www.gmvsford.com/forums/timeslips.php
http://board.accordtuner.com/timeslips.php
http://www.240sxforums.com/forums/timeslips.php
http://www.tennesspeed.net/forums/timeslips.php
http://www.socalloc.com/forums/timeslips.php
http://www.lincolnvscadillac.com/timeslips.php
http://fordvschevy.com/forum/timeslips.php
http://www.skylinesaustralia.com/forums/timeslips.php
http://www.lonestarstangs.com/forum/timeslips.php
http://www.tallahasseemusclecar.com/forum/timeslips.php
http://www.ricehatersclub.com/vbulletin/timeslips.php
http://www.highertuning.com/forums/timeslips.php4
http://www.mx5roadsters.com/forums/timeslips.php
http://www.stangcountry.com/forums/timeslips.php
http://www.lssix.com/forums/timeslips.php
http://gpfanatix.com/forums/timeslips.php
http://tealnet.com/ipw-web/forum/timeslips.php
http://www.eurotechniks.com/forums/timeslips.php
http://k-series.com/forum/timeslips.php
http://www.ymrforums.com/timeslips.php
http://www.modernengineuity.com/forums/timeslips.php
http://t6p.com/forums/timeslips.php
http://www.turborides.com/forums/timeslips.php
http://www.mr2oc.com/timeslips.php
http://host41.hrwebservices.net/~wac...timeslips.php?
http://www.moparstyle.net/forums/timeslips.php
http://www.fullthrottleforums.com/timeslips.php
http://www.ozhonda.com/forum/timeslips.php
http://www.fordforums.com.au/timeslips.php
http://www.commodorecarclubwa.com/timeslips.php
http://www.forabodiesonly.com/mopar/timeslips.php
http://www.carolinarides.com/forum/timeslips.php
http://www.sicgmtrucks.com/forum/timeslips.php
http://www.micra.org.uk/timeslips.php
http://www.carforums.net/

If you'd like me to add a link to your VB3 Timeslip Database for others to see, please post it in this thread.

I've also attached some screenshots from my test board below so that you can see what the standard VB3 version looks like. The screenshots only show 10 entries, but it does have pagination and will display 25 per page by default.

Screenshots:
Timeslips main page
Vehicle Profile
Edit Vehicle Profile
Upload a timeslip
Admincp settings


Installation overview:
Files to edit: (7)- admincp/user.php, image.php, member.php, includes/functions_user.php, profile.php, includes/functions_upload.php, includes/functions_online.php
Files to upload: (3)- TDinstaller.php, timeslips.php, slipicon.gif
Templates to edit: (2)- USERCP_SHELL, navbar
Templates to add: (5)- timeslips, timeslipsbit, getvehicleinfo, timeslips_customfields, modifytimeslip
Phrases to add: (6) *see instructions


Support: (Updated: 8-6-05)
Due to my busy scedule and the release of vB 3.5 this version of the Timeslip Database will no longer be supported or developed. Please do not PM me with questions about when the next version will be released because I honestly have no idea.. But when I do start working on it I'll be sure to let you guys know.
Read more here:
https://vborg.vbsupport.ru/showpost....&postcount=666

Please search this thread before posting questions. Theres a good chance that your question has already been posted and answered.

Also, reading through the old thread for vB Timeslip Database v1.3 can probably answer some of your questions about adding new features or customizing.

The VB2 version of this hack is located here:
https://vborg.vbsupport.ru/showthread.php?t=58076


Add-ons & How to's:
*Show the Top 5 ETs on your vB Advanced Homepage.
*Show the Top 5 ETs on your vB Advanced CMPS page. (by coolmody)
*Show the Top 5 ETs on your vBindex page. (by SVTBlackLight01)
*Change the default sort method
*Show the ET club that users belong to in the postbit.
*Show the 1/4 mile ET in the postbit only for users who have added it.
*Set permissions for editing the Vehicle Profile per usergroup.
*Require a link to the actual timeslip for all ETs that are 11.99 or quicker (for v2.0 only.. this comes standard in v2.1)


This hack has been confirmed to work with vB versions 3.0.0 - 3.0.8.

Many thanks to my beta testers: 350Chevy and Corsacrazy :up:


Version History:
v2.1: -Added the ability for users to upload timeslips in their vehicle profile. Added the ability for admins to require an actual timeslip for specified ETs. New Timeslip Database settings added to the admincp to control maximum upload sizes and turn the upload feature on & off. (current version)
(Check this post for more info about the new features.)
v2.0: -Ported hack over for VB3 and added a few new fields to the vehicle profile.
v1.3: -Added the ability to sort by ET brackets or "clubs". (ie. show 10 second cars only. 11 second cars only, 13 sec cars, etc).
v1.2: -Added a new action that will show the average ET, trap speed, and horsepower for your site.
v1.1: -Added the seperate vehicle profile page to input timeslip data. Added a few new fields to the vehicle profile page (race weight, track, D/A, mods, tranny type, etc). Added a "details" column to the Timeslip Database page which lets you view all vehicle profile fields when clicked.
v1.0: -Initial release. (VB2)


NOTE: If you've recently upgraded your forum software and you're having trouble with timeslips.php showing all users (regardless if they have an ET) or it not sorting correcty, Read This!


If you find this script useful please click install. :)

EvilLS1 01-30-2004 12:39 AM

One more screenshot:

EvilLS1 01-30-2004 12:47 AM

Add-on (for v2.0 only.. this comes standard in v2.1)

Require a link to the actual timeslip for all ETs that are 11.99 or quicker.

This bit of javascript will check the 1/4 mile ET field and the timeslip link field. If the 1/4 mile ET is less than 12.00 and the timeslip link field is empty, users will get a small pop-up box when they click the submit button telling them that a timeslip is required for ETs that are 11.99 or quicker.

Of coarse you can easily change it to any ET for the slip requirement.

In your modifytimeslip template find:
Code:

<form action="profile.php" method="post" id="profileform">
Replace it with:
Code:

<script language="javascript">
<!--
function validate(theform) {
        if ((theform.field55.value<12) && (theform.field55.value>0) && (theform.field57.value=="")) {
                alert("A link to your timeslip is required if your 1/4 mile ET is 11.99 or quicker.");
                return false; }
}
//-->
</script>

<form action="profile.php" method="post" id="profileform" onSubmit="return validate(this)">


PranK 01-30-2004 12:54 AM

I LOVE YOU!!!

I have been hanging for this to come out for VB3!!!

/me clicks install 10,000 times!

Thanks heaps,

Christian

SIINSI 01-30-2004 01:47 AM

Awesome man... How do I just upgrade from your first version?

Thanks,
Miguel

PranK 01-30-2004 01:51 AM

got problemo's...
Code:

Database error in vBulletin 3.0.0 Release Candidate 3:

Invalid SQL: INSERT INTO profilefield (profilefieldid,title,description,required,hidden,maxlength,size,displayorder,editable,type,data,height,def,optional,searchable,memberlist,regex,form,html) VALUES (50,'Ride','What do you drive?',0,0,'20','20','50','1','input','','0','0','0','0','0','0','','0')
mysql error: Duplicate entry '50' for key 1

any suggestions?

Christian

EvilLS1 01-30-2004 01:55 AM

Thanks fellas.

Miguel,
If you still have some of the old timeslip fields from version 1.X, you can edit the installer and remove the queries which add the fields that you already have. Then it will only add the new fields. Just go into your admin panel and looks under user profile fields and make a note of the IDs.

PranK,
You still have some of the old profile fields in your database.

From the instructions:
Quote:

// IMPORTANT: If you've previously installed vB Timeslip Database version 1.X on your VB2 board you'll need to go to your admincp, click "user profile fields manager" and make sure that no profile fields with IDs from 50-65 exist.. If they do, you'll need to remove them before running the installer..
Or if you want to keep the values from your old Timeslip Database fields you can simply edit the TDinstaller file and remove ONLY the fields that you want to keep.
I will make an upgrade script when I get some free time.

EvilLS1 01-30-2004 02:30 AM

.................................................. ....

PranK 01-30-2004 05:09 AM

cheeers - thanks mate!

(I did check the user profile manager, but none of the ones you listed were in there).

PranK 01-30-2004 05:16 AM

i deleted the fields from the db, ran the installer and got;
Code:

Invalid SQL: ALTER TABLE user ADD tdban smallint(5) unsigned DEFAULT 1 NOT NULL
mysql error: Duplicate column name 'tdban'

any help?

Thanks!

PixelFx 01-30-2004 07:29 AM

this looks killer, could you make a version for people that own boats? :P

PranK 01-30-2004 08:33 AM

PixelFx, it'd be damn easy to change the fields and take out the ones you dont want.

If you need any help, let me know. (I'm a boat person myself. :) )

EvilLS1 01-30-2004 10:56 AM

PixelFx,
You can easily change this version to suit your needs. Once installed, you can edit all of the timeslip fields in your admincp because they're just regular profile fields.

Prank,
You're getting that error because you've already ran the installer once. Open up TDinstaller.php and remove this section of code:
Code:

$DB_site->query("ALTER TABLE " . TABLE_PREFIX . "user ADD tdban smallint(5) unsigned DEFAULT 1 NOT NULL");
Then before running the installer, login to your admin panel and double check that no profile fields with IDs between 50-65 exist.. If they do, remove them. The run then installer again.

PranK 01-30-2004 12:12 PM

thanks EvilS1, i'll give it a go - but i removed the fields from the db manually and tried installing.. ?

oh well, will let you know! thanks again!

Christian

FastAttack 01-30-2004 12:22 PM

Man you beat me to it.. I had a working function but I am a slow ass coder :) anyhow thanks for releasing it.. I will try it tonight on my beta site!

PranK 01-30-2004 12:24 PM

nope...

Invalid SQL: ALTER TABLE userfield ADD field50 CHAR(250) NOT NULL
mysql error: Duplicate column name 'field50'

I deleted everything from the 'profilefield' table that wasn't one of my 7 fields... ie, everything to do with the vbtimeslips, i ran it again - same as above except changes to field51 or 52 etc ...

do you have the sql that i can just manually insert?

its strange, because all the fields seem to add fine, its not until you try to add your car details that it gives you an error....

Christian

EvilLS1 01-30-2004 02:25 PM

Prank,
Do you have phpmyadmin? If so, look under the userfield and profilefield tables and you'll see that the old fields or columns are still there. Thats whats causing the 'duplicate entry error'. If you will remove all old feilds/columns with IDs from 50-65 from both your userfield and profilefield tables, then run the new installer it will work. If you still can't get it I'll help you with it when I get home from work this afternoon.

FastAttack 01-30-2004 04:01 PM

Ok its up and running:

http://srtforums.com/forums/timeslips.php

the only thing I am going to do to it, when I have time is modify it so that it goes into a moderation queue since I didn't see this on this hack.. this will allow me to sort out the bogus time slips.. and allow my fastest time list mod to have an easier time than sorting out through random time slips.

FastAttack 01-30-2004 04:18 PM

the other thing I am going to change probably is make it so that you have the option to upload it ( if in the right membership group) or link it :D

magnus 01-30-2004 07:23 PM

Nice work, I had ported over the vB2 version and I have been using it since Gamma. I'll check out the new one -- thanks for updating! ;)

EvilLS1 01-30-2004 08:02 PM

FastAttack,
Looks nice!

magnus,
Thanks. :)

EvilLS1 01-30-2004 09:50 PM

@ Prank (or anyone else who's getting the 'duplicate field or column' error when running the installer):

Replace your timeslips.php & TDinstaller.php files with the ones attached to this post. Run the new installer, then follow the new instructions. If you've already done the file edits from the instructions in the first post of this thread, you'll need to start over and use the code in the attached instructions (all of the field IDs are different in this version). This will solve your problem.

PranK 01-30-2004 10:47 PM

Hey Evil,

Invalid SQL: INSERT INTO profilefield (profilefieldid,title,description,required,hidden, maxlength,size,displayorder,editable,type,data,hei ght,def,optional,searchable,memberlist,regex,form, html) VALUES (80,'Ride','What do you drive?',0,0,'20','20','80','1','input','','0','0', '0','0','0','0','','0')
mysql error: Duplicate entry '80' for key 1

Sorry to be such a pain! :(

How do i remove the fields from userfield? i can remove them from profilefield...

Thanks,

Christian

EvilLS1 01-30-2004 10:51 PM

Prank,
Do you have Yahoo IM? If not email me at EvilLS1TA@AOL.com

0ptima 01-31-2004 04:49 AM

Awseome job EvilS1!!! Im still on VB2, but once I install VB3, Im going to install your hack!!!

Drowned 01-31-2004 01:01 PM

WOOOHOOOOOOOOOOOOOOOOO... I have been waiting for this!

:bowdown: :bowdown: :bowdown: :bowdown: :bowdown:

My forum members LOVE YOUUUU!!! :nervous:

EvilLS1 01-31-2004 05:14 PM

Thanks fellas. :)

gmarik 01-31-2004 06:15 PM

Interesting ...

94DROPTOPZ 01-31-2004 06:28 PM

I have been waiting very patiently for this because this hack is awesome!!

This will work on my 3.0 Beta5 right?

EvilLS1 01-31-2004 06:32 PM

Quote:

Originally Posted by 94DROPTOPZ
I have been waiting very patiently for this because this hack is awesome!!

This will work on my 3.0 Beta5 right?

I don't know what all has changed since beta5 so I'm not sure. Its only been tested on RC1-RC3.

94DROPTOPZ 01-31-2004 06:34 PM

Quote:

Originally Posted by EvilLS1
I don't know what all has changed since beta5 so I'm not sure. Its only been tested on RC1-RC3.

Hmmm just when I got my hopes up :ermm:

EvilLS1 01-31-2004 06:36 PM

Quote:

Originally Posted by 94DROPTOPZ
Hmmm just when I got my hopes up :ermm:

You could always upgrade. RC3 looks and runs smoother than the older betas anyway, so it would be worth it. ;)

94DROPTOPZ 01-31-2004 08:17 PM

Quote:

Originally Posted by EvilLS1
You could always upgrade. RC3 looks and runs smoother than the older betas anyway, so it would be worth it. ;)

I might try to upgrade but Im just afraid to lose all of my posts and members. Maybe in the future. Thanks for the awesome hack

BarryA 02-01-2004 07:47 PM

Installed and works great...

http://www.fordpower.net/forums/timeslips.php?

EvilLS1 02-01-2004 11:05 PM

Looks great Barry. I added your link to the first post. :)

EvilLS1 02-01-2004 11:07 PM

Minor bug fix:

Open timeslips.php and find:
Code:

  $pagenav = construct_page_nav($userscount[users],"timeslips.php?$session[sessionurl]do=  $_REQUEST[do]&perpage=$perpage");
Replace it with:
Code:

  $pagenav = construct_page_nav($userscount[users],"timeslips.php?$session[sessionurl]do=$_REQUEST[do]&perpage=$perpage");
It fixes an unneeded space in the page navigation links (between do= and $_REQUEST[do]) which was causing the sort by method to be lost when viewing pages other than the first one.

First post has been updated.

BarryA 02-02-2004 01:51 AM

After playing with it for a while I have a few suggestions.

Add Torque (We all know thats really what wins races)... :)

It would be nice if the timeslips were attachments instead of links. We all know 6 months from now half of the links will be dead.

And thanks for making this, it saved me a lot of time from having to do it myself.

On Edit: I just re-read your post and saw that you are not adding any more features so I will take a shot at this myself.

DigitalEclipse 02-02-2004 02:45 AM

<a href="http://www.al-club3g.org/forums/timeslips.php" target="_blank">http://www.al-club3g.org/forums/timeslips.php</a>

Just added it, thanks!

EvilLS1 02-02-2004 03:06 AM

Quote:

Originally Posted by DigitalEclipse
I do have a small problem...I am running VBadvanced Home page. The link on the navbar doesnt work on there. Its trying to send me to http://www.al-club3g.org/timeslips.php, leaving out the /forums.

In your navbar template find:
Code:

<td class="vbmenu_control"><a href="timeslips.php?$session[sessionurl]">$vbphrase[timeslips]</a></td>
Replace it with:
Code:

<td class="vbmenu_control"><a href="$vboptions[bburl]/timeslips.php?$session[sessionurl]">$vbphrase[timeslips]</a></td>
That should fix it. :)

EvilLS1 02-02-2004 03:11 AM

Quote:

Originally Posted by BarryA
After playing with it for a while I have a few suggestions.

Add Torque (We all know thats really what wins races)... :)

It would be nice if the timeslips were attachments instead of links. We all know 6 months from now half of the links will be dead.

And thanks for making this, it saved me a lot of time from having to do it myself.

On Edit: I just re-read your post and saw that you are not adding any more features so I will take a shot at this myself.

Good suggestions. The v1.3 thread explains how to add extra fields (for torque or whatever you want). Its pretty easy. As for the upload feature, I might look into adding it when I upgrade to vb3.. That could be a while though, so if you guys want to add it yourself go for it. :)


All times are GMT. The time now is 01:38 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.01767 seconds
  • Memory Usage 1,865KB
  • 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
  • (9)bbcode_code_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (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