Visual editor stripping Adwords onclick from link
-
Hello,
I’m trying to find a plugin or something that will prevent WordPress from stripping the onclick portion of code when I add it to the HTML editor.Backgroung
I’m trying to track conversions in Adwords. I added their javascript using a header plugin. That’s the first step. But now I need to add this:
onClick=”goog_report_conversion (‘https://amazon.com’)”
to the image link or direct html link.I switch to HTML editor, add this little code snippet, then when I switch back to visual editor, and then back to HTML editor, the tracking onClick is stripped.
My hope was there was some way to add this code to the Image Details window, like Image CSS Class that I could add this code in, but there must be a common way to do this
There are tons of posts on how to add the javascript to the header, but that’s only half the activity. Without the onClick added to the link (picture, text), there’s no way Adwords will track my conversions.
Certainly there has to be an “easy” way to do this, since there are tons of websites that sell and track their conversions?
- The topic ‘Visual editor stripping Adwords onclick from link’ is closed to new replies.