I'm doing a migration.
I made a PHP script to generate posts in the new WordPress database.
The post content contains an HTML link containing href="javascript:"
and onClick="trackOutboundLink('url')"
.
post_content in the new database
<div>
<a class="exclusive button-exclusive" href="javascript:" onclick="trackOutboundLink('url'); return false;" rel="nofollow"><span>▷ Text link</span></a>
</div>
For some reason, the href
and onclick
attributes did not show in the admin post editor. Why? How can I fix this?