Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > General > Member Archives
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Details »»

Version: , by Lionel Lionel is offline
Developer Last Online: Nov 2023 Show Printable Version Email this Page

Version: Unknown Rating:
Released: 01-10-2002 Last Update: Never Installs: 0
 
No support by the author.

Well, I do not pretend this to be a hack, nor do I know if someone else has done it. I found it somewhere and thought that it could be useful to some.

In newthread template find:

<textarea name="message" rows="20" cols="$textareacols" wrap="virtual" tabindex="2">$message</textarea>

and replace with:

<textarea name="message" rows="20" cols="$textareacols" wrap="virtual" tabindex="2" onkeypress="compter(this.form)">$message</textarea><input type="text" name="nbcar" size=3>

then Set the var max= to your config in the script below and place the javascript anywhere between <body> and </body>

<SCRIPT LANGUAGE="JavaScript">
var max=2000;
function compter(f) {
var txt=f.message.value;
var nb=txt.length;
if (nb>=0) {
nb=nb+1;
}
if (nb>max) {
alert("Can't have more than "+max+" characters in your post");
f.message.value=txt.substring(0,max);
nb=max;
}
f.nbcar.value=nb;
}

function timer() {
compter(document.forms["form1"]);
setTimeout("timer()",100);
}

</SCRIPT>

Use it for the other templates too.

Show Your Support

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

Comments
  #2  
Old 01-10-2002, 06:22 AM
Lionel Lionel is offline
 
Join Date: Dec 2001
Location: Delray Beach, Florida
Posts: 3,277
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

here is what it looks like
Attached Files
File Type: (21.4 KB, 176 views)
Reply With Quote
  #3  
Old 01-10-2002, 06:51 AM
Lionel Lionel is offline
 
Join Date: Dec 2001
Location: Delray Beach, Florida
Posts: 3,277
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

After I posted, I found this which I think is much nicer.
Reply With Quote
  #4  
Old 01-10-2002, 03:41 PM
Nam's Avatar
Nam Nam is offline
 
Join Date: Oct 2001
Location: NY
Posts: 206
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Don't worry, I like your style better, thanks .
Reply With Quote
  #5  
Old 01-10-2002, 11:29 PM
Shenlong's Avatar
Shenlong Shenlong is offline
 
Join Date: Nov 2001
Location: Manhattan, New York
Posts: 167
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I agree, your style is much better and easier to configure, thanks so mcuh for this hack! A+! Make some more!
Reply With Quote
  #6  
Old 01-10-2002, 11:30 PM
Shenlong's Avatar
Shenlong Shenlong is offline
 
Join Date: Nov 2001
Location: Manhattan, New York
Posts: 167
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

By the way, heres a message from a user:

Quote:
Teleblaze,
Thanks for installing that message hack, sometimes I was posting a long tutorial and didn't know when my characters would run out, now I know perfectly and such an easy location to see! Whoever made this, thank them!

Sincerely,
XX_Reaper_XX
^Look, a happy user^

Thanks again!
Reply With Quote
  #7  
Old 01-10-2002, 11:43 PM
Shenlong's Avatar
Shenlong Shenlong is offline
 
Join Date: Nov 2001
Location: Manhattan, New York
Posts: 167
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey, how do I make the box appear, the script is easy for the visitors to see but the box would be nicer, how do I add that, the only thing it says is:

[check character length]
Reply With Quote
  #8  
Old 01-11-2002, 01:59 AM
Lionel Lionel is offline
 
Join Date: Dec 2001
Location: Delray Beach, Florida
Posts: 3,277
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

All there is to it is to adjust your html accordingly. For example if you want to make the input bigger just say so in the input size.

BTW, I unistalled and placed a modified html hack of the other one. It looks nicer and I will encourage people to use it.
Reply With Quote
  #9  
Old 01-11-2002, 06:58 AM
Jawelin Jawelin is offline
 
Join Date: Nov 2001
Posts: 557
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

As I can see, the other's hack is still under revisioning...
Meanwhile, I installed yours !
Thanks a lot.
Reply With Quote
  #10  
Old 01-11-2002, 09:42 AM
bokhalifa bokhalifa is offline
 
Join Date: Oct 2001
Location: U A E Dubai
Posts: 127
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nice job
Works great
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 10:56 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.04353 seconds
  • Memory Usage 2,311KB
  • Queries Executed 24 (?)
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_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
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (1)postbit_attachment
  • (10)postbit_onlinestatus
  • (10)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
  • postbit_attachment
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete