MySQL Forums
Forum List  »  PHP

Re: Newby needs some help - collation/charset ?
Posted by: Marvin Miller
Date: December 20, 2013 09:20PM

Rick James Wrote:
-------------------------------------------------------
> Add this at the end of the function:
> mysql_set_charset('latin1',
> $this->connection_id);
>
> Then watch for other things to break.


Ok, adding that line to the sql driver file resulted in my being able to run all the problematic scripts I wanted - yeehaa!!! (and a big Thank you!).

However, with that line in there some of the posts on the site which had strange characters would not appear correctly. So, I took the line back out and...same thing.

At that point I re-started the web server and looked again - all fine. So it seems that either the connection is persistent or my opcode cache didn't pick up on the change.

So, we managed to work-around it, which is really, really fantastic.

Is it worth pursuing trying to figure out how to fix this on a permanent basis?
Lastly, should I be using utf-8 site-wide? It now seems almost the entire site has been changed over to it.

This is really great Rick - you just helped me fix something that I needed badly! Ultimately, this means (among other things) I can easily embed videos into my forum :)

Options: ReplyQuote


Subject
Written By
Posted
Re: Newby needs some help - collation/charset ?
December 20, 2013 09:20PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.