Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
QuoteIt! 2.0 - Quote Management System Details »»
QuoteIt! 2.0 - Quote Management System
Version: 2.03, by Cap'n Steve Cap'n Steve is offline
Developer Last Online: May 2010 Show Printable Version Email this Page

Version: 3.0.7 Rating:
Released: 04-10-2005 Last Update: 11-05-2005 Installs: 47
DB Changes
 
No support by the author.

QuoteIt! version 2.0

QuoteIt! allows you to have a database of quotes integrated with your forum. Users submit quotes that can then be voted on by the other users, using your choice of two rating systems. The average installation will show a random quote on the forum home page, but you can include it on any vBulletin page. This was developed on vBulletin 3.0.7, but should work on 3.0.0 and above.

You can see a demo on forums.monkeycrap.com.
Instructions for adding a random quote to vBadvanced and vBindex are in this post.


Features (features new to 2.0 are in yellow)

Random Quote
- a random quote can be shown on any vBulletin powered page
- the administrator can set a default rating threshold that quotes must meet before showing up as the random quote
- the quote shown is much more random than in previous versions


Quote Database
- quotes can only be edited or deleted by an administrator
- quotes can be viewed individually or listed on several pages
- quotes can be sorted by total score, average score, author, submitter, or date added
- quotes now have a "context" field that can be turned on or off to include more information about the quote
- each post and private message now has a "Submit to Quotes" link that allows users to quote things said on your forum more easily


Quote Ratings System
- quotes can be rated either plus/minus or on a scale from 1 to 5
- quotes below a certain total score or average score can be filtered out


Quote Management
- quotes can either be automatically approved or moderated
- the administrator can now edit quotes
- the quote moderation que is now more like the que for posts, enabling the moderation of several quotes at once




Don't forget to click

This hack is based on QuoteIt! 1.2, originally by magnus. The "submit post" feature was inspired by an addon by CtrlAltDel. The location code is based on a post by Acido.

You may release translations of this hack as long as the original credits are included. Otherwise, you not redistribute this hack without permission from me.

Show Your Support

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

Comments
  #62  
Old 04-15-2005, 02:04 PM
j_86 j_86 is offline
 
Join Date: May 2003
Posts: 275
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you, I will do soon.

Also been redesigning the listbit templates;

http://www.ugamer.net/forums/quotes.php
Reply With Quote
  #63  
Old 04-15-2005, 02:33 PM
j_86 j_86 is offline
 
Join Date: May 2003
Posts: 275
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'd like to be able to generate the following information, but I do not know how to.

On quotes.php (when listing quotes), I want to be able to display the following information;

Total number of quotes
Total number of quotes in moderation queue

Anyone care to help? Thanks;

Jamie
Reply With Quote
  #64  
Old 04-15-2005, 02:46 PM
Cap'n Steve's Avatar
Cap'n Steve Cap'n Steve is offline
 
Join Date: Feb 2004
Location: Kalamazoo, MI, USA
Posts: 745
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

$quotecount['quotes'] holds the number of quotes that are approved and meet the rating threshold the user has set.

If you want to add more, in quotes.php find:
PHP Code:
$gradient2 str_replace('#'''$stylevar['alt2_bgcolor']); 
Under that you can add:
PHP Code:
$totalcount $DB_site->query_first('
    SELECT COUNT(*) AS all FROM ' 
TABLE_PREFIX 'quotes
'
); 
or
PHP Code:
$modcount $DB_site->query_first('
     SELECT COUNT(*) AS moderation FROM ' 
TABLE_PREFIX 'quotes
          WHERE approved = 0
 '
); 
In this example, $totalcount['all'] will be the number of total quotes (add "WHERE approved = 1" to only count quotes that have been approved) and $modcount['moderation'] will be the number of quotes awaiting moderation.
Reply With Quote
  #65  
Old 04-16-2005, 04:27 PM
j_86 j_86 is offline
 
Join Date: May 2003
Posts: 275
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks again Cap'n Steve.

I have a few more modifications i'd like to make (and release them as addons later, or maybe even give them back to you to release a Version3? ).

I want to be able to send a PM to people who submitted a quote on approval/rejection.

I have this PM code;

PHP Code:
function SendPM($message,$title,$to,$from)
{
    global 
$DB_site;
    
    
// Permssions Crap XD your getting a damn PM!! XD
    // Parse It Out
    
$title addslashes(htmlspecialchars_uni(fetch_censored_text($title)));
    
$message addslashes(fetch_censored_text($message));
    
$to=$DB_site->query_first("select * from ".TABLE_PREFIX."user where userid='{$to}'");  // Grab Member Its Going TO
    
$from=$DB_site->query_first("select * from ".TABLE_PREFIX."user where userid='{$from}'"); // Grab Member Its Coming FROM
    
    // Insert The Message
    
$to_string["$to[userid]"] = $to['username'];
    
$now=time();
    
$DB_site->query("insert into ".TABLE_PREFIX."pmtext (fromuserid,fromusername,title,message,touserarray,iconid,dateline,showsignature  ,allowsmilie) values ('{$from['userid']}','".addslashes($from['username'])."','{$title}','{$message}','".addslashes(serialize($to_string))."','4','{$now}','1','1')");
    
// id thingy
    
$DB_site->query("insert into ".TABLE_PREFIX."pm (pmtextid, userid) values (".$DB_site->insert_id().", '{$to['userid']}')");
    
    if (
$to['pmpopup'])
    {
        
$DB_site->shutdown_query("UPDATE " TABLE_PREFIX "user SET pmtotal=pmtotal+1, pmunread=pmunread+1, pmpopup=2 WHERE userid='{$to['userid']}'");
    }
    else
    {
        
$DB_site->shutdown_query("update ".TABLE_PREFIX."user set pmtotal=pmtotal+'1',pmunread=pmunread+'1' WHERE userid='{$to['userid']}'");
    }

    
    
// Update pm count
    


But I need to know where to put this code, and I also need to know in what variable the USERID is stored, when approving quotes.

I'm looking at inserting the PM code here -

Find:
PHP Code:
            $DB_site->query('
                UPDATE ' 
TABLE_PREFIX 'quotes SET
                approved = 1,
                quote = "' 
$quote[$quoteid] . '",
                author = "' 
$author[$quoteid] . '"
                ' 
$contextval '
                    WHERE quoteid = ' 
intval($quoteid)
            ); 
Add under; (pm code above).

Thank you;

Jamie
Reply With Quote
  #66  
Old 04-17-2005, 02:24 AM
Cap'n Steve's Avatar
Cap'n Steve Cap'n Steve is offline
 
Join Date: Feb 2004
Location: Kalamazoo, MI, USA
Posts: 745
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I've just updated the hack with a couple small bug fixes. If you use the "Submit to Quotes" feature for posts and have context enabled, you should replace your quotes.php and admincp/quoteadmin.php files with the new copies. Also, in the style manager in your administrator control panel, edit the template quote_addquote and delete all instances of maxlength="75"

JimpsEd -
In admincp/quoteadmin.php find:
PHP Code:
            $deleted[] = intval($quoteid); 
Below that, add:
PHP Code:
         SendPM('Your quote "' $quote[$quoteid] . '" has been rejected.''Quote ' intval($quoteid) . ' rejected.'intval($user[$quoteid]), $bbuserinfo['userid']); 
In the same file, find:
PHP Code:
         print_input_row($vbphrase['author'], 'author[' $quote['quoteid'] . ']'$quote['author'], 0); 
Below that, add:
PHP Code:
         construct_hidden_code('user[' $quote['quoteid'] . ']'$quote['userid']); 
In the same file, find:
PHP Code:
    $context = &$_REQUEST['context']; 
Below that, add:
PHP Code:
   $user = &$_REQUEST['user']; 
Finally, in the same file, find:
PHP Code:
        }
        elseif (
$action == -1) { 
Above that, add:
PHP Code:
         SendPM('Your quote "' $quote[$quoteid] . '" has been approved.''Quote ' intval($quoteid) . ' approved.'intval($user[$quoteid]), $bbuserinfo['userid']); 
Note: I haven't tested this, so keep a backup of your quoteadmin.php file just in case.

EDIT: I don't know where that SendPM function came from, so in admincp/quoteadmin.php, find:
PHP Code:
require_once('./global.php'); 
and add your code below that.
Reply With Quote
  #67  
Old 04-17-2005, 04:37 AM
YLP1 YLP1 is offline
 
Join Date: Aug 2004
Posts: 417
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey Cap'n Steve... something in the revised php pages and the text above fixed my timing out issue on edit.

Go figure....LOL LOL
Reply With Quote
  #68  
Old 04-17-2005, 05:05 AM
Cap'n Steve's Avatar
Cap'n Steve Cap'n Steve is offline
 
Join Date: Feb 2004
Location: Kalamazoo, MI, USA
Posts: 745
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

That's really weird. The only thing that changed in the quote editing part was adding two more calls to str_replace(). I really think there must be something strange with the way your host has php set up.
Reply With Quote
  #69  
Old 04-17-2005, 11:03 AM
j_86 j_86 is offline
 
Join Date: May 2003
Posts: 275
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks Cap'n - all the PM stuff works
Reply With Quote
  #70  
Old 04-24-2005, 06:16 AM
YLP1 YLP1 is offline
 
Join Date: Aug 2004
Posts: 417
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Cap'n Steve
That's really weird. The only thing that changed in the quote editing part was adding two more calls to str_replace(). I really think there must be something strange with the way your host has php set up.
Wouldn't surprise me as they hosed my db and site a few days ago and then decided they would try and fix it before I found out (my site was going down at least 3 times a day and I was complaining).

Well one of the ones with brains decided to figure out why my portal page and wasn't showing so found an old index backup in my file directory and used that.

They ended up hosing my navigation on the forums, breaking this mod, the arcade and my journal mod.

Can't wait for my own server to be ready....
Reply With Quote
  #71  
Old 04-25-2005, 04:31 AM
anarchystar anarchystar is offline
 
Join Date: Dec 2004
Posts: 56
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I upgraded from 3.0.5 to 3.0.7 and also upgraded VBACMPS to 1.0.1. I upgraded to quoteit1.2 to 2.0, everything seems to have installed just fine, all my phrases and templates and in place, but when I added the module I still can't get the mod to show up on the index page .... any suggestions?
The mod is active, and selected to appear on the index page, it just does'nt???
Reply With Quote
Reply


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 11:07 AM.


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.12373 seconds
  • Memory Usage 2,361KB
  • 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
  • (14)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (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