隐藏Javascript代码段

I am trying to keep track of users clicking on a button within my marketing automation software, Infusionsoft. Infusionsoft gives me a snippet which I would like to add to my 'Click Here' button shown below. However, I would like to remove the form itself as it is not necessary to show. When a user clicks on the button, the javascript snippet would still run in the background. I realize this might be a round-about-way of solving this problem, so I'm welcoming all suggestions for improvements.

Is there anyway I can hide this form while still utilizing this snippet code when a user click on 'Click Here'?

From what I've researched, it seems like:

1) I would have to implement some third party solution, such as Flash or Flex (prefer not to do this)

2) I've tried utilizing a <p hidden> tag, but that didn't seem to work

3) Add a separate JS file and reference that JS file in my HTML (but not exactly sure how this would make it work)

Below is a screenshot of what my site looks like: Form Screenshot

Would like to remove the form above

Below is my code:

<p><a target="_blank" title="Click to download all 7 I Love It ads" onclick="window.open('<?php echo $urlStringILI; ?>','popup','width=450,height=350,left='+(screen.availWidth/2-200)+',top='+(screen.availHeight/2-125)+'');return false;" href="<?php echo $urlStringILI; ?>" ><strong>Click Here</strong></a> To  Download The &ldquo;I Love It Because I Chose It&rdquo; Ads
    <script type='text/javascript' src='https://fb976.infusionsoft.com/app/form/iframe/db670b7e512a36318bcc43f5592377ec'></script>
</p>
douhuan1905
douhuan1905 使用infusionsoft,而不是使用javascript片段,您可以使用他们的表单HTML代码,对吗?
2 年多之前 回复
dousuize3082
dousuize3082 我真的不想使用提交按钮。我也想隐藏它,但我知道只有按下该按钮时才会触发javascript代码片段。希望看看@Rohit.007是否有任何解决方法
2 年多之前 回复
douyazi1129
douyazi1129 它被生成到iFrame中,由于XXS,您无法通过点击此处链接触发提交按钮。
2 年多之前 回复
dongliyu3278
dongliyu3278 道歉。不,我不是想发布数据。当用户单击“单击此处”按钮时,我只是尝试将javscript片段解雇,但我不想显示infusionsoft自动生成的表单。请参阅代码中的<script>标记
2 年多之前 回复
drkrsx3135168
drkrsx3135168 目前还不清楚你想要什么。您是否只是在单击按钮时尝试POST用户数据(以某种方式已经在页面上)?
2 年多之前 回复
dongzhenge2014
dongzhenge2014 表单由infusionsoft通过javascript片段自动生成。在我的CSS中我可以编辑它,如果它自动生成?
2 年多之前 回复
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问