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)
-   -   Advance Sticky Options (https://vborg.vbsupport.ru/showthread.php?t=103642)

SmEdD 12-23-2005 10:00 PM

Advance Sticky Options
 
What this Hack Does
This hack will allow you to set a Display Order for Sticky Posts (ignore any sortorder) and set an Expiry Date to unstick your posts.

Hack Info
Templates to Edit: 1 (manual)
Files to Upload: 1 (auto)
DB Changes: 3 (auto)
Plugins Added: 7 (auto)

Instructions
1) Download the attached file.
2) Upload the file in the "upload" folder.
3) Import the plugin.
4) Find and Replace in template threadadmin_editthread
HTML Code:

                $posticons
With:
HTML Code:

                <fieldset class="fieldset">
                        <legend>$vbphrase[sticky_options]</legend>
                        <div style="padding:$stylevar[formspacer]px">
                                <div>
                                        $vbphrase[sticky_order]<br />
                                        <input type="text" class="bginput" name="sticky_order" value="$threadinfo[sticky_order]" size="5" maxlength="3" />
                                        $vbphrase[sticky_order_desc]
                                </div>
                                <div>
                                        $vbphrase[sticky_expiry]<br />
                                        <table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
                                          <tr>
                                                <td>
                                                        <span class="smallfont">$vbphrase[month]<br />
                                                        <select name="sticky_expiry[month]" tabindex="1">
                                                                <option value="-1" $monthselected[default]></option>
                                                                <option value="1" $monthselected[1]>$vbphrase[january]</option>
                                                                <option value="2" $monthselected[2]>$vbphrase[february]</option>
                                                                <option value="3" $monthselected[3]>$vbphrase[march]</option>
                                                                <option value="4" $monthselected[4]>$vbphrase[april]</option>
                                                                <option value="5" $monthselected[5]>$vbphrase[may]</option>
                                                                <option value="6" $monthselected[6]>$vbphrase[june]</option>
                                                                <option value="7" $monthselected[7]>$vbphrase[july]</option>
                                                                <option value="8" $monthselected[8]>$vbphrase[august]</option>
                                                                <option value="9" $monthselected[9]>$vbphrase[september]</option>
                                                                <option value="10" $monthselected[10]>$vbphrase[october]</option>
                                                                <option value="11" $monthselected[11]>$vbphrase[november]</option>
                                                                <option value="12" $monthselected[12]>$vbphrase[december]</option>
                                                        </select>
                                                        </span>
                                                </td>
                                                <td>
                                                        <span class="smallfont">$vbphrase[day]<br />
                                                        <input type="text" tabindex="1" class="bginput" name="sticky_expiry[day]" value="$sticky_expiry[day]" size="4" maxlength="2" />
                                                        </span>
                                                        </td>
                                                <td>
                                                        <span class="smallfont">$vbphrase[year]<br />
                                                        <input type="text" tabindex="1" class="bginput" name="sticky_expiry[year]" value="$sticky_expiry[year]" size="4" maxlength="4" />
                                                        </span>
                                                </td>
                                          </tr>
                                        </table>
                                </div>

                        </div>
                </fieldset>
               
                $posticons

Change Log
Version 1.0.3
- Fixed some broken uninstall code.

Version 1.0.2
- Changed the default value of sticky order from 0 to 5. This was done so you may have stickies like ?Sig Testing? that are always below new stickies.

Version 1.0.1
- Fixed Select Field size.
- Removed '' from numeric values to lessen load and speed up the script.
- Removed excess spacing just to clean up the code.
- Changed != to <> in the MySQL Query to prevent problems.

WNxWakko 12-24-2005 02:49 AM

Very interesting. Ill Install it.

divided_by_fear 12-24-2005 03:01 AM

going to try it out thanks

wolfstream 12-24-2005 07:36 AM

Nice job!

FleaBag 12-24-2005 11:50 AM

This should be default in vB! Great work, thanks a lot! :)

nexialys 12-24-2005 11:56 AM

what would be cool on the design sight is to have that new block of functions displayed only when you click to stick the thread.. ;) -- ok, i'm paranoid!

SmEdD 12-24-2005 04:16 PM

Quote:

Originally Posted by nexialys
what would be cool on the design sight is to have that new block of functions displayed only when you click to stick the thread.. ;) -- ok, i'm paranoid!

The problem is there area about 4 different spots to sticky posts. There is only one spot that you could do it reasonably. The rest get a bit more complicated especially the inline mod sticky as you can stick mass amounts of threads.

I will look into it though for a future version.

akanevsky 12-24-2005 04:26 PM

Very nice. Could use a bit of work, but on the bottom line this hack is great :)

uae 12-24-2005 05:40 PM

Awesome Work :)

SmEdD 12-24-2005 06:48 PM

Quote:

Originally Posted by Psionic Vision
Very nice. Could use a bit of work, but on the bottom line this hack is great :)

Letme know what needs changed and I can fix em up :)


All times are GMT. The time now is 10:39 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.01196 seconds
  • Memory Usage 1,762KB
  • 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_html_printable
  • (2)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