Home Action Replay Page Forum Index Home Action Replay Page
Home Action Replay Page
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

mucky error messages
Goto page 1, 2  Next
 
Post new topic   Reply to topic    Home Action Replay Page Forum Index -> General
View previous topic :: View next topic  
Author Message
Chad
Supereditor


Joined: 05 Jan 2005
Posts: 811

PostPosted: Mon Jul 23, 2007 2:05 am    Post subject: mucky error messages Reply with quote

If you have a double quote in your text field and try to submit a comment you get this.

Query failed : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'software/apple2/Castle Wolfenstein (1981)(Muse).zip" to the command line. The i' at line 2

What is REALLY annoying is that the text you typed is lost, you can't back button and retrieve it to edit out the double quote and resend. you have to retype it. So Please not put a persistent html flag on the comment page so backup up will go back to the previous form post OR stream edit double quotes into single double quotes before sending to the sql dealy.
Back to top
View user's profile Send private message
MJS
System Leader


Joined: 12 Feb 2005
Posts: 177
Location: Buenos Aires, Argentina

PostPosted: Mon Jul 23, 2007 4:07 am    Post subject: Reply with quote

Yeah, I had to type &quot for the double quotes and &#92 for the backlash.
Anyway, next time I will use the forum to talk about playback problems.
Noted about the -imagecache1 usage, thanks.
Back to top
View user's profile Send private message
Chad
Supereditor


Joined: 05 Jan 2005
Posts: 811

PostPosted: Mon Jul 23, 2007 4:41 am    Post subject: Reply with quote

you're welcome. I'm curious if you get that to playback, i'm trying to recreate the situation i had where i got it to playback, but of course now i can't... If i can't i'll just chok it up to mess and rerecord on wolfmess114, hopefully getting further too.
Back to top
View user's profile Send private message
gameboy9
Site Admin


Joined: 20 Sep 2004
Posts: 810

PostPosted: Tue Jul 24, 2007 10:46 am    Post subject: Reply with quote

Yeah, I really need to figure out how to fix that stuff...
Back to top
View user's profile Send private message Send e-mail
Chad
Supereditor


Joined: 05 Jan 2005
Posts: 811

PostPosted: Tue Jul 24, 2007 1:29 pm    Post subject: Reply with quote

the quickest fix is to do a search and replace for all the escapable characters (you can use vbscript's replace maybe even on client side code? or use a char replacement scheme server side) before you post them to the sql. so far double quotes(") need to get replaced with &quote; and (\) needs to get replaced with \
Back to top
View user's profile Send private message
Chad
Supereditor


Joined: 05 Jan 2005
Posts: 811

PostPosted: Thu Dec 13, 2007 11:14 pm    Post subject: Reply with quote

looks like master gameboy has trounced this bug, downloads with quotes in them work perfectly now.
Back to top
View user's profile Send private message
gameboy9
Site Admin


Joined: 20 Sep 2004
Posts: 810

PostPosted: Fri Dec 14, 2007 1:31 pm    Post subject: Reply with quote

No, I just renamed the files. Still haven't fixed the bug. I should post code when I get the next opportunity.
Back to top
View user's profile Send private message Send e-mail
gameboy9
Site Admin


Joined: 20 Sep 2004
Posts: 810

PostPosted: Sat Dec 22, 2007 9:06 pm    Post subject: Reply with quote

OK, my problem is the "addslashes" function in PHP. If I surround everything in single quotes, I'll have a problem with the double quotes that have a slash in them, and vice versa.

Got any ideas? Besides... maybe using a string transformation? (str_replace)
Back to top
View user's profile Send private message Send e-mail
Chad
Supereditor


Joined: 05 Jan 2005
Posts: 811

PostPosted: Sat Dec 22, 2007 10:13 pm    Post subject: Reply with quote

not familiar with php but can you concatenate quoted strings, maybe you can "first Part" +"\'" + "second Part"
Back to top
View user's profile Send private message
gameboy9
Site Admin


Joined: 20 Sep 2004
Posts: 810

PostPosted: Thu Jan 17, 2008 12:16 am    Post subject: Reply with quote

FINALLY squashed the single quote bug.

Also took care of the comments... hopefully.
Back to top
View user's profile Send private message Send e-mail
Chad
Supereditor


Joined: 05 Jan 2005
Posts: 811

PostPosted: Thu Jan 17, 2008 12:27 am    Post subject: Reply with quote

cool, downloads are probably safe now! but this feature might have been missed:

I still can't edit this screenshot pointer with a single quote in it (from the - split name to the original name which the screen shot is named.)

http://www.homeactionreplay.org/editgame.php?gameid=4614

also for anyone willing to try, if you are not a super editor or a genesis editor, i'd be curious if you could access this link above (testing the security :)
Back to top
View user's profile Send private message
Kale



Joined: 01 Jan 1970
Posts: 141

PostPosted: Thu Jan 17, 2008 6:11 pm    Post subject: Reply with quote

Chad wrote:

http://www.homeactionreplay.org/editgame.php?gameid=4614

also for anyone willing to try, if you are not a super editor or a genesis editor, i'd be curious if you could access this link above (testing the security Smile


Nope,I can't access it Wink
Back to top
View user's profile Send private message
Chad
Supereditor


Joined: 05 Jan 2005
Posts: 811

PostPosted: Thu Jan 17, 2008 9:22 pm    Post subject: Reply with quote

cool, security is in lockdown! The game screenshot pointer i'm trying to change is from all the splits.

Micro Machines - Turbo Tournament '96 (V1.1) (E)

What zwaxy does for splits in marp is to have splits have a deafult screenshot pointer assigned when the split is made that goes to the parent romset. So that when splits are made the screenshots don't disappear they just borrow from the existing one. I guess when you make a split it doesn't make a new game entry you kind of have to copy the existing one, so it might not be as automatable here.
Back to top
View user's profile Send private message
gameboy9
Site Admin


Joined: 20 Sep 2004
Posts: 810

PostPosted: Fri Jan 18, 2008 1:13 pm    Post subject: Reply with quote

I don't quite understand Chad, but yeah, you always need to do a screenshot pointer for splits, and you have to manually change it if you want to use a different filename.

Update the screenshot with the same filename? No problem.

The single quote problem in regards to the screenshot pointer in the game edit was fixed.

I also changed an error message from "Invalid Game ID" to "Invalid Game ID or no changes were made". (discovered while I was fixing the single quote mess)
Back to top
View user's profile Send private message Send e-mail
Chad
Supereditor


Joined: 05 Jan 2005
Posts: 811

PostPosted: Sun Feb 03, 2008 5:58 pm    Post subject: Reply with quote

the add comments for recordings page still gets nukified when you put a quote in it.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Home Action Replay Page Forum Index -> General All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group