Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)

Reply
 
Thread Tools Display Modes
  #11  
Old 03-25-2003, 11:46 AM
drives fast's Avatar
drives fast drives fast is offline
 
Join Date: Nov 2001
Posts: 263
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

okay...well...thanks for trying
Reply With Quote
  #12  
Old 03-27-2003, 05:23 PM
WetWired's Avatar
WetWired WetWired is offline
 
Join Date: Jun 2002
Location: Texas
Posts: 669
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I think the else was important. What you have at the end there is that only admins and mods get checked for long posts.
Reply With Quote
  #13  
Old 03-27-2003, 09:54 PM
drives fast's Avatar
drives fast drives fast is offline
 
Join Date: Nov 2001
Posts: 263
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

those were the suggestions I was given but I agree with you.

still hoping for a working solution.
Reply With Quote
  #14  
Old 03-27-2003, 10:26 PM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Found it. The else isn't the problem. The code I have in the text file is fine. The problem is that there is a javascript in the newreply, editpost, and newthread templates.

Remove this code from them (or something similar in each. I am only looking at newreply)

Code:
	if (postmaxchars != 0) { message = "\nThe maximum permitted length is $postmaxchars characters."; }
	else { message = ""; }
	alert("Your message is "+theform.message.value.length+" characters long."+message);
Reply With Quote
  #15  
Old 03-28-2003, 02:30 AM
drives fast's Avatar
drives fast drives fast is offline
 
Join Date: Nov 2001
Posts: 263
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

won't that disable the limit for everyone?
Reply With Quote
  #16  
Old 03-28-2003, 09:20 PM
WetWired's Avatar
WetWired WetWired is offline
 
Join Date: Jun 2002
Location: Texas
Posts: 669
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If you use this code you posted, it will still work for everyone else, but they won't be informed of their error 'till after their post hits the server.

Code:
if (strlen($message)>$postmaxchars and $postmaxchars!=0 and ($bbuserinfo[usergroupid]!=6) and ($bbuserinfo[usergroupid]!=5) and ($bbuserinfo[usergroupid]!=7)) {
eval("standarderror(\"".gettemplate("error_toolong")."\");");
}
Reply With Quote
  #17  
Old 03-28-2003, 10:00 PM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If you really wanted you could create a separte newreply, newthread, editpost template for admins and mods that have the limit removed and then leave the javascript in for everybody else.

However, as the check is done on the server, it's really a matter of personal choice. I don't have a problem with users posting long posts; so this isn't an issue for me. You know where the code is and you know what your options are - you'll just have to decide what is best for you.

Amy
Reply With Quote
  #18  
Old 03-29-2003, 12:02 AM
drives fast's Avatar
drives fast drives fast is offline
 
Join Date: Nov 2001
Posts: 263
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

WetWired,

that code has alreay been tried and it limits the usergroups that are listed in it to the character limit instead of exempting them
Reply With Quote
  #19  
Old 03-29-2003, 12:16 AM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

No, it doesn't Drives Fast. They are exampted with that code on the server side. The reason it wasn't working was because the javascript was throwing the error before it ever got to the server.

You can't just throw any old code at your board and expect results. You need to start to understand how things work if you want to change the base functionality.

Amy
Reply With Quote
  #20  
Old 03-29-2003, 01:07 AM
drives fast's Avatar
drives fast drives fast is offline
 
Join Date: Nov 2001
Posts: 263
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I am sorry but there is no such java script in my newthread nor newreply so the code mentioned does in fact prevent admins and mods from bypassing the limit. I looked for all of those words together and individually and did not find anything that looked anything like what you posted as the solution.

perhaps you are looking at a different version of vbulletin than I have

If I understood how vbulletin worked I wouldn't be asking for help on this.

If you no longer wish to help...then don't....but please do not insult me for no reason. The fact that I am asking for help is evidence enough that I do not know how to do this myself.

thank you anyway.....I give up
Reply With Quote
Reply

Thread Tools
Display Modes

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 06:07 PM.


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.08850 seconds
  • Memory Usage 2,263KB
  • Queries Executed 12 (?)
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)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (2)bbcode_code
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)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
  • (10)postbit
  • (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
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete