Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases

Reply
 
Thread Tools
Display threads creation date Details »»
Display threads creation date
Version: 1.00, by VBDev VBDev is offline
Developer Last Online: Dec 2021 Show Printable Version Email this Page

Version: 3.0.0 Rating:
Released: 04-24-2004 Last Update: Never Installs: 19
 
No support by the author.

Display thread's creation date

Total hack's description : http://www.vbulletindev.net/forums/h...hack&hackid=69



Please click if you like this hack


I've created this hack, and I saw then that it was already done here, but with my hack, you can display the date from the searcH.php and it adds a new column :nervous:

With this small hack, you'll add the thread's creation date in the forumdisplay (and search results)

Show Your Support

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

Comments
  #12  
Old 06-01-2004, 09:09 PM
Isotope Isotope is offline
 
Join Date: Mar 2004
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi! Quick question...


I want to have the Creation Date column come AFTER the "Last Post" column, not before.

How do I do this?
Reply With Quote
  #13  
Old 06-01-2004, 09:40 PM
Isotope Isotope is offline
 
Join Date: Mar 2004
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Isotope
Hi! Quick question...


I want to have the Creation Date column come AFTER the "Last Post" column, not before.

How do I do this?
I just wrestled this, and figured it out.


But now, I have one other question - the "Date of Creation" column that's added is the only column you can't sort by. What do I have to change in order to make this column sortable?
Reply With Quote
  #14  
Old 06-19-2004, 09:18 AM
lazytown lazytown is offline
 
Join Date: Feb 2004
Posts: 503
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How about adding this to the "Similar Threads" feature? Also, does this work with 3.01?
Reply With Quote
  #15  
Old 07-03-2004, 11:51 PM
dniMTheory dniMTheory is offline
 
Join Date: Apr 2003
Posts: 30
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Would be great if you can sort from oldest to newest or newest to oldest
Reply With Quote
  #16  
Old 07-04-2004, 12:59 AM
Andreas's Avatar
Andreas Andreas is offline
 
Join Date: Jan 2004
Location: Germany
Posts: 6,863
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nice one, although I wrote that myself about half a year ago (with ability to sort by thread creation date)

Adding sorting should be fairly straightforward:

In Template FORUMDISPLAY

REPLACE

Code:
<td class="thead" align="center" nowrap="nowrap"><span style="white-space:nowrap">$vbphrase[date_creation]</a></span></td>
WITH
Code:
<td class="thead" align="center" nowrap="nowrap"><span style="white-space:nowrap"><a href="$sorturl&amp;order=asc&amp;sort=threadstarted">$vbphrase[date_creation]</a> $sortarrow[threadstarted]</span></td>

In forumdisplay.php FIND
PHP Code:
case 'postusername':
        
$sqlsortfield $sortfield;
        break; 
BELOW that ADD
PHP Code:
case 'threadstarted':
        
$sqlsortfield 'thread.dateline';
        break; 
That's it (at least if I remeber correctly).
Reply With Quote
  #17  
Old 07-05-2004, 08:23 PM
Ocean's Avatar
Ocean Ocean is offline
 
Join Date: Mar 2004
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

vBDev, with vBulletin 3.0.3, some of the code has changed - especially in the ThreadBit Template.


Is there any chance you can update this hack for vB 3.0.3?


Thanks!
Reply With Quote
  #18  
Old 07-06-2004, 06:15 PM
dookie dookie is offline
 
Join Date: Jun 2003
Location: Germany
Posts: 57
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Works fine @ 3.0.3

What changes in threadbit do you mean?
There are no changes in threadbit. :surprised:
Reply With Quote
  #19  
Old 07-06-2004, 07:20 PM
Ocean's Avatar
Ocean Ocean is offline
 
Join Date: Mar 2004
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by dookie

Works fine @ 3.0.3

What changes in threadbit do you mean?
There are no changes in threadbit. :surprised:
http://www.vbulletin.com/forum/showp...14&postcount=2



The threadbit has changed with 3.0.2. In order to make sure that there are no conflicts/problems, I was hoping that the hack code could be brought up to date.
Reply With Quote
  #20  
Old 07-14-2004, 09:52 PM
Ocean's Avatar
Ocean Ocean is offline
 
Join Date: Mar 2004
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

There are a number of issues that need to be dealt with, for this hack.


1. The "Threadbit" template has changed between 3.0.0 and 3.0.3, but VBDev has not yet updated his code to reflect that.

2. This hack does not support the Subscribed Threads section in your UserCP.

3. This hack causes problems with the Subscribed Threads section of the UserCP. An additional empty column is created, where the Thread Creation Date should have been - if it were supported - but that throws off the synchronization between column headers and data.


Since VBDev no longer seems to be responding to this Thread, nor is he responding on his home forum, I've updated this hack to correct the issues listed above, and to add support for Thread Subscriptions - if anyone is interested.


I've listed it as a Revised Version 1.2. Use it if you like.

If you want to use it, however, and you've already installed the original 1.0 version - I suggest that you replace the end section of the "Threadbit" template with the Default code before applying that portion of my revision.

I made my instructions so that they interfered as little as possible with the original code. Personally, I dislike hacks that say "find this entire huge section, and *replace* it with this one", when they could have just specified the few lines that needed to be changed.


If you guys use this revised version, let me know if it works well for you.


Version 1.3 Update

I took KirbyDE's code suggestions and integrated/modified them. Now, you can sort by Creation Date in both ForumDisplay, as well as Subscribed Threads.


Version 1.31 Update

I added the Sort by Creation Date option to the ForumDisplay "Display Options" menu.



Upgrade Instructions:


Upgrade from v1.2 to 1.3:


1. Open the ForumDisplay Template and Find:


Code:
 
 
<td class="thead" align="center" nowrap="nowrap"><span style="white-space:nowrap">$vbphrase[date_creation]</a></span></td>

2. Replace the above code with:


Code:
 
 
<td class="thead" align="center" nowrap="nowrap"><span style="white-space:nowrap"><a href="$sorturl&amp;order=asc&amp;sort=threadstarted">$vbphrase[date_creation]</a> $sortarrow[threadstarted]</span></td>

3. Repeat steps 1 and 2 for the SUBSCRIBE Template.


4. Open the ForumDisplay.php file and Find:


Code:
 
case 'postusername':
$sqlsortfield = $sortfield;
break;

5. Below, Add:


Code:
 
 
case 'threadstarted': 
$sqlsortfield = 'thread.dateline'; 
break;

6. Repeat steps 4 and 5 for Subscription.php



Upgrade from v1.3 to 1.31:


In the ForumDisplay Template, Find:


Code:
 
 
<option value="lastpost" $sort[lastpost]>$vbphrase[last_post_time]</option>

Below, Add:


Code:
 
 
<option value="threadstarted" $sort[threadstarted]>$vbphrase[date_creation]</option>

And you're done!
Reply With Quote
  #21  
Old 07-19-2004, 03:06 PM
snake-boy snake-boy is offline
 
Join Date: Jul 2004
Location: Bangkok
Posts: 102
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi,

Everything looking good, I hit a snag right at the start:

Quote:
<td class="thead" width="150" align="center" nowrap="nowrap"><span style="white-space:nowrap"><a href="$sorturl&amp;order=desc&amp;sort=lastpost">$ vbphrase[last_post]</a> $sortarrow[lastpost]</span></td>
This line does not exist in my forumdisplay.php? (V3.0.3) Am I just crazy?

-snake
Reply With Quote
Reply

Thread Tools

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 04:35 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.14782 seconds
  • Memory Usage 2,312KB
  • 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
  • (8)bbcode_code
  • (2)bbcode_php
  • (3)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
  • (3)pagenav_pagelink
  • (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