Jump to content

foleyatwork

Member
  • Posts

    1,269
  • Joined

  • Last visited

  • Days Won

    4

Community Answers

  1. foleyatwork's post in How can I track form submissions in Google Analytics? was marked as the answer   
    Paste the following code into the footer code injection of your site.
    <script> Y.use('node', function() { Y.on('domready', function() { Y.all('.form-block').each(function(n) { var d = n.getData('block-json'); d = Y.JSON.parse(d); n.one('form').on('submit',function() { _gaq.push(['_trackEvent', d.formName + ' Submission', 'Form Submission', 'Submit']); }); }); }); }); </script>
    This is a one step process. Once you paste this code in your footer, each form will be tracked automatically with the form name in Google Analytics.
    Please post any feedback as a comment here. If there is a bug I will try and fix it.
    Also, please note this is not supported by Squarespace, even though I am a Squarespace employee. Support won't be able to help you out, but I will do my best to make sure this code works and stays up-do-date.
  2. foleyatwork's post in Code Block: How can I autoplay a video? was marked as the answer   
    Disclaimer: I almost always think autostarting videos is a terrible idea. Just my personal opinion. Please do good, not evil, with this answer.
    With YouTube you can just add ?autoplay=1 to the end of the iframe URL. For instance:
    <iframe width="420" height="315" src="http://www.youtube.com/embed/4KRZQQ_eICo?autoplay=1" frameborder="0" allowfullscreen></iframe>
  3. foleyatwork's post in How do I display a Facebook feed on my site? was marked as the answer   
    There are a few different ways to do this. By far the easiest is to use one of Facebook's social plugins:
    http://developers.facebook.com/docs/plugins/ (Like Box does what you're looking for, I think.)
    Those will generate code for you and all you have to do is paste it into the Code Block in Squarespace.
×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.