Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+1 vote
592 views
in Q2A Core by

The install went alright, but after posting a sample question, I get nothing but a blank page when I click on it.

When I view the source of the blank page, the output is:

<HTML>
	<HEAD>
		<META HTTP-EQUIV="Content-type" CONTENT="text/html; charset=utf-8">
		<STYLE type="text/css">
			body,input {font-size:16px; font-family:Verdana, Arial, Helvetica, sans-serif;}
			body {text-align:center; width:640px; margin:64px auto;}
			table {margin: 16px auto;}
		</STYLE>
	</HEAD>
	<BODY>

This repeats about 10 times.

There are errors in my apache log as well:

[Sun Nov 11 13:45:02 2012] [error] [client 127.0.0.1] PHP Question2Answer MySQL query error 1153: Got a packet bigger than 'max_allowed_packet' bytes - Query: (SELECT '0' AS selectkey, posts.postid, posts.categoryid, posts.type, LEFT(posts.type, 1) AS basetype, INSTR(posts.type, '_HIDDEN')>0 AS hidden, posts.acount, posts.selchildid, posts.closedbyid, posts.upvotes, posts.downvotes, posts.netvotes, posts.views, posts.hotness, posts.flagcount, posts.title, posts.tags, UNIX_TIMESTAMP(posts.created) AS created, categories.title AS categoryname, categories.backpath AS categorybackpath, uservotes.vote AS uservote, uservotes.flag AS userflag, posts.userid, posts.cookieid, INET_NTOA(posts.createip) AS createip, userpoints.points, users.flags, users.level, users.email AS email, users.handle AS handle, users.avatarblobid, users.avatarwidth, users.avatarheight, NULL AS obasetype, NULL AS ohidden, NULL AS opostid, NULL AS ouserid, NULL AS ocookieid, NULL AS oip, NULL AS otime, NULL AS oflagcount, NULL AS oflags, NULL AS olevel, NULL AS oemail, NULL AS ohandle, NULL AS oavatarblobid, NULL AS oavatarwidth, NULL AS oavatarheight, NULL AS opoints, NULL AS parentid, NULL AS qcount, NULL AS position, NULL AS childcount, NULL AS content, NULL AS backpath, NULL AS passsalt, NULL AS passcheck, NULL AS emailcode, NULL AS sessioncode, NULL AS sessionsource, NULL AS loggedin, NULL AS loginip, NULL AS written, NULL AS writeip, NULL AS noticeid, NULL AS format, NULL AS pageid, NULL AS permit, NULL AS nav, NULL AS heading, NULL AS widgetid, NULL AS place FROM posts LEFT JOIN categories ON categories.categoryid=posts.categoryid LEFT JOIN uservotes ON posts.postid=uservotes.postid AND uservotes.userid='1' LEFT JOIN users ON posts.userid=users.userid LEFT JOIN userpoints ON posts.userid=userpoints.userid JOIN (SELECT postid FROM posts WHERE catidpath3=(SELECT categoryid FROM categories WHERE backpath='$&-_~#%\\\\@^*()=!()][`\\';:|\\".{},<>?# \xcf\x80\xc2\xa7\xc2\xbd\xd0\x96\xd7\xa9/test/url' LIMIT 1) AND type='Q' ORDER BY posts.created DESC LIMIT 0,50) y ON posts.postid=y.postid) UNION ALL (SELECT '1', posts.postid, posts.categoryid, posts.type, LEFT(posts.type, 1), INSTR(posts.type, '_HIDDEN')>0, posts.acount, posts.selchildid, posts.closedbyid, posts.upvotes, posts.downvotes, posts.netvotes, posts.views, posts.hotness, posts.flagcount, posts.title, posts.tags, UNIX_TIMESTAMP(posts.created), categories.title, categories.backpath, uservotes.vote, uservotes.flag, posts.userid, posts.cookieid, INET_NTOA(posts.createip), userpoints.points, users.flags, users.level, users.email, users.handle, users.avatarblobid, users.avatarwidth, users.avatarheight, LEFT(aposts.type, 1), INSTR(aposts.type, '_HIDDEN')>0, aposts.postid, aposts.userid, aposts.cookieid, INET_NTOA(aposts.createip), UNIX_TIMESTAMP(aposts.created), aposts.flagcount, ausers.flags, ausers.level, ausers.email, ausers.handle, BINARY ausers.avatarblobid, ausers.avatarwidth, ausers.avatarheight, auserpoints.points, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL FROM posts LEFT JOIN categories ON categories.categoryid=posts.categoryid LEFT JOIN uservotes ON posts.postid=uservotes.postid AND uservotes.userid='1' LEFT JOIN users ON posts.userid=users.userid LEFT JOIN userpoints ON posts.userid=userpoints.userid JOIN posts AS aposts ON posts.postid=aposts.parentid LEFT JOIN users AS ausers ON aposts.userid=ausers.userid LEFT JOIN userpoints AS auserpoints ON aposts.userid=auserpoints.userid JOIN (SELECT postid FROM posts WHERE catidpath3=(SELECT categoryid FROM categories WHERE backpath='$&-_~#%\\\\@^*()=!()][`\\';:|\\".{},<>?# \xcf\x80\xc2\xa7\xc2\xbd\xd0\x96\xd7\xa9/test/url' LIMIT 1) AND type='A' ORDER BY posts.created DESC LIMIT 0,50) y ON aposts.postid=y.postid WHERE posts.type='Q') UNION ALL (SELECT '2', NULL, categories.categoryid, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, categories.title, categories.tags, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, categories.parentid, categories.qcount, categories.position, COUNT(child.categoryid), categories.content, categories.backpath, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL FROM categories JOIN (SELECT NULL AS parentkey UNION SELECT grandparent.parentid FROM categories JOIN categories AS parent ON categories.parentid=parent.categoryid JOIN categories AS grandparent ON parent.parentid=grandparent.categoryid WHERE categories.backpath='$&-_~#%\\\\@^*()=!()][`\\';:|\\".{},<>?# \xcf\x80\xc2\xa7\xc2\xbd\xd0\x96\xd7\xa9/test/url' UNION SELECT parent.parentid FROM categories JOIN categories AS parent ON categories.parentid=parent.categoryid WHERE categories.backpath='$&-_~#%\\\\@^*()=!()][`\\';:|\\".{},<>?# \xcf\x80\xc2\xa7\xc2\xbd\xd0\x96\xd7\xa9/test/url' UNION SELECT parentid FROM categories WHERE backpath='$&-_~#%\\\\@^*()=!()][`\\';:|\\".{},<>?# \xcf\x80\xc2\xa7\xc2\xbd\xd0\x96\xd7\xa9/test/url' UNION SELECT categoryid FROM categories WHERE backpath='$&-_~#%\\\\@^*()=!()][`\\';:|\\".{},<>?# \xcf\x80\xc2\xa7\xc2\xbd\xd0\x96\xd7\xa9/test/url') y ON categories.parentid<=>parentkey LEFT JOIN

(The query keeps going but it is too long to post).

I tried increasing the max_allowed_packet in my.ini to large numbers and the error keeps happening (the apache log showed that error).  Any idea what is going on?

Furthermore, in the admin panel, everytime I refresh the page I get different URL options with the OK label next to them.  This is on a development server and I have rewrite turned on.  I've tried every one of the rewrite options.

Q2A version: 1.5.3

1 Answer

0 votes
by

Try switching on QA_OPTIMIZE_LOCAL_DB in qa-config.php - at least that will help determine which database query is causing the problem. 

...