vb.org Archive

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

PranK 11-17-2003 06:41 AM

Evil - you rock!

Thanks mate!

oly51 11-18-2003 12:59 AM

EvilLS1, I am very impressed with the amount of support you have shown for this hack!
Great job, keep up the good work!

EvilLS1 11-18-2003 12:08 PM

Thank you. :)

carlitosz 11-18-2003 04:00 PM

EvilLS1,

Please check your mail.

Carlos.

EvilLS1 11-19-2003 02:56 AM

carlitosz,
I replied to your email but it bounced back to me. Please check your PMs.

EvilLS1 11-26-2003 12:09 AM

Here's a little add-on that some of you might want..

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

{edit} This is for v1.3 only.

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:

</head>
Above it add:
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>

Find:
Code:

<form action="member.php" method="post">
Replace it with:
Code:

<form action="member.php" name="vbform" method="post" onSubmit="return validate(this)">
Done.

Silverstangs 11-28-2003 12:26 AM

I now have it installed on vb2.3.3 and it works great. I did make a dumb mental error, I added the templates to only one set. Just remember they all need the same templates.

I am going to modify the hack a little and add "Torque" for one of the fields.

--Scott
aka Silver

PranK 11-28-2003 08:15 AM

I was using this on my old VB 233... i now use VB3 B7... what are the possibilities of me getting it to work on that?

Thanks in advance!

EvilLS1 11-28-2003 07:25 PM

PranK,
The hack will have to be re-written for VB3 since the code is all new. I do plan to port this over for VB3 once the RC versions are released though.

PranK 11-28-2003 10:53 PM

Ahh sweet - you rock!

Thanks mate!

Christian

bandit022 12-03-2003 08:43 PM

first off, i'd like to thank EvilLS1 for a great hack.. been looking for something that could organize timeslips easily.

i really want to get this working on my board... but i get the following errors:

i get this when i try to view the Who's Online:

Warning: main(.././global.php): failed to open stream: No such file or directory in /home/bandit/public_html/forum/online.php on line 7

i get these when i try to view a member's profile:

Warning: main(.././global.php): failed to open stream: No such file or directory in /home/bandit/public_html/forum/member.php on line 1372

Warning: main(): Failed opening '.././global.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/bandit/public_html/forum/member.php on line 1372

Fatal error: Call to undefined function: getpermissions() in /home/bandit/public_html/forum/member.php on line 1374

i get these when i try to edit my vehicle proflie:

Warning: main(.././global.php): failed to open stream: No such file or directory in /home/bandit/public_html/forum/member.php on line 607

Warning: main(): Failed opening '.././global.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/bandit/public_html/forum/member.php on line 607

Fatal error: Call to undefined function: show_nopermission() in /home/bandit/public_html/forum/member.php on line 611

any suggestions? seems like there's something wrong with .././global.php but i'm not sure, i'm pretty new at all of this.

thanks for your help,

-jeff

Josh Combs 12-03-2003 09:21 PM

Quote:

Originally Posted by bandit022
first off, i'd like to thank EvilLS1 for a great hack.. been looking for something that could organize timeslips easily.

i really want to get this working on my board... but i get the following errors:

i get this when i try to view the Who's Online:

Warning: main(.././global.php): failed to open stream: No such file or directory in /home/bandit/public_html/forum/online.php on line 7

i get these when i try to view a member's profile:

Warning: main(.././global.php): failed to open stream: No such file or directory in /home/bandit/public_html/forum/member.php on line 1372

Warning: main(): Failed opening '.././global.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/bandit/public_html/forum/member.php on line 1372

Fatal error: Call to undefined function: getpermissions() in /home/bandit/public_html/forum/member.php on line 1374

i get these when i try to edit my vehicle proflie:

Warning: main(.././global.php): failed to open stream: No such file or directory in /home/bandit/public_html/forum/member.php on line 607

Warning: main(): Failed opening '.././global.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/bandit/public_html/forum/member.php on line 607

Fatal error: Call to undefined function: show_nopermission() in /home/bandit/public_html/forum/member.php on line 611

any suggestions? seems like there's something wrong with .././global.php but i'm not sure, i'm pretty new at all of this.

thanks for your help,

-jeff

what version of vb are you running?

bandit022 12-03-2003 10:29 PM

Quote:

Originally Posted by GAGT2NV
what version of vb are you running?

oh crap, forgot to mention that.

2.3.0 with a good list of hacks installed.

bandit022 12-03-2003 11:54 PM

nevermind.. i fixed it

bandit022 12-07-2003 01:57 AM

hey evil,

is there any way you could add a feature to show the dyno chart to prove the WHP, and make it like the 1/4 mile thing so that it would require a dyno chart for WHP over a certain amount?

just wondering cause i think this might be a problem on my board in a while and it might become hard to moderate what's real and what's fake without a dyno chart.

thanks,

-jeff

EvilLS1 12-07-2003 08:18 PM

Bandit,
Go into your admin panel and add the new profile field for the dynosheet link.

Then hold your mouse over the "edit" link for the new field and make a note of the field ID # (at the end of the URL).

Then open timeslips.php and find:
Code:

} else if ($action=="username") {
  $cond.=" WHERE userfield.field55>'".intval($number)."'";
  $condition.=" AND userfield.field55>'".intval($number)."'";
  $orderby="user.username";
  $direction=ASC;

Below it add:
Code:

} else if ($action=="graph") {
  $condition.=" AND userfield.fieldXX!='' AND userfield.field51>'".intval($number)."'";
  $cond.=" WHERE userfield.fieldXX!=''";
  $orderby="userfield.field51";
  $direction=ASC;
  $bracketA="<b>[</b>";
  $bracketB="<b>]</b>";

In the code above, replace the highlighted Xs with the ID# of the new field you added.

Still in timeslips.php find:
Code:

$ride= $userinfo[field50];
Below it add:
Code:

if ($userinfo[fieldXX]!=""){
  $graph="<a href=\"$userinfo[fieldXX]\" target=\"_blank\"><img src=\"{imagesfolder}/slipicon.gif\"  border=0></a>";
}else{
  $graph="";
}

Again, replace the highlighted Xs with the ID# of the new field you added.

Now in your "timeslips" template find:
Code:

<option value="$bburl/timeslips.php?s=$session[sessionhash]&action=username">Username</option>
Below it add:
Code:

<option value="$bburl/timeslips.php?s=$session[sessionhash]&action=graph">Dyno Graph</option>
Find:
Code:

        <td bgcolor="{categorybackcolor}" colspan="9"><normalfont color="{categoryfontcolor}"><CENTER><b> Timeslip Database</b></CENTER></normalfont></td>
Replace it with:
Code:

        <td bgcolor="{categorybackcolor}" colspan="10"><normalfont color="{categoryfontcolor}"><CENTER><b> Timeslip Database</b></CENTER></normalfont></td>
Find:
Code:

<td bgcolor="{tableheadbgcolor}" align="center"><smallfont color="{tableheadtextcolor}">$bracket7<b>WHP</b>$bracket8</smallfont></td>
Below it add:
Code:

<td bgcolor="{tableheadbgcolor}" align="center"><smallfont color="{tableheadtextcolor}">$bracketA<b>Graph</b>$bracketB</smallfont></td>
Find:
Code:

<td bgcolor="{categorybackcolor}" colspan="9">
Replace it with:
Code:

<td bgcolor="{categorybackcolor}" colspan="10">

In your "timeslipsbit" template find:
Code:

<td bgcolor="{secondaltcolor}">$avghp$rwhp</td>
Below it add:
Code:

<td bgcolor="{firstaltcolor}">$graph</td>
In member.php and register.php find all instances of this:
Code:

(50,51,52,53,54,55,56,57,58,59,60,61,62,63)
And replace them with thise:
Code:

(50,51,52,53,54,55,56,57,58,59,60,61,62,63,XX)
(Change the highlighted XXs to the field ID for the dynograph.)

In your modifytimeslip template find:
Code:

<script language="javascript">
<!--
function validate(theform) {
        if ((theform.field55.value<12) && (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>

Replace it with:
Code:

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

Again, replace the highlighted XXs with the dynosheet field ID.

I haven't tested this but it should work if you make all of the changes.

Dewayne

bandit022 12-07-2003 09:34 PM

holy crap! you're the man Dewayne!

didn't realize it would require so many changes... thanks for taking the time to do that for me!

i'll probably make the changes a little later tonight, i'll let you know if it works.

thanks again,

-jeff

bandit022 12-08-2003 01:37 PM

works like a charm. :D

thanks a million!

-jeff

PKRWUD 12-09-2003 11:40 AM

Wow, a hack thread with unnecessary drama, too! ;)

First off, let me say that I am just blown away by not only this hack, but the support that comes with it. This was probably the easiest hack I've ever installed, and will be a favorite at my site.

That being said, I have one problem. The database page has nothing listed until someone makes an entry, so I entered my info, and submitted it, but it's not listed. I tried changing the Sort By, but it didn't matter, the page still has no one listed. What did I do wrong?

http://www.ricehatersclub.com/vbulletin/timeslips.php

http://www.ricehatersclub.com/vbulle...ails&userid=94

Thanks!

~Chris

EvilLS1 12-09-2003 07:06 PM

@ Jeff,
You're welcome. :)

@ Chris,
I think maybe you forgot to add the timeslipsbit template.. If not, check the spelling of that template name.

timeslipsbit template:

Code:

<tr align="center">
<td bgcolor="{firstaltcolor}">$rank</td>       
<td bgcolor="{secondaltcolor}"><normalfont><a href="member.php?s=$session[sessionhash]&action=getinfo&userid=$userinfo[userid]">$username</a></normalfont></td>
<td bgcolor="{firstaltcolor}">$ride</td>
<td bgcolor="{secondaltcolor}">$avghp$rwhp</td>
<td bgcolor="{firstaltcolor}">$avgsf$sixty</td>
<td bgcolor="{secondaltcolor}">$avge$eighth$atmph1$eighthmph$spacer$avgemph</td>
<td bgcolor="{firstaltcolor}">$avgq$quarter$atmph2$quartermph$spacer$avgqmph</td>
<td bgcolor="{secondaltcolor}"><smallfont>$details</smallfont></td>
<td bgcolor="{firstaltcolor}">$slip</td>
</tr>

Let me know if that doesn't fix it.

Dewayne

PKRWUD 12-09-2003 07:58 PM

Damn, you're good. I forgot the second "s" in the name of the timeslipsbit template.

*clicks Install with immense pleasure!*

Please tell me you have other hacks, yours work great, and your instructions are excellent, especially to a know-nothing like me. I really like this hack, and the ease with which I installed it.

Thanks again!

Take care,
~Chris

EvilLS1 12-09-2003 08:40 PM

Thanks Chris. :) Glad its working for you now.

SVTOA 12-13-2003 03:22 PM

Quote:

Originally Posted by EvilLS1
I also added this to the Timeslip Database hack. Check the demo (my site) to see it. Thanks to brendonm and SVTOA for the idea. :)


I don't know what all the drama in this thread is about, and I don't want anyone speaking for me. I know that EvilLS1 has done a GREAT job with his hack. I do not see what he has done as "copying" my idea, and I think the level of support he has offered to those who want to use his creation is A-1 TOP NOTCH and he should be commended for same.

He thanked me and brendonm for ideas, that's an indication of a stand-up guy. I have had some people on other boards accuse me of copying HIS idea, such is life I guess. The bottom line is, when people take the time to help others improve their forums, it's all good.

My version of this hack is nowhere near as comprehensive as Evil's is...
I have made some changes to it, so it loads faster with less draw on the database...

http://www.mach-1.org/vbulletin/quartermileranking.php?s=&action=getall&what=&ltr= &perpage=25&orderby=field6&ausername=&=&direction= ASC&fields[6]=.&pagenumber=1


You have to copy and paste the link to have it work for you...

EvilLS1- take a bow, you have done a GREAT job on this and that is all there is to it. Only thing I can say is, I wish that you had done all this back when I was asking for something like this.. NOBODY replied to my hack request, so I kinda started one of my own... In hindsight, it kind of forced me to learn more about PHP and that's a good thing.

Peace and Happy Holidays!

Greg

SVTOA 12-13-2003 05:21 PM

Quote:

Originally Posted by EvilLS1
sunrunner_pei,

In admin/functions.php find:
Code:

$jointime = (time() - $post[joindate]) / 86400; // Days Joined
Above it add:
Code:

if ($post[field55]>0){
  $postquarter= $post[field55];
}else{
  $postquarter="";
}
if ($post[field56]>0){
  $postatmph= "@";
  $postmph= $post[field56];
}else{
  $postatmph="";
  $postmph="";
}

Then in your postbit template put this where you want the 1/4 mile ET to show up.:
Code:

$postquarter$postatmph$postmph
This way it will only show up if an ET has been entered by the user.


That's awesome- to add: The way that is written, it will only display the ET/MPH. If you want to add some text such as "Best ET" to display along with the stats, add:
Code:

$posttext= "Best ET";
to the line above
Code:

$postatmph= "@";
Then add:
Code:

$posttext$postquarter$postatmph$postmph
to your postbit in the area where you want this to display.

Imprezer 12-30-2003 03:09 AM

Great hack!

Installed.

My peeps will like it.

Alex
www.i-club.com

Carnage Media 01-18-2004 07:05 PM

Installed and awesome!

what if you wanted to add another category getting people to tell what kind of suspension they have

like:
stock
tubbed
etc.

maybe in a drop down box?

also, how do you edit in case somebody puts something false in?

Thanks again Evil, I love this one.

SVTBlackLight01 01-18-2004 07:22 PM

Hey Evil,

Have you looked into making this hack for vb3?

EvilLS1 01-18-2004 08:53 PM

Carnage,
Thank you.
To add other fields check these two posts:
https://vborg.vbsupport.ru/showpost....0&postcount=32
https://vborg.vbsupport.ru/showpost....&postcount=136

Quote:

also, how do you edit in case somebody puts something false in?
You simply go into your admin panel and edit that user as you normally would. His timeslip info will be listed there. :)

Quote:

Have you looked into making this hack for vb3?
I plan to within the next few weeks.. I just haven't had enough time to look into it yet (still using VB2).

SVTBlackLight01 01-19-2004 04:12 AM

Sounds great. Still using VB2 here too. I probably won't be upgrading for a while.

sticky 01-21-2004 07:26 AM

I can't believe I just found this, I wanted something just like this a few months ago on my forum but I thought it would be too complicated for anyone to ever do. This is the greatest hack in the world.

sticky 01-21-2004 07:30 AM

Question: Would it be possible to sort by make? I could really use that feature so a user could see what the fastest car in each make was.

Another thing, with the whp column, would you be able to make it so someone can link to their dyno run the same way you do it with the slip?

Edit: What if a person has more than one car?

EvilLS1 01-21-2004 11:04 PM

Thanks for the kind words.

Quote:

Question: Would it be possible to sort by make? I could really use that feature so a user could see what the fastest car in each make was.
It is possible but would require alot of work. As it is right now your users can add their vehicle in a regular text input field.. Since its not fool-proof they could enter several different things which would not sort correctly.. For example, if one user enters "Mustang" and another user enters "Ford Mustang" and yet another user enters "stang" they will not be sorted together.

In order to make it possible to sort by vehicles you would need separate select box input fields for vehicle make, model, and year. This would take some time to add, and unfortunately I don't have alot of free time right now. However, if you feel comfortable editing a little php code you could do it yourself. If you'll read back through this thread I've posted instructions on how to add select box input fields and sort by them.

Quote:

Another thing, with the whp column, would you be able to make it so someone can link to their dyno run the same way you do it with the slip?
Yes, its all explained in this post:
https://vborg.vbsupport.ru/showpost....&postcount=136

Quote:

Edit: What if a person has more than one car?
You could add an extra field to list other cars, but the timeslips page can only show/sort the info for one car per user.

Carnage Media 01-22-2004 12:19 AM

Evil, I've been searching but can't find it.

My members would like for the timeslips to be able to show what engine size instead of WHP.

How can I do that?

Thanks.

sticky 01-22-2004 12:53 AM

Evil, if necessary, I will pay you to have a custom version of this made for my site to compensate for your time.

EvilLS1 01-22-2004 12:56 AM

Quote:

Originally Posted by Carnage Media
Evil, I've been searching but can't find it.

My members would like for the timeslips to be able to show what engine size instead of WHP.

How can I do that?

Thanks.

In timeslips.php find:
Code:

} else if ($action=="rwhp") {
  $cond.=" WHERE userfield.field51>'".intval($number)."'";
  $condition.=" AND userfield.field51>'".intval($number)."'";
  $orderby="userfield.field51";
  $direction=DESC;
  $bracket7="<b>[</b>";
  $bracket8="<b>]</b>";

Replace it with:
Code:

} else if ($action=="cubes") {
  $cond.=" WHERE userfield.field61>'".intval($number)."'";
  $condition.=" AND userfield.field61>'".intval($number)."'";
  $orderby="userfield.field61";
  $direction=DESC;
  $bracket7="<b>[</b>";
  $bracket8="<b>]</b>";

Find:
Code:

if ($userinfo[field51]>0){
  $rwhp= $userinfo[field51];
}else{
  $rwhp="";
}

Replace it with:
Code:

if ($userinfo[field61]!=""){
  $cubes= $userinfo[field61];
}else{
  $cubes="";
}

In your timeslips template find:
Code:

<option value="$bburl/timeslips.php?s=$session[sessionhash]&action=rwhp">Horsepower</option>
Replace it with:
Code:

<option value="$bburl/timeslips.php?s=$session[sessionhash]&action=cubes">Displacement</option>
Find:
Code:

<b>WHP</b>
Replace it with:
Code:

<b>C.I.</b>
In your timeslipsbit template find:
Code:

<td bgcolor="{secondaltcolor}">$avghp$rwhp</td>
Replace it with:
Code:

<td bgcolor="{secondaltcolor}">$cubes</td>

EvilLS1 01-22-2004 01:04 AM

Quote:

Originally Posted by sticky
Evil, if necessary, I will pay you to have a custom version of this made for my site to compensate for your time.

Thanks for the offer, but $$ is not really the issue. I'm just so busy with other things right now that I don't have time to do any custom work. I haven't even got around to upgrading my own site yet.

Maybe after I finish with all of my own projects.. But that'll probably be a while.

Carnage Media 01-22-2004 01:15 AM

thank you for the fast response and it worked perfect

EvilLS1 01-22-2004 01:17 AM

You're welcome. :)

EvilLS1 01-24-2004 08:15 PM

For those interested, I've started working on a new version of this for VB3. I can only work on it in my spare time (and my spare time is limited) so its probably gonna be a few weeks before I release it. Should be pretty nice though.

Dewayne

0ptima 01-24-2004 08:21 PM

Quote:

Originally Posted by EvilLS1
For those interested, I've started working on a new version of this for VB3. I can only work on it in my spare time (and my spare time is limited) so its probably gonna be a few weeks before I release it. Should be pretty nice though.

Dewayne

Woohoo !!! Thanks!!!


All times are GMT. The time now is 07:43 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.01405 seconds
  • Memory Usage 1,891KB
  • 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
  • (39)bbcode_code_printable
  • (12)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
  • (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