Forum Replies Created
-
AuthorPosts
-
royvarleyMember
Excellent!
All-in-all a successful night's work!
royvarleyMemberGood Morning!
Peter – you're right – it's the handling of the magic quotes variable being on or off. I should have twigged when I was saying that the should be \. If magic quotes were on it would have changed to \ and the synch would work.
I changed the code to:
if (get_magic_quotes_gpc()) {
$xmlrecvd = stripslashes ( urldecode ( $_POST['textfield'] ) );
} else {
$xmlrecvd = urldecode ( $_POST['textfield'] );
}
And that works.
SQLyog folks will have to check that that is all that's required – there may be other parts of the code that need attention.
… to breakfast…
royvarleyMemberBeing 2:00am, I'm going to bed!
I'll catch up tomorrow – goodnight!
royvarleyMembermagic_quotes_gpc is off.
royvarleyMemberpeterlaursen wrote on Aug 3 2005, 01:46 AM:OK – it seems that you know what you are doing 😀[post=”6707″]<{POST_SNAPBACK}>[/post]I wouldn't go that far!
stripslashes converts things like ' into '
Yes very odd that Ritesh and you have both not seen the problem. Obviously something peculiar about my setup – but I can't see what it could be right now.
royvarleyMemberstripslashes did the right thing. I rather think that the should have been \ in the original xml.
royvarleyMemberAgreed that's what it should be.
Not sure about your conclusion but it could well be so!
I'd like to know what the raw xml looks like for the working tests that Ritesh did using the tunnel. Or even the same set of translations.
royvarleyMemberYes.
I've been running the tunnel in debug mode with a few extra writelogs.
The raw XML, passed to the tunnel, that generates the query is:-
insert into `roles` values ('183', 'Mr Slate's Quarry', NULL, '1', '15', '43')
Then we execute:
$xmlrecvd = stripslashes ( urldecode ( $_POST['textfield'] ) );
which gives a value of $xmlrecvd of:
insert into `roles` values ('183', 'Mr Slate's Quarry', NULL, '1', '15', '43')
We lose the
This is then translated to:
insert into `roles` values ('183', 'Mr Slate's Quarry', NULL, '1', '15', '43')
which is wrong.
royvarleyMemberI upgraded to 4.1 beta 7 today. The file looked the same but I uploaded it to the website anyway.
royvarleyMemberWell it's the one that's in the SQLyog directory. It has a creation date/time of 1-Feb-2005 3:26:05PM.
My ISP is still running PHP 4.3.8
royvarleyMemberFYI: I tried it with 4.1 beta 7, just in case. Problem is still there.
My gut feel tells me it's the parser in SQLyogTunnel.php – not handling an escaped single quote inside another pair of quotes… or something like that.
royvarleyMemberThat fixed it! Thanks!
royvarleyMemberI was trying to replicate this error so that I could send a sample db.
If I set up the two databases with just a single table in each on my windows machine, the synch works. No problem.
If I set up the destination db on the website (just the same, single table) and then try to synch, I get the error as described.
This was running the synch job immediately from SQLYog.
Something is different about running the synch locally and running it across to a destination website. The destination website is Linux. MySQL version is the same on both sites.
I assume that SQLYog/SJA on my local machine generates the command files for MySQL on the destination machine? It is either generating something different or it's different when it gets to the destination to execute.
royvarleyMemberRitesh, I'll start a new post for my issue – I hadn't intended to hijack Peter's thread, I thought it was the same problem – but maybe not.
royvarleyMemberDan, if I understand you correctly, you have a single machine on which you run a live website. You want to run a separate development website on the same machine?
If that's the case, these links might point you in the right direction:
http://sunsite.mff.cuni.cz/MIRRORS/ftp.mys…le_servers.html
http://www.webmasterworld.com/forum48/1306.htm
You might have to set up the development site with a different port for MySQL.
Hope that helps.
-
AuthorPosts