Go Back   vb.org Archive > vBulletin Modifications > Archive > Modification Graveyard

Reply
 
Thread Tools
Donations Progress Image (Wiki lookalike) Details »»
Donations Progress Image (Wiki lookalike)
Version: 1.00, by Mr Chad Mr Chad is offline
Developer Last Online: Apr 2009 Show Printable Version Email this Page

Category: Add-On Releases - Version: 3.6.4 Rating:
Released: 01-22-2007 Last Update: Never Installs: 36
 
No support by the author.

If you like it click


Installation Time: <2 mins
Files: 2
Products: 1
VB Version: This actually works on 3.6.4 (not sure about 3.5)

Description:

THIS HACK IS AN ADDITION TO [PayPal Donations]

This Hack will get your dontations stats (i.e. goal total, total donated and percentage) and write them to your Donations Image. It calls the stats from
your Database and writes them to an image called donations.jpg

This hack uses the PHP-GD Function, so be shure you have this enabled on your server. If you don?t be shure about this, ask your host or look in your PHP-Info.

Installation Instructions:
  1. Upload donationsimage.php to your /includes/cron/ dir
  2. Upload donations.jpg to your forum dir / (CHMOD 777 the donations.jpg)
  3. Install the product and run the scheduled task called "Donations Image"
  4. go to yourforum/donations.jpg
Examples:
[Example of Use]
FAQ: N/A

If you like it click


To add extra stats look in the signature.php for more info.

Show Your Support

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

Comments
  #52  
Old 01-31-2007, 03:56 AM
Mr Chad's Avatar
Mr Chad Mr Chad is offline
 
Join Date: Jul 2005
Posts: 911
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

you want both?
Reply With Quote
  #53  
Old 01-31-2007, 03:59 AM
Ahsin1 Ahsin1 is offline
 
Join Date: Mar 2006
Location: Toronto, Canada
Posts: 234
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

yeh i want both
Reply With Quote
  #54  
Old 01-31-2007, 04:29 AM
Mr Chad's Avatar
Mr Chad Mr Chad is offline
 
Join Date: Jul 2005
Posts: 911
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

find:
PHP Code:
$query_goals $vbulletin->db->query("SELECT * FROM ".TABLE_PREFIX."donation_goals WHERE active = '1' ORDER BY title ASC LIMIT 0,2");
while (
$row $vbulletin->db->fetch_array($query_goals)){
$amount $row['amount'];
$amount_formatted number_format($row['amount'], 2'.'',');
$goal_total $row['total_donated'];
$goal_total_formatted number_format($row['total_donated'], 2'.'',');
if (
$row['amount'] > 0){
  
$percentage round(($goal_total/$amount)*1002);
} else {
  
$percentage '0';
}

replace with:
PHP Code:
$amount 0;
$goal_total 0;
$query_goals $vbulletin->db->query("SELECT * FROM ".TABLE_PREFIX."donation_goals WHERE active = '1' ORDER BY title ASC LIMIT 0,2");
while (
$row $vbulletin->db->fetch_array($query_goals)){
$amount $amount $row['amount'];
$amount_formatted number_format($row['amount'], 2'.'',');
$goal_total $goal_total $row['total_donated'];
$goal_total_formatted number_format($row['total_donated'], 2'.'',');
if (
$row['amount'] > 0){
  
$percentage round(($goal_total/$amount)*1002);
} else {
  
$percentage '0';
}

i have not tested this so please respond with results.
Reply With Quote
  #55  
Old 01-31-2007, 04:43 AM
Ahsin1 Ahsin1 is offline
 
Join Date: Mar 2006
Location: Toronto, Canada
Posts: 234
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Working Perfect Thanks a lot for ur help
Reply With Quote
  #56  
Old 01-31-2007, 04:55 AM
Mr Chad's Avatar
Mr Chad Mr Chad is offline
 
Join Date: Jul 2005
Posts: 911
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Ahsin1 View Post
Working Perfect Thanks a lot for ur help
glad to hear
Reply With Quote
  #57  
Old 01-31-2007, 05:22 AM
masons masons is offline
 
Join Date: Jan 2007
Posts: 150
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

can I pay someone to fix mine up a little bit? I dont know how to make it appear on the left site column instead of at the top without it messing up the column width.

Also why is it showing $53 when it should be $20?
Reply With Quote
  #58  
Old 01-31-2007, 05:59 AM
Mr Chad's Avatar
Mr Chad Mr Chad is offline
 
Join Date: Jul 2005
Posts: 911
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by masons View Post
can I pay someone to fix mine up a little bit? I dont know how to make it appear on the left site column instead of at the top without it messing up the column width.

Also why is it showing $53 when it should be $20?
can you export your donation_goals table and post it here (from your database).
Reply With Quote
  #59  
Old 01-31-2007, 06:33 AM
masons masons is offline
 
Join Date: Jan 2007
Posts: 150
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi, Here it is!

Quote:
-- phpMyAdmin SQL Dump
-- version 2.9.0.3
-- http://www.phpmyadmin.net
--
-- Host: localhost
-- Generation Time: Jan 31, 2007 at 01:32 AM
-- Server version: 5.0.24
-- PHP Version: 4.4.4
--
-- Database: `peter_mason`
--

-- --------------------------------------------------------

--
-- Table structure for table `donation_goals`
--

CREATE TABLE `donation_goals` (
`id` int(255) NOT NULL auto_increment,
`title` varchar(255) NOT NULL default '',
`description` text NOT NULL,
`amount` decimal(10,2) NOT NULL default '0.00',
`total_donated` decimal(10,2) NOT NULL default '0.00',
`active` tinyint(1) NOT NULL default '1',
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=3 ;

--
-- Dumping data for table `donation_goals`
--

INSERT INTO `donation_goals` (`id`, `title`, `description`, `amount`, `total_donated`, `active`) VALUES
(2, 'Running of servers', 'We like to think of this site as a community, as such we hope we can all share in the cost of running this.', '200.00', '0.00', 1);
Also, I really dont know how to make the information look better and placed in the left column, any advise is welcome!
Reply With Quote
  #60  
Old 01-31-2007, 02:10 PM
Mr Chad's Avatar
Mr Chad Mr Chad is offline
 
Join Date: Jul 2005
Posts: 911
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hmm did you CHMOD the image 777 ? because there seems to be no donations so there is no reason for it to say any amount of money. also connect the donation buttons to your goal or it will not be recorded. I'm not sure what you mean abt your left column.
Reply With Quote
  #61  
Old 02-01-2007, 09:38 PM
frandy frandy is offline
 
Join Date: Mar 2006
Posts: 39
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is it possible to change the color/style of the image? Like have a gradient in the background? change the positioning of the text etc?
Reply With Quote
Reply

Thread Tools

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 01:51 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.07804 seconds
  • Memory Usage 2,321KB
  • 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
  • (2)bbcode_php
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)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