Upgrade to Pro — share decks privately, control downloads, hide ads and more …

EC-CUBE3デザイナー向け勉強会 #4

EC-CUBE3デザイナー向け勉強会 #4

amidaike

March 23, 2016
Tweet

More Decks by amidaike

Other Decks in Programming

Transcript

  1. ϒϩοΫΛ׆༻ͨ͠σβΠϯ • ϒϩοΫ؅ཧͱϖʔδϨΠΞ΢τ؅ཧΛར༻͢Δ͜ͱͰɺ facebook Page Plugin΍Google AnalyticsɺtwitterϘλϯ΍ instagramϘλϯ౳ͷιʔγϟϧϘλϯ͕؆୯ʹઃஔ͢Δ͜ ͱ͕ՄೳͰ͢ɻ •

    GoogleλάϚωʔδϟʔ΍YahooλάϚωʔδϟʔ౳ͷ <body>λά௚Լ΍</body>λά௚લʹຒΊࠐΉඞཁͷ͋Δ λάʹ͍ͭͯ͸ɺඪ४ͷςϯϓϨʔτͩͱϖʔδϨΠΞ΢ τ؅ཧͰ͸ରԠෆՄೳͳͨΊɺdefault_frame.twig΁௚઀ه ड़͢Δඞཁ͕͋Γ·͢ɻ
  2. ϒϩοΫΛ׆༻ͨ͠σβΠϯ • facebook Page Pluginͷઃஔํ๏
 ϒϩοΫ؅ཧΑΓҎԼͷJavaScriptλάΛೖྗͯ͠ϒ ϩοΫΛ࡞੒͠·͢ɻ
 <div id="fb-root"></div> <script>(function(d,

    s, id) { var js, fjs = d.getElementsByTagName(s)[0]; if (d.getElementById(id)) return; js = d.createElement(s); js.id = id; js.src = "//connect.facebook.net/ja_JP/sdk.js#xfbml=1&version=v2.5"; fjs.parentNode.insertBefore(js, fjs); }(document, 'script', 'facebook-jssdk'));</script>
  3. ϒϩοΫΛ׆༻ͨ͠σβΠϯ • facebook Page Pluginͷઃஔํ๏
 ϒϩοΫ؅ཧΑΓҎԼͷදࣔ༻λάΛೖྗͯ͠ϒϩοΫ Λ࡞੒͠·͢ɻ
 <div class="fb-page" data-href="https://www.facebook.com/

    facebook" data-tabs="timeline" data-small-header="false" data-adapt-container-width="true" data-hide-cover="false" data-show-facepile="true"><div class="fb-xfbml-parse- ignore"><blockquote cite="https://www.facebook.com/ facebook"><a href="https://www.facebook.com/ facebook">Facebook</a></blockquote></div></div>
  4. ϒϩοΫΛ׆༻ͨ͠σβΠϯ • Google Analyticsλάͷઃஔํ๏
 ϒϩοΫ؅ཧΑΓαΠτ༻ͷτϥοΩϯάίʔυΛೖ ྗͯ͠ϒϩοΫΛ࡞੒͠·͢ɻ <!-- Google Analytics -->

    <script> (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) })(window,document,'script','//www.google-analytics.com/analytics.js','ga'); ga('create', 'UA-xxxxxxx-x', 'auto'); ga('send', 'pageview'); </script>
  5. ϒϩοΫΛ׆༻ͨ͠σβΠϯ • GoogleλάϚωʔδϟʔͷઃஔํ๏
 default_frame.twigʹରͯ͠<body>௚ԼʹGoogleλά Ϛωʔδϟʔ༻λάΛઃஔ͠·͢ɻ <body> <!-- Google Tag Manager

    --> <noscript><iframe src="//www.googletagmanager.com/ns.html?id=GTM-T6HJ3B" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript> <script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src= '//www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f); })(window,document,'script','dataLayer','GTM-XXXXXX');</script> <!-- End Google Tag Manager -->
  6. ϒϩοΫΛ׆༻ͨ͠σβΠϯ • YahooλάϚωʔδϟʔͷઃஔํ๏
 default_frame.twigʹରͯ͠</body>௚લʹYahooλά Ϛωʔδϟʔ༻λάΛઃஔ͠·͢ɻ <!-- Yahoo Tag Manager -->

    <script type="text/javascript"> (function () { var tagjs = document.createElement("script"); var s = document.getElementsByTagName("script")[0]; tagjs.async = true; tagjs.src = "//s.yjtag.jp/tag.js#site=xxxxxxx"; s.parentNode.insertBefore(tagjs, s); }()); </script> <noscript> <iframe src="//b.yjtag.jp/iframe?c=xxxxxxx" width="1" height="1" frameborder="0" scrolling="no" marginheight="0" marginwidth="0"></iframe> </noscript> <!-- Yahoo Tag Manager --> </body>