PHP echo是否有长度限制? [英] Are there any length limits on PHP echo?

查看:446
本文介绍了PHP echo是否有长度限制?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有这个脚本,它从mysql获取一些数据,然后使用echo输出它。
但是,随着页面的增长和变得更长,我突然出现了一种怪异的行为,它的结尾处削减了65535 chrs(使用strlen进行检查时)

I have this script that fetches some data from mysql and then uses echo to output it. But, as the page have grown and gotten longer all of a sudden i have this weird behavior where it cuts of the end at 65535 chrs (when using strlen to check)

数据全部保存在MySQL中,超过了使用echo时显示的65535 chrs。

编辑: 对不起,似乎并非所有数据都已保存,正是我的所见即所得(WYSIWYG)编辑器使所有内容看起来都已保存,但已保存。 (它会自动关闭未关闭的标签,使我再次打开内容时一切正常。)

The data is all saved in MySQL, beyond the 65535 chrs showing when using echo.
Sorry, it seems like NOT all data was saved, it was my WYSIWYG editor that made it look like all was saved but it wasent. (It auto closed unclosed tags making it look all ok when i opend the content again.)

为什么会这样?

我所要做的就是

$content= $row['content'];
echo $content;


推荐答案

您确定这是PHP问题吗? MySQL TEXT字段的最大大小为65535个字符。确保文本实际上在您的数据库中。

Are you sure it's a PHP issue? The MySQL TEXT field has a maximum size of 65535 characters. Make sure the text is actually in your database.

这篇关于PHP echo是否有长度限制?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆