开发者

Rails & MySQL - Saved HTML Being Truncated at HTML Entity

I'm saving whole HTML documents in the database with ActiveRecord. I can see in the logs that correct INSERT statements are being generated and sent to MySQL but when I actually look in the database after the save has completed, the content is truncated.

It appears that   entities in the document are causing this truncation. I can URL encode the document or 开发者_如何学编程something to avoid this happening but I'd much rather understand why this is happening.


This was an encoding issue - make sure your read the HTML in as UTF8.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜