PDA

View Full Version : Broswer Problem with this site???



Tom Gonser
- 9th October 2005, 02:49
Anyone else not able to use the 'Search' pull down list in PBP Pro forum? I cannot get it to work in IE or in Firefox, and hence can't search for things... Is it just me?

Tom

Luciano
- 9th October 2005, 06:43
Hi,

No problem with IE6.0.

Try the URL:
http://www.picbasic.co.uk/forum/search.php?

Luciano

Mike_Lynch
- 9th October 2005, 15:36
Interesting now that you mention it, I notice that sometimes the search window comes up,
sometimes not. For example, it works when my browser is reading the main forum page at
http://www.picbasic.co.uk/forum/index.php? but if I click the link for the “General” subforum
(http://www.picbasic.co.uk/forum/forumdisplay.php?f=7 )
it stops working, however upon selecting a particular thread such as THIS ONE
( http://www.picbasic.co.uk/forum/showthread.php?t=2534 ), the search function starts
working again. Strange behavior. IE 6 Version 6.0.2800.1106 on Win 2K Pro Version 5.0
Build 2195 Service Pack 4. I guess it is yet another Micro$$ “ FEATURE “ ???

ML

keithdoxey
- 9th October 2005, 15:43
Interesting now that you mention it, I notice that sometimes the search window comes up,
sometimes not.

SNIP

but if I click the link for the “General” subforum
(http://www.picbasic.co.uk/forum/forumdisplay.php?f=7 )
it stops working

ML
If you have the status bar enabled on your browser you will see it report a Javascript error.

ANY javascript error on a page will stop ALL javascript on that page form working

Regards

Tom Gonser
- 9th October 2005, 15:47
Yes. I have the exact same issue - on a high level page I can search. On the page for PBP Pro I cannot.

On THESE pages:(example - there are others)
http://www.picbasic.co.uk/forum/forumdisplay.php?f=4
http://www.picbasic.co.uk/forum/forumdisplay.php?f=3

I get no pop-up search boxes on 'Search' or 'Quick links' or 'Forum Tools' or 'search this forum'..

However, on THESE pages : (Example)
http://www.picbasic.co.uk/forum/forumdisplay.php?f=13
http://www.picbasic.co.uk/forum/index.php?
http://www.picbasic.co.uk/forum/forumdisplay.php?f=11

- The pop-ups work fine..

I think the web site has some bad code somewhere.

Tom

keithdoxey
- 9th October 2005, 16:00
I think the web site has some bad code somewhere.

Tom

Hi Tom,

Its probably down to the content of one of the messages and the fact that whoever wrote the Javascript functions forgot to escape a certain character in one of the functions, most likely an apostrophe or backslash.

Can be very difficult to track down but as the error occurs as soon as the page is loaded rather than when mousing over something or clicking a link, my guess is that it is caused by the call "vBulletin_init();" at the bottom of the page.

Not sure what this function does as it isnt visible in the page. It is probably in one of the following included files

clientscript/vbulletin_global.js
clientscript/vbulletin_menu.js

The fact that you report the error happening and NOT happening in the same page "forumdisplay.php" would tend to confirm that it is related to a thread in a forum. EG forums 3 & 4 break it but 11 and 13 dont.

I would just like to wish Lester the best of luck in tracking this one down!

Regards

Keith

keithdoxey
- 9th October 2005, 20:25
my guess is that it is caused by the call "vBulletin_init();" at the bottom of the page.

Not sure what this function does as it isnt visible in the page. It is probably in one of the following included files

clientscript/vbulletin_global.js
clientscript/vbulletin_menu.js

I would just like to wish Lester the best of luck in tracking this one down!



OK. Been looking a bit deeper into this and have discovered why some of the forums are broken and others are OK. Its to do with the number of threads.

I have found the location of "vBulletin_init();"

It is in the vbulletin_global.js file and the error message points to line 1520 which is in the middle of "vBulletin_init"

This is the section causing the problem.....

[1516] // process the pagenavs popup form
[1517] if (typeof addr != 'undefined')
[1518] {
[1519] fetch_object('pagenav_form').addr = addr;
[1520] fetch_object('pagenav_form').gotopage = vBpagenav.prototype.form_gotopage;
[1521] fetch_object('pagenav_ibtn').onclick = vBpagenav.prototype.ibtn_onclick;
[1522] fetch_object('pagenav_itxt').onkeypress = vBpagenav.prototype.itxt_onkeypress;
[1523] }


.... line 1520 actually starts with three "TABS" so the "f" of fetch_object is char 4 which is where it says the error is but as the error reported is....

"null" is null or not an object

....it probably refers to the line 1519 with "addr" not being correctly set.

"addr" is initially defined at line 1503 as follows....

var addr = pagenavs[n].title;

... in the section that is titled "add popups to pagenav elements"

The forums that work OK are the ones with only a single page of topics. The forums with more than one page are the ones that bring up the error.

Multipage forums show an additional nav bar "page 1 of n" top and bottom of the main window. This gets drawn OK but the dropdown arrow doesnt appear to do anything which I think is also related to this same problem.

Dont ask me any more about fixing it cause I didnt write it... just reverse engineering it :-)

Strange way to write it though doing a chunk of page creation client side. I would have made PHP do the dirty work server side rather than leave it to the mercy of a browser to handle!

Regards