HTML Checker
Moderator: moderator
HTML Checker
I have a customer who uses Google Analytics and never had a problem before but when I tried to save the customer's latest HTML, I'm suddenly getting an "Found unsafe HTML tag: script" error and the HTML won't save. If I remove the script, it's saving fine. Is there an undocumented feature to turn off HTML checking in the database?
Re: HTML Checker
Forgot to add that I'm running OpenEMM 2011 on a Windows Server 2003 machine with MySQL 5.5.timr wrote:I have a customer who uses Google Analytics and never had a problem before but when I tried to save the customer's latest HTML, I'm suddenly getting an "Found unsafe HTML tag: script" error and the HTML won't save. If I remove the script, it's saving fine. Is there an undocumented feature to turn off HTML checking in the database?
-
- Site Admin
- Posts: 2628
- Joined: Thu Aug 03, 2006 10:20 am
- Location: Munich, Germany
- Contact:
Re: HTML Checker
Is it possible to post the code causing the error message so that we can have a look at it?
OpenEMM Maintainer
Re: HTML Checker
This is the code that causes this error: "Found unsafe HTML tag: script"
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script><script src="Aarcher08092011EM_files/ga.js" type="text/javascript"></script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("UA-xxxxxxx-x");
pageTracker._trackPageview();
} catch(err) {}</script>
The above saved with no problem in 6.2 but if I copy an email that was saved in 6.2 and try to save the copy in 2011, I get the same unsafe HTML tag error. I think it's the script tag that's causing the problem because when I change <script> to <scrip> for example (which of course won't work), it saves with no error. I was hoping there was an undocumented feature like the one that was mentioned in this post - https://forum.openemm.org/bugs-bug-fixe ... 2102.html- to also turn off HTML checking.
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script><script src="Aarcher08092011EM_files/ga.js" type="text/javascript"></script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("UA-xxxxxxx-x");
pageTracker._trackPageview();
} catch(err) {}</script>
The above saved with no problem in 6.2 but if I copy an email that was saved in 6.2 and try to save the copy in 2011, I get the same unsafe HTML tag error. I think it's the script tag that's causing the problem because when I change <script> to <scrip> for example (which of course won't work), it saves with no error. I was hoping there was an undocumented feature like the one that was mentioned in this post - https://forum.openemm.org/bugs-bug-fixe ... 2102.html- to also turn off HTML checking.
-
- Site Admin
- Posts: 2628
- Joined: Thu Aug 03, 2006 10:20 am
- Location: Munich, Germany
- Contact:
Re: HTML Checker
Please replace class file MailingBaseForm.class in directory /home/openemm/webapps/openemm/WEB-INF/classes/org/agnitas/web/forms and class file MailingContentForm.class in directory /home/openemm/webapps/openemm/WEB-INF/classes/org/agnitas/web with two updated files which are available for download here:
https://sourceforge.net/projects/openem ... /Bugfixes/
Please tell us if this fix works for you so that we can announce it officially.
https://sourceforge.net/projects/openem ... /Bugfixes/
Please tell us if this fix works for you so that we can announce it officially.
OpenEMM Maintainer
Re: HTML Checker
That worked and the script code is saving with no errors after replacing those files. I know you get a lot of compliments for OpenEMM but I must say that your level of support for this free product is better than a lot of paid products support and I almost feel guilty for using OpenEMM for no charge. I know your main focus is your Enterprise-level Email Marketing Manager but you should consider developing an upgraded OpenEMM (easy for me to say) that offers multiple user/company capability and sells for less than $1000 US because I think you would sell a lot of licenses.
Thanks for your help!
Thanks for your help!
-
- Site Admin
- Posts: 2628
- Joined: Thu Aug 03, 2006 10:20 am
- Location: Munich, Germany
- Contact:
Re: HTML Checker
You know what: This is exactly what we are working on right now - a commercial version with some minor limits that runs on MySQL instead of Oracle. Stay tuned! 

OpenEMM Maintainer