vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   [vbhacker] Mozilla Text Area Fix (https://vborg.vbsupport.ru/showthread.php?t=39428)

Erwin 04-05-2003 11:44 PM

Okay, I've made the instructions very clear in case people were replacing only the commented out line (but surely not) - find that code and REPLACE the WHOLE SECTION.

It should work.

Boofo 04-06-2003 01:29 AM

It won't work. You got way too many brackets with the eregi stuff now.

Erwin 04-06-2003 01:35 AM

Uh... count the brackets carefully. :) It does work. Because it's the same code running on my forums for the past 6 months.

Boofo 04-06-2003 01:39 AM

Then you muist have a magic site. ;)

One on the left and 2 on the right and it still works?

("Netscape6/",$HTTP_USER_AGENT))

Erwin 04-06-2003 02:24 AM

Boofo... look at that line of code carefully. COUNT the number of brackets.

Don't confuse the OR bits with the AND bits... :) The Netscape is joined with the Mozilla variables...

If you can't count, I can't help you.

P.S - vB.org is definitely not magical, but it has this code installed... ;)

Erwin 04-06-2003 02:27 AM

Let me break it down for you, since you obviously can't count, yet insist on trying to be smart.

if (eregi("MSIE",$HTTP_USER_AGENT)

this first part - opens a new bracket, the IE one is open and closed, 1 bracket still needs to be closed...

|| (eregi("Mozilla/5",$HTTP_USER_AGENT) &&

Opens another bracket, the Mozilla is open and closed, so we have 2 brackets to be closed now.

!eregi("Netscape6/",$HTTP_USER_AGENT))) {

The Netscape variables are open and closed, so then we close the 2 brackets.

See?

Next time, count, before trying to criticize code released by others.

Boofo 04-06-2003 02:39 AM

Erwin, I was counting before you were even born. ;)

This is the line I was referring to.

PHP Code:

} elseif ("Netscape6/",$HTTP_USER_AGENT)) { // browser is NS 6
        
return "40"

And I have looked over at vb.com for this fix and I didn't see it anywhere.

Edit: You're not even using eregi in your new code, by the way.

attroll 04-06-2003 03:19 AM

Yes you must have a magic site because I have done this three time and still get the same error even after you changed your directions. Are you sure you did not change something somewhere else maybe? I don't think I am that bad I have installed mods before.

Boofo 04-06-2003 03:29 AM

attroll, try this. I'm not very good at counting so it may not work. ;) Let me know.

[disable]// ###################### Start gettextareawidth #######################
function gettextareawidth() {
// attempts to fix idiotic Nutscrape textarea width problems
global $HTTP_USER_AGENT;

if ((eregi("MSIE",$HTTP_USER_AGENT) || (eregi("Mozilla/5",$HTTP_USER_AGENT) && !(eregi("Netscape6/",$HTTP_USER_AGENT))))) { // browser is IE
return "{textareacols_IE}";

} elseif (eregi("Netscape6/",$HTTP_USER_AGENT)) { // browser is NS 6
return "{textareacols_NS6}";

} elseif (eregi("Mozilla/4.",$HTTP_USER_AGENT)) { // browser is NS4
return "{textareacols_NS4}";

} else { // unknown browser - stick in a sensible value
return 60;

}

}[/disable]

attroll 04-06-2003 03:48 AM

Yup that did it with yours Boofo. I don't know if it actiually works with Mozilla though. I will have to wait until one of my users comes online to find out. But at least I am not getting any errors now.

THanks Boofo


All times are GMT. The time now is 09:10 AM.

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.01088 seconds
  • Memory Usage 1,736KB
  • 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
  • (1)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)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