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)
-   -   Yet Another Awards System [1.2.1] (https://vborg.vbsupport.ru/showthread.php?t=78934)

Dean C 04-15-2005 08:13 PM

I've removed your file Red Line :)

mtha 04-15-2005 09:22 PM

Quote:

Originally Posted by RED_LINE
hello

yes im sure about change the file correctly

the error somtimes apear not alaways :rolleyes:

can you check showthread.php plz

Regards,

:"> sorry Marco and DeanC, i fotgot that we cant distribute files.


RedLine, check and see if your showthread has anything like this:

ORDER BY au.issue_time

If you find any, paste that part of code (with the whole query) hereI dont have that line on my code, and your errror says that it got error at that location.


Quote:

the error somtimes apear not alaways :rolleyes:
can you test and see when and where it apprear?

make sure that you do upload the right file to the right location.

RED_LINE 04-16-2005 06:40 AM

thankyou MarcoH64

no porblem Dean :nervous:

Quote:

Originally Posted by mtha
:"> sorry Marco and DeanC, i fotgot that we cant distribute files.


RedLine, check and see if your showthread has anything like this:

ORDER BY au.issue_time

If you find any, paste that part of code (with the whole query) hereI dont have that line on my code, and your errror says that it got error at that location.




can you test and see when and where it apprear?

make sure that you do upload the right file to the right location.

i see that code you told me

(ORDER BY au.issue_time) at line 1304

PHP Code:

// [START HACK='Yet Another Award System' AUTHOR='HacNho']
                // Obtain list of awards for current user
                        
$alluserawards =  $DB_site->query("
                                SELECT a.*, au.*, post.userid, post.postid
                                FROM " 
TABLE_PREFIX "post AS post
                                INNER JOIN " 
TABLE_PREFIX "award_user AS au ON (au.userid=post.userid)
                                INNER JOIN " 
TABLE_PREFIX "award AS a ON (a.award_id=au.award_id)
                                WHERE post.postid IN (" 
$cache_postids ")
                                GROUP BY au.issue_id
                                ORDER BY au.issue_time
                        "
);
                        while( 
$ua $DB_site->fetch_array($alluserawards))
                        {
                                
$userawardscache[$ua['userid']][$ua['issue_id']] = $ua;
                        }
                        
$DB_site->free_result($alluserawards);
// [END HACK='Yet Another Award System' AUTHOR='HacNho'] 

thanx for help mtha :nervous:

deathemperor 04-16-2005 10:26 AM

Hi mtha,

I'm requesting for automatic awards like user has top post, user has the most reputation, user has the most post per day %, etc....

my site use UCS as the point system, and ppl is stealing money from the others -> reputation drops, I'd like to have an award like "Thief Master" with someone did most thief actions, and "The Worse Guy" if he has least reputation.

Below is the best example from Gamespot community, take a look and these links:

http://www.gamespot.com/user/profile.html?user=duxup
http://www.gamespot.com/user/emblem.html?id=mod
http://www.gamespot.com/user/emblem.html?id=badtaste

It is to make a superb awards system.

mtha 04-16-2005 06:33 PM

Quote:

Originally Posted by RED_LINE
i see that code you told me

(ORDER BY au.issue_time) at line 1304

PHP Code:

// [START HACK='Yet Another Award System' AUTHOR='HacNho']
                // Obtain list of awards for current user
                        
$alluserawards =  $DB_site->query("
                                SELECT a.*, au.*, post.userid, post.postid
                                FROM " 
TABLE_PREFIX "post AS post
                                INNER JOIN " 
TABLE_PREFIX "award_user AS au ON (au.userid=post.userid)
                                INNER JOIN " 
TABLE_PREFIX "award AS a ON (a.award_id=au.award_id)
                                WHERE post.postid IN (" 
$cache_postids ")
                                GROUP BY au.issue_id
                                ORDER BY au.issue_time
                        "
);
                        while( 
$ua $DB_site->fetch_array($alluserawards))
                        {
                                
$userawardscache[$ua['userid']][$ua['issue_id']] = $ua;
                        }
                        
$DB_site->free_result($alluserawards);
// [END HACK='Yet Another Award System' AUTHOR='HacNho'] 

thanx for help mtha :nervous:

What version of YAAS are you using? did you upgrade to the last version? Since your pasted code is different from the one in my instruction, I think you DID NOT make the correct changes to your files file.
PLEASE download the NEW zip file and follow instruction there for upgrade, and re-edit ALL files.

mtha 04-16-2005 06:46 PM

Quote:

Originally Posted by deathemperor
Hi mtha,

I'm requesting for automatic awards like user has top post, user has the most reputation, user has the most post per day %, etc....

my site use UCS as the point system, and ppl is stealing money from the others -> reputation drops, I'd like to have an award like "Thief Master" with someone did most thief actions, and "The Worse Guy" if he has least reputation.

Below is the best example from Gamespot community, take a look and these links:

http://www.gamespot.com/user/profile.html?user=duxup
http://www.gamespot.com/user/emblem.html?id=mod
http://www.gamespot.com/user/emblem.html?id=badtaste

It is to make a superb awards system.

The example looks really nice.
however, i think that your would lead to a seperate award system, or a branch of it.

I dont really like the idea of giving awards "automatically" very much, for right now, but that'd be a nice idea.
However, for this to work,you dont have award issue time and reason, you also dont have award history. just the current users has, says, top posts (or reputation) showing up, right? if tomorrow, someone else has higher score, the former one will lose his award?

datainternet 04-17-2005 01:24 PM

Hi,

At first: This is really really a great hack. Thanks dude :).

But I have two little Questions:

1. In the request_award.php - file there is an option called "REDIRECT OPTIONS:". There you can choose Option 0 to show a thank you message.

Now my question: Is it possibly to show this message AND redirect after some seconds to another page?

This would be very nice :).

2. I translated my hack to german speech and now I have 1 little problem:

In the request award page there are 2 different buttons in the bottom: "Submit" and "Reset". Where can i find this values to translate them?

When this two little problems are solved I really love this hack :).

MFG datainternet

mtha 04-17-2005 04:23 PM

Quote:

Originally Posted by datainternet
Hi,

1. In the request_award.php - file there is an option called "REDIRECT OPTIONS:". There you can choose Option 0 to show a thank you message.

Now my question: Is it possibly to show this message AND redirect after some seconds to another page?

for this, you can ask Erwin here:
https://vborg.vbsupport.ru/showthread.php?t=66082
I use his hack for the form, basically.

Quote:

In the request award page there are 2 different buttons in the bottom: "Submit" and "Reset". Where can i find this values to translate them?
sorry I had those things hard-coded.
you can edit awards_request_form template, and change
value="Submit" => value="$vbphrase[submit]"
value="Reset" => value="$vbphrase[reset]"

Ben5150 04-18-2005 12:56 AM

has anybody got this error
Database error in vBulletin 3.0.7:

Invalid SQL: CREATE TABLE vb3_award (
award_id smallint(5) unsigned NOT NULL auto_increment,
award_cat_id smallint(5) NOT NULL default '1',
award_name varchar(50) NOT NULL default '',
award_desc varchar(250) NOT NULL default '',
award_icon_url varchar(250) NOT NULL default '',
award_img_url varchar(225) NOT NULL default '',
award_displayorder smallint(5) NOT NULL default '0',
PRIMARY KEY (award_id)
) TYPE=MyISAM;

mysql error: You have an error in your SQL syntax near ';
' at line 10

mysql error number: 1064
if so how to fix it

mtha 04-18-2005 04:08 AM

Quote:

Originally Posted by Ben5150
has anybody got this error
Database error in vBulletin 3.0.7:

Invalid SQL: CREATE TABLE vb3_award (
award_id smallint(5) unsigned NOT NULL auto_increment,
award_cat_id smallint(5) NOT NULL default '1',
award_name varchar(50) NOT NULL default '',
award_desc varchar(250) NOT NULL default '',
award_icon_url varchar(250) NOT NULL default '',
award_img_url varchar(225) NOT NULL default '',
award_displayorder smallint(5) NOT NULL default '0',
PRIMARY KEY (award_id)
) TYPE=MyISAM;

mysql error: You have an error in your SQL syntax near ';
' at line 10

mysql error number: 1064
if so how to fix it

hmm, have no idea yet. you can try to manually enter the database, or run "upgrade"


All times are GMT. The time now is 10:29 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.01361 seconds
  • Memory Usage 1,784KB
  • 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
  • (2)bbcode_php_printable
  • (8)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)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