The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
how do i do this?[php table change]
first, sorry is this is in the wrong forum...
i want to display the progress of a fundraise from donations for a forum. i've been searching but i don't know what i should be searching for. so far i've found this http://www.evolt.org/help_support_evolt/index.html thats exactly the effect i'm looking for(top left). if someone could explain how its done? ideally I want to have a form in the admin protected section of vbulletin where we can enter our total needed and achieved thus far. then it displays like evolt.org on the /index.php. some idea of how its done or what kind of script i can use will help. cheers |
#2
|
||||
|
||||
you could just do something like finding the percentage then using a second table inside with a different colored background and do
<table><tr> <td width=".$percent." bgcolor="green"> </td> <td bgcolor="red"></td> </tr><table> smoething to that effect. |
#3
|
||||
|
||||
PHP Code:
|
#4
|
|||
|
|||
that looks good thanks.
how can i store the values? |
#5
|
||||
|
||||
thats a little more difficult if you want it intergrated with vb, if you dont mind waiting till Im done with my current project I can make a hack out of this, till then you could just use
$value1="189"; // Amount Recieved $value2="1000"; // Amount We Need assuming you have earned $189 of the $1000 you need. |
#6
|
|||
|
|||
no i don't need it integrated. I can put that php you made me into the header i would like a
value.cfg file or something the admin could edit and upload to the webroot. i don't know how to make the values come from another file. thanks for your help already has made it seem easier though |
#7
|
||||
|
||||
include("../value.php");
then put the values in value.php |
#8
|
|||
|
|||
thanks i'll tinker with this tomorrow after some sleep.
cheers |
#9
|
|||
|
|||
hmm i'm not good at this. i can't even make the script start to work. i should say i know nothing about php i'm just fiddling trying to make it work.
i've got my value.php file in the same dir. inside this file i only have $value1="682"; // Amount Recieved $value2="1400"; // Amount We Need now i'm trying to use the php you made me print this html, changing the $ from the values in the include file and altering the size of the table to reflect the donations.. Code:
<table width="337" height="52" bgcolor="black" align="center"> <tr> <td height="26" colspan="2"> <img src="images/donation.gif" width="337" height="26"> </td> </tr> <tr height="26"> <td width="65%" bgcolor="#FF0000"> <p align="right">$648 received </p> </td> <td> <p align="right"><font color="red">$880 needed</font></p> </td> </tr> </table> PHP Code:
Quote:
thanks for any pointers you can give me... |
#10
|
||||
|
||||
First File table.php:
PHP Code:
Second File value.php: PHP Code:
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|