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

Reply
 
Thread Tools
Details »»

Version: , by bira bira is offline
Developer Last Online: Jun 2013 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 12-08-2001 Last Update: Never Installs: 141
 
No support by the author.

Hi all,

This is a brand new addition to my own BB, so I don't even know how my own users will react to it, let alone how you guys would

Hack Description:
  • Posts you have already read in a thread, will show up with their header only (a row that includes the username, post subject and date only). New posts only will appear in full.
  • This is user selectable via the 'Edit Options' page: each user can decide if he wants this option on or not. (By default all existing and new users will have this turned Off).
  • A link at the top of the thread offers to "expand all" posts or "contact all" posts.
  • by clicking on the + sign on a shruk post, it will expand without the page reloading. By clicking on the - sign on an expanded post, it will shrink without the page reloading.
  • [high]this option is available for your IE users only! Netscape users will see no difference and will not be affected anyway at all by the change[/high]
How to install:
  • Please download the attached zipfile.
  • Upload plus.gif and minus.gif to your images directory
  • Upload install_contractposts.php to your admin directory and run that script.
Note: there are quite a few changes to make (primarily additions, not replacements) to the vb scripts and templates. The process should take you several minutes, so I recommend you close your Bulletin Board while installing the hack.

Demo:

You are welcome to visit my Bulletin Board, at http://www.atlasf1.com , to see what the additions look like. To test it in full (ie, the option of old posts being shrunk by default), you will have to register and modify your options after you have received your password.

Cheers,

Bira

Show Your Support

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

Comments
  #282  
Old 09-04-2002, 06:45 AM
Sho Sho is offline
 
Join Date: Nov 2001
Location: Berlin, Germany
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I found this and it works with MoZilla (and, therefore, with Netscape 6/7). Could anyone combine this technique with bira's hack, so we get a version working with IE *and* Netscape?
Reply With Quote
  #283  
Old 09-04-2002, 06:56 AM
cybrcyfr cybrcyfr is offline
 
Join Date: Aug 2002
Posts: 16
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yeah, using the getElementByID() works in Netscape 6, but not 4.

I was planning on getting around to modifying the hack to do it all client side and work in IE, Netscape and Opera. on my todo list.

Check this site out, good stuff [http]http://www.xs4all.nl/~ppk/js/index.html?/~ppk/js/intro.html[/http]
Reply With Quote
  #284  
Old 09-04-2002, 07:01 AM
Sho Sho is offline
 
Join Date: Nov 2001
Location: Berlin, Germany
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hm, looks like an interesting read. Thanks!

[high]* Sho is back in "learning by doing" mode ...[/high]
Reply With Quote
  #285  
Old 09-04-2002, 08:55 AM
Sho Sho is offline
 
Join Date: Nov 2001
Location: Berlin, Germany
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well, with the information on the page you recommended, cybrcyfr, I did the following:

Code:
<SCRIPT LANGUAGE="JavaScript" TYPE="text/javascript">
<!--

var supported = (document.getElementById || document.all);

if (supported)
{
	document.write("<STYLE TYPE='text/css'>");
	document.write(".postbit_regular {display: block}");
	document.write(".postbit_hidden {display: none}");
	document.write("</STYLE>");

	var max = 7;
	var data_regular = new Array();
	for (var i=1;i<=max;i++)
	{
		data_regular[i+1] = false;
	}
	
	var max = 7;
	var data_hidden = new Array();
	for (var i=1;i<=max;i++)
	{
		data_hidden[i+1] = false;
	}	

}

function contract(i)
{
	if (!supported)
	{
		alert('This link does not work in your browser.');
		return;
	}
	data_regular[i] = (data_regular[i]) ? false : true;
	current = (data_regular[i]) ? 'none' : 'block';
	if (document.getElementById)
	{
		document.getElementById('postbit_regular'+i).style.display = current;	
	}
	else if (document.all)
	{
		document.all['postbit_regular'+i].style.display = current;
	}
}

function expand(i)
{
	if (!supported)
	{
		alert('This link does not work in your browser.');
		return;
	}
	data_hidden[i] = (data_hidden[i]) ? false : true;
	current = (data_hidden[i]) ? 'block' : 'none';
	if (document.getElementById)
	{
		document.getElementById('postbit_hidden'+i).style.display = current;	
	}
	else if (document.all)
	{
		document.all['postbit_hidden'+i].style.display = current;
	}
}

// -->
</SCRIPT>
... and two <divs> in the "postbit" template as containers, using those CSS classes and IDs. This expands/contracts in both browsers. Note that I have never used JavaScript before, so this might be a piece of s***.
Reply With Quote
  #286  
Old 09-04-2002, 10:36 PM
dabean dabean is offline
 
Join Date: Oct 2001
Posts: 247
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

[QUOTE]Originally posted by Sho
Well, with the information on the page you recommended, cybrcyfr, I did the following:

*snipped interesting javascript*

... and two <divs> in the "postbit" template as containers, using those CSS classes and IDs. This expands/contracts in both browsers. Note that I have never used JavaScript before, so this might be a piece of s***.
Reply With Quote
  #287  
Old 09-05-2002, 04:22 AM
NeoGT NeoGT is offline
 
Join Date: Jan 2002
Posts: 7
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Installed the hack, but none of the post quotes (except from the first post) appear on the contracted view. Plus there are these weird squares which have appeared to the left of everyone's name.

Okay I see what those are for now, they're just blank and they don't do anything.
Reply With Quote
  #288  
Old 09-05-2002, 05:05 AM
Sho Sho is offline
 
Join Date: Nov 2001
Location: Berlin, Germany
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Too late!

Just finished rewriting bira's hack to fit my needs: completely client-side, working with IE, MoZilla & Netscape 6/7 (=>Gecko). Thanks again to cybrcyfr for linking to his interesting website!

Looking forward to Opera 7 and its improved DOM support, btw.
Reply With Quote
  #289  
Old 09-05-2002, 07:38 PM
NeoGT NeoGT is offline
 
Join Date: Jan 2002
Posts: 7
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Can anyone help? What's happening is that it only displays the post subjects while in contracted form instead of the first line of the post, like it does at this site. If there is no subject then all I get is a blank line for that post.
Reply With Quote
  #290  
Old 09-19-2002, 07:31 PM
havefun's Avatar
havefun havefun is offline
 
Join Date: Jan 2002
Location: Spain & Austria
Posts: 83
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

really cool hack!

like it & had no probs.. :banana:

lg, havefun
Reply With Quote
  #291  
Old 09-21-2002, 07:05 PM
havefun's Avatar
havefun havefun is offline
 
Join Date: Jan 2002
Location: Spain & Austria
Posts: 83
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

when you have chosen in the user CP 'yes' by contract posts:

you enter a link to a special post# th. you will not go to the right position in browser window or only find conracted posts ...

[you only have the prob when you allready have read the post|s.]


do you have any idea?
--> after following a post link to find it opened ...

thx 4 your time!
haveFUN
[i love this hack!]
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 05:51 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.04926 seconds
  • Memory Usage 2,309KB
  • 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
  • (1)bbcode_code
  • (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