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)
-   -   Post Award Hack (https://vborg.vbsupport.ru/showthread.php?t=92677)

Abe1 07-21-2005 10:00 PM

Post Award Hack
 
Post Award Hack 2.1


Overview:
This hack will allow you to award individual posts. It will give you an option to add or remove the award. It will show a rosette on a post that has been awarded.

Features:
  • Shows a rosette on all awarded posts
  • Search for individuals awarded posts
  • Search for all awarded posts
  • Settings to allow what users or usergroups can give thanks
Installation information on hack:
  • Files edited: 0
  • Templates edited: 4
  • Files to upload: 1
  • Time to install: 5 minutes max
Updates:

Version 2.1 (2/8/06):
  • GOLD Release of this hack for vBulletin version 3.5
  • Added user and usergroup permissions via the acp options
  • Rewrote the template edits

Please post your comments or suggestions for this hack. I read ALL posts.

MAKE SURE YOU CLICK INSTALL!
You will get an email when a new version is released.

This hack is created for your use free of charge. No payment is requested. However, if you would like to donate money for the work I put in to this hack, a donation would show your appreciation.
https://vborg.vbsupport.ru/external/2010/02/12.gif

ForYou 07-22-2005 01:47 PM

Nice Award ,

is there away to give users Award , it's like this hack ,

Regards

Azhrialilu 07-22-2005 04:10 PM

Nice :D

Darth Gill 07-22-2005 04:34 PM

Where's the PHP file (award.php) and where is the SQL to update the database. Also I found a problem in the templates editing...

You have

in MEMBERINFO:
Code:

find:
--------------------------------------------------------------------
<if condition="$vboptions['profilelastpost']">
--------------------------------------------------------------------

replace with:
--------------------------------------------------------------------
<tr>
<td><a href="search.php?$session[sessionurl]do=findawards&amp;u=$userinfo[userid]">Find all awarded posts by $userinfo[username]</a></td>
</tr>
--------------------------------------------------------------------

It should be:
Code:

find:

<td><a href="search.php?$session[sessionurl]do=process&amp;showposts=0&amp;starteronly=1&amp;exactname=1&amp;searchuser=$userinfo[urlusername]"><phrase 1="$userinfo[username]">$vbphrase[find_all_threads_started_by_x]</phrase></a></td>
                                </tr>



after it add:

<!-- HACK -->
<tr>
<td><a href="search.php?$session[sessionurl]do=findawards&amp;u=$userinfo[userid]">Find all awarded posts by $userinfo[username]</a></td>
</tr>
<!-- HACK -->


Darth Gill 07-22-2005 04:45 PM

Nevermind I see the sql in the xml.

Abe1 07-22-2005 04:48 PM

Quote:

Originally Posted by Darth Gill
Where's the PHP file (award.php) and where is the SQL to update the database. Also I found a problem in the templates editing...

You have

in MEMBERINFO:
Code:

find:
--------------------------------------------------------------------
<if condition="$vboptions['profilelastpost']">
--------------------------------------------------------------------

replace with:
--------------------------------------------------------------------
<tr>
<td><a href="search.php?$session[sessionurl]do=findawards&amp;u=$userinfo[userid]">Find all awarded posts by $userinfo[username]</a></td>
</tr>
--------------------------------------------------------------------

It should be:
Code:

find:

<td><a href="search.php?$session[sessionurl]do=process&amp;showposts=0&amp;starteronly=1&amp;exactname=1&amp;searchuser=$userinfo[urlusername]"><phrase 1="$userinfo[username]">$vbphrase[find_all_threads_started_by_x]</phrase></a></td>
                                </tr>



after it add:

<!-- HACK -->
<tr>
<td><a href="search.php?$session[sessionurl]do=findawards&amp;u=$userinfo[userid]">Find all awarded posts by $userinfo[username]</a></td>
</tr>
<!-- HACK -->


First, thanks for that template error. It should have said "add before" instead or "replace". I fixed it in the zip download.

Second, the award.php is no longer needed. All actions are in the plugings. Yhe SQL change is also done by the installer when you import the plugings. It's a pritty cool way how the installer and uninstaller work using the plug-in sytem.

Darth Gill 07-22-2005 04:52 PM

Why do some of the templates link to award.php then if it's handled by the plugin?

Abe1 07-22-2005 04:57 PM

Quote:

Originally Posted by Darth Gill
Why do some of the templates link to award.php then if it's handled by the plugin?

I must have been sleeping when I made the installer. Anyways, I just fixed it over. award.php was not changed to showthread.php. The search features I had made already go to search.php.

Darth Gill 07-22-2005 05:08 PM

Oh, another bug, you have in the instructions to upload to images/buttons when it should be images/misc

Abe1 07-22-2005 06:04 PM

Quote:

Originally Posted by Darth Gill
Oh, another bug, you have in the instructions to upload to images/buttons when it should be images/misc

Anything else? I'm glad I call this Beta.

I had copied the image location from my Post Thanks Hack that is why is said button and not misc.

Anyways, all showld be good now.


All times are GMT. The time now is 03:06 AM.

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.01251 seconds
  • Memory Usage 1,749KB
  • 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
  • (4)bbcode_code_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (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