html不识别<br/>,后台返回<br/>,前端不换行解决办法
作者:互联网
今天编写页面,后台直接返回带有html格式的字符串,包含<br/>,前端直接输出了<br/>页面不换行
解决办法
后台将<br/> 替换为 \n 并在前端添加样式style="white-space:pre-line";
select a.*,b.EngName,b.CnName,(SELECT inst+ ',\n' FROM mi_tls_instruction WITH(NOLOCK) where
pjno = a.MiProject and pono = a.Step for XML Path ('')) as LotInstruction from mi_t_pdrouting a
WITH(NOLOCK) left join mi_t_wc b WITH(NOLOCK) on a.WC = b.WC where
MiProject = 'XXXXXXXXXX-00' order by a.step asc
标签:解决办法,WC,换行,前端,mi,html,后台,NOLOCK 来源: https://www.cnblogs.com/Depingblogs/p/15140768.html