Previous Thread
Next Thread
Print Thread
Hop To
Joined: Mar 2008
Posts: 326
D
Enthusiast
Enthusiast
D Offline
Joined: Mar 2008
Posts: 326
admin/database.php?returntab=1 (SQL Command in CP)

  1. Type a query that contains line breaks into the Query box.
  2. Save the query.
  3. Click the 'Execute' link next to the saved query.
  4. Enjoy a SQL error.


Fix:
In templates/default/admin/database.tmpl find:
Code
function exeCommand (i) {
	document.sql.command.value = commandArray[i];
	document.sql.submit();
}
and replace it with:
Code
function exeCommand (i) {
	document.sql.command.value = commandArray[i].replace(/JSLBR/g,'\n');
	document.sql.submit();
}

Joined: Jun 2006
Posts: 1,344
G
veteran
veteran
G Offline
Joined: Jun 2006
Posts: 1,344
Yes, I saw this bout a week ago when doing the same. I needed to click use and than execute for it to wor.k right

Joined: Mar 2008
Posts: 326
D
Enthusiast
Enthusiast
D Offline
Joined: Mar 2008
Posts: 326
It appears that this existed in 7.4.2 (since the code snippet culprit is identical) but I guess nobody noticed it. I don't know how far back in versions it goes, but at least they have a fix now. smile

Joined: Jun 2006
Posts: 1,344
G
veteran
veteran
G Offline
Joined: Jun 2006
Posts: 1,344
I noticed it in 7.4.2 and while in Pm with Rick mentioned it, not sure if he saw it though.

Joined: Jun 2006
Posts: 9,242
Likes: 1
R
Former Developer
Former Developer
R Offline
Joined: Jun 2006
Posts: 9,242
Likes: 1
Thanks for the report and fix.

Joined: Mar 2008
Posts: 326
D
Enthusiast
Enthusiast
D Offline
Joined: Mar 2008
Posts: 326
[Linked Image from ubbdev.com]

Joined: Jun 2006
Posts: 9,242
Likes: 1
R
Former Developer
Former Developer
R Offline
Joined: Jun 2006
Posts: 9,242
Likes: 1
-1 brownie points for posting dancing fruit frown

Joined: Mar 2008
Posts: 326
D
Enthusiast
Enthusiast
D Offline
Joined: Mar 2008
Posts: 326
But that's how you know it's ripe! wink

Joined: Jun 2006
Posts: 9,242
Likes: 1
R
Former Developer
Former Developer
R Offline
Joined: Jun 2006
Posts: 9,242
Likes: 1
That's how you know it's been possessed by the devil!

Joined: Mar 2008
Posts: 326
D
Enthusiast
Enthusiast
D Offline
Joined: Mar 2008
Posts: 326
Mmm... sacrilicious.


Link Copied to Clipboard
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
spam issues
by ECNet - 03/19/2024 11:45 PM
Looking for a forum
by azr - 03/15/2024 11:26 PM
Editing Links in Post
by Outdoorking - 03/15/2024 9:31 AM
Question on barkrowler and the like
by Mors - 02/29/2024 6:51 PM
Member Permissions Help
by domspeak - 02/27/2024 6:31 PM
Who's Online Now
0 members (), 744 guests, and 147 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
Los Angeles
Los Angeles
by isaac, August 6
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Stones
Stones
by isaac, August 19
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20230217)