Youtube Subscribe Button Event

不打扰是莪最后的温柔 提交于 2019-12-08 05:26:47

问题


How can I catch an event when a user subscribes to my Youtube Channel on my site?


回答1:


You could use an image, button, or banner in order to record the action(click) that lands them on the YouTube subscription page.

<p> <a href="DOMAIN" onClick="_gaq.push(['_trackEvent', 'ChannelSubcription', 'SUBSCRIBED', 'SUBSCRIPTION');"><img src="Title.jpg"></a></p>

If you're trying to record the action from an embedded player you'll need to use YouTube's API - it would be wise to reference their beta API. You could also use the custom iframe subscribe button for your channel and record without having them exit your site.



来源:https://stackoverflow.com/questions/11283159/youtube-subscribe-button-event

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!