MyBB Community Forums

Full Version: Hanging at "Loading. Please wait"
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5
Edits to functions.php would be for Google SEO and I haven't seen anything mentioning xmlhttp.php yet...

I added nothing to the fresh template set. That looks like my image resizer plugin and the Google Analytics plugin?
Replace your ./jscripts/thread.js file with this:
[attachment=20684]

I've added some logging in to see exactly where it stops running.
thanks
uploaded
Interesting. I've updated the above attachment, can you try this new one??
re-uploaded - thanks matt.
OK, you can replace it with the original script now.

I think I've finally figured this out, and it appears to be the most ridiculous thing ever.

This is part of the javascript in thread.js for when it gets the result of the AJAX request:

else if(request.responseText.match(/id="post_([0-9]+)"/))
{
	var pid = request.responseText.match(/id="post_([0-9]+)"/)[1];
	var post = document.createElement("div");
	post.innerHTML = request.responseText;
	$('posts').appendChild(post);
	if(MyBB.browser == "ie" || MyBB.browser == "opera" || MyBB.browser == "safari" || MyBB.browser == "chrome")
	{
		var scripts = request.responseText.extractScripts();
		scripts.each(function(script)
		{
			eval(script);
		});
	}
	Form.reset('quick_reply_form');
	if($('lastpid'))
	{
		$('lastpid').value = pid;
	}
}
else
{
	request.responseText.evalScripts();
}

If it gets a post back, it'll do all the stuff to show the post, if it doesn't get a post, it runs the last bit at the end. When I added the debug stuff, I could see that it was going into that last bit, and getting no further (in the code after what's here), which was weird; it seemed to be getting stuck there, but I couldn't work out why it was going here at all. Then I had a closer look at your source code. Look at this javascript:

request.responseText.match(/id="post_([0-9]+)"/)

it's matching:

id="post_([0-9]+)"

i.e. post_ and then a number; the number of the post. However, on your forum, it has this:

id=post_188679

This has no ", so quite simply, it didn't match the pattern for the javascript above to register it as a post, because the " were missing.

I'm not sure why it's like this in your forum or if it's intentional, but either way, in the postbit and postbit_classic template, on one of the first few lines, it should have this right at the end of the long opening <table> tag:

id="post_{$post['pid']}"

however yours will probably just be this:

id=post_{$post['pid']}

Add the " " around it again, and it should work.
No dice... That section of the code in the postbit and postbit classic templates looks like this already: id="post_{$post['pid']}"
Really?? This is line 238 of the page source of the thread about this issue on your forum:

<table border=0 cellspacing=1 cellpadding=4 class=tborder style="border-top-width: 0; " id=post_192845>

But in the templates in the ACP it has the " " around it?? What's even weirder is that one attribute does have them.

Pretty much all the attributes in your source have no " " around them, look at this:

<form method=post action="newreply.php?tid=21189&amp;processed=1" name=quick_reply_form id=quick_reply_form> 
<input type=hidden name=my_post_key value=post_key_here /> 
<input type=hidden name=subject value="RE: Loading, please wait..."/> 
<input type=hidden name=action value=do_newreply /> 
<input type=hidden name=posthash value=post_hash_here id=posthash /> 
<input type=hidden name=quoted_ids value="" id=quoted_ids /> 
<input type=hidden name=lastpid id=lastpid value=192876 /> 
<input type=hidden name=from_page value=5 /> 
<input type=hidden name=tid value=21189 /> 
<input type=hidden name=method value=quickreply />

I haven't got a clue what could be stripping the " " out from the templates...
I know this sounds really stupid, but I have a similar problem with the image hanging on one of my themes - but only on Opera - not on firefox, and not on the default theme with Opera. Could this be a theme related issue?
It'd be better if you created a separate thread if you have a similar issue.
Pages: 1 2 3 4 5