vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.5 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=113)
-   -   Toplist (https://vborg.vbsupport.ru/showthread.php?t=98646)

derekivey 06-03-2006 02:54 PM

By the way guys. Here are some screenshots of my progress so far. So far I have the feature that checks to see if the code has been added to their site done. I just need to make the cronjob that can automatically check it and validate it. The code checking feature is optional and can be disabled or enabled in the settings. All it does is looks for the board URL on each site and validates the site if it is found.

Derek

Mr.D 06-03-2006 03:09 PM

Great when can we aspect the release

derekivey 06-03-2006 03:16 PM

Not sure when, I've been busy studying for finals which are Tuesday and Wednesday. So hopefully after those 2 days sometime maybe, before, I don't know exactly when.

vonedaddy 06-05-2006 12:33 AM

Great hack, I have one small problem. The dynamic image.png button does not work, I editted according to your directions in post #450. Any ideas?

derekivey 06-05-2006 01:10 AM

Can you paste the contents of it here in tags please?

Thanks,
Derek

vonedaddy 06-06-2006 04:20 AM

PHP Code:

<?php 

/*======================================================================*\
|| #################################################################### ||
|| # Toplist Hack - Version 1.0.6                      # ||
|| # For vBulletin 3.5.3                          # ||
|| # ---------------------------------------------------------------- # ||
|| # By Derek Ivey (derek@modbb.com)                      # ||
|| # This hack may not be redistributed without my written permission # ||
|| #################################################################### ||
\*======================================================================*/

// ####################### SET PHP ENVIRONMENT ########################### 
error_reporting(E_ALL & ~E_NOTICE); 

// #################### DEFINE IMPORTANT CONSTANTS ####################### 
define('NO_REGISTER_GLOBALS'1); 
define('THIS_SCRIPT''toplist_dynamic_image');

// ######################### REQUIRE BACK-END ############################
// change the following to the path to your forum, with no ending slash.
chdir('/home/u1/vonaone/html/forum');
require_once(
'global.php'); 

// ####################################################################### 
// ######################## START MAIN SCRIPT ############################ 
// #######################################################################

// ############################## MISC STUFF #############################
header("Content-type: image/png"); 
$image imagecreatefrompng("images/toplist/buttons/dynamic/background.png");  
$color imagecolorallocate($image00255);
$font 3;

// ######################### GRAB INFO FROM DB ###########################
//$sql = "SELECT * FROM " . TABLE_PREFIX . "toplist_sites WHERE id='8'";
$sql "SELECT * FROM " TABLE_PREFIX "toplist_sites WHERE id='".$db->escape_string($_GET['id'])."'";
$sqlr $db->query_read($sql);
$sr $db->fetch_array($sqlr);

if (
$vbulletin->options['toplist_ranking_method'] == 0)
{    
    
$order '`in`';
}
else if (
$vbulletin->options['toplist_ranking_method'] == 1)
{
    
$order 'out';
}
else if (
$vbulletin->options['toplist_ranking_method'] == 2)
{
    
$order 'rating_average';
}
else
{
    
$order '`in`';
}

$rank1 "SELECT * FROM " TABLE_PREFIX "toplist_sites ORDER BY ".$order." DESC";
$rank2 $db->query_read($rank1);
$i 1;
while(
$rank3 $db->fetch_array($rank2))
{
    if (
$rank3['id'] == $_GET['id'])
    {
        
$rank $i;
    }
    else
    {
        
$i++;
    }
}

// ############################# CREATE IMAGE ############################
imagestring($image$font4428$rank$color);
imagestring($image$font5242$sr['in'], $color);
imagestring($image$font6256$sr['out'], $color);
imagestring($image$font5270$sr['rating_average'], $color);
imagestring($image2583$sr['name'], $color);

imagepng($image); 
imagedestroy($image);
?>


derekivey 06-06-2006 09:44 AM

See what the permissions are for that file. Make sure it has execute permissions (CHMOD 755). Please let me know if that fixes it.

Thanks,
Derek

vonedaddy 06-06-2006 11:46 AM

Quote:

Originally Posted by derekivey
See what the permissions are for that file. Make sure it has execute permissions (CHMOD 755). Please let me know if that fixes it.

Thanks,
Derek

No Sir, any other ideas?

derekivey 06-06-2006 07:25 PM

Make sure the .htaccess file is in that folder and also make sure your host supports .htaccess and also has GD.

vonedaddy 06-06-2006 09:59 PM

Quote:

Originally Posted by derekivey
Make sure the .htaccess file is in that folder and also make sure your host supports .htaccess and also has GD.

Yes to all of the above, we use gd 2 btw.


All times are GMT. The time now is 01:31 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.02342 seconds
  • Memory Usage 1,766KB
  • 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
  • (1)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (4)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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