Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/89.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php Don';在输入值中处理html_Php_Html_Mysql - Fatal编程技术网

Php Don';在输入值中处理html

Php Don';在输入值中处理html,php,html,mysql,Php,Html,Mysql,我的mysql表中有一个包含html代码的条目: <p>Hello!</p> 以下是条目: <p><ol><li>HKCU/Software/Microsoft/Windows/NT/CurrentVersion/WindowsLegacy/DefaultPrinterMode<li> Set to 0 (on)</ol> HKCU/Software/Microsoft/Windows/NT/CurrentV

我的mysql表中有一个包含html代码的条目:

<p>Hello!</p>
以下是条目:

<p><ol><li>HKCU/Software/Microsoft/Windows/NT/CurrentVersion/WindowsLegacy/DefaultPrinterMode<li> Set to 0 (on)</ol>
HKCU/Software/Microsoft/Windows/NT/CurrentVersion/WindowsLegacy/DefaultPrinterMode
  • 设置为0(on)
    我想这样就行了

    <textarea><?php echo  $row['details'];?></textarea>
    
    
    
    尝试保存数据,如

    ascii_to_entities($this->input->post('ur_textara_name'));
    
    在展示的时候

    entities_to_ascii()
    

    你必须转义特殊字符。你可以用它来做

    此外,您不应为textarea设置值,而应将其写入其内容:

    <textarea>
    <?php /* some code here */ ?> 
    </textarea>
    
    
    
    您对文本区域的期望是什么?您不能在文本区域中显示段落,只能在元素中显示文本区域内容。您好,我希望显示HKCU/Software/Microsoft/Windows/NT/CurrentVersion/WindowsLegacy/DefaultPrinterMode
  • 设置为0(on)然后我可以更改并更新它,让每个人都知道你的答案和malutki5200 A.R,将代码放在中间,而不是value=worked echo“Details:”$行[“详细信息”]。“”;
    <textarea>
    <?php /* some code here */ ?> 
    </textarea>