<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Custom JavaScript event got deleted and won't auto-regenerate the deleted event in APIs &amp; Integrations</title>
    <link>https://community.hubspot.com/t5/APIs-Integrations/Custom-JavaScript-event-got-deleted-and-won-t-auto-regenerate/m-p/224559#M3455</link>
    <description>&lt;P&gt;Hi all,&lt;/P&gt;
&lt;P&gt;I made a custom event using the following script:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;&amp;gt; var element = document.querySelector('meta[property="topic"]');
&amp;gt; var content = element &amp;amp;&amp;amp; element.getAttribute("content");
&amp;gt; 
&amp;gt; _hsq.push(["trackEvent", {
&amp;gt;         id: content,
&amp;gt;         value: 1
&amp;gt;     }]);
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Every article has a meta tag called topic with the name of the topic that creates/updates an event by the topic name. It is working well for each and every topic.&lt;/P&gt;
&lt;P&gt;The problem is, it is not creating an event for "Economics" topic. I don't know why that is happening. Is it a bug from HubSpot's side? Any help will be greatly appreciated.&lt;/P&gt;
&lt;P&gt;sample article: &lt;A href="https://fee.org/articles/got-tariff-fatigue/" rel="nofollow noopener"&gt;https://fee.org/articles/got-tariff-fatigue/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Thanks in advance.&lt;/P&gt;</description>
    <pubDate>Mon, 18 Jun 2018 15:58:29 GMT</pubDate>
    <dc:creator>Riadhoq</dc:creator>
    <dc:date>2018-06-18T15:58:29Z</dc:date>
  </channel>
</rss>

