How can I insert unicode characters into Published html?
显示 更早的评论
I've started using the "Publish" feature again for creating tutorial and exam question solutions. Its very handy, now that there is a way to make the Latex equations come out bigger (and readable!). ( Thread 163367 )
Now, the next issue I am trying to solve is how to get some unicode characters into the published html, to represent (for example), the Ohms symbol Ω or the angle symbol ∠
The trouble is, when I try and insert these into the MATLAB script and publish, it (you may say correctly) "escapes" the & character as & and so Ω comes out as Ω in the published html and this of course then appears in the web browser as Ω again.
An ugly solution is to post-edit every html file and strip out the &'s and replace them with just & again.
But, is there some way of stopping MATLAB adjusting the &'s to &'s?
In my MATLAB script, I am trying to use lines like:
I1_answer = [MFAJR_SigFigStr(abs(I1),2),' ∠ ',MFAJR_SigFigStr(180/pi*angle(I1),2),'° Amps RMS (angle relative to V1)']
I am hoping to get something like this in the final browser window
I1_answer =
2.2 ∠ -90° Amps RMS (angle relative to V1)
But I am actually getting
I1_answer =
2.2 ∠ -90° Amps RMS (angle relative to V1)
Any ideas?
By the way, writing this thread took a long time because the forum software keeps evaluating the & codes and I had to double-code all the ampersands. I think it looks right in the final preview/view now..
回答(1 个)
类别
在 帮助中心 和 File Exchange 中查找有关 App Building 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!