← Blogging/Comunidades

Codigo do analytics

Lida 2839 vezes

Offline

pedro teixeira 
Membro
Mensagens 237 Gostos 0
Troféus totais: 22
Trófeus: (Ver todos)
Super Combination Combination Topic Starter Poll Voter Level 4 Level 3 Level 2 Level 1 100 Posts 50 Posts


Olá gostaria de saber se o codigo está bem colocado, foi o unico sitio que concegui colocar se antes do body, sem que o tema perde-se formatação.

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html expr:dir='data:blog.languageDirection' xmlns='http://www.w3.org/1999/xhtml' xmlns:b='http://www.google.com/2005/gml/b' xmlns:data='http://www.google.com/2005/gml/data' xmlns:expr='http://www.google.com/2005/gml/expr'>
  <head>
    <b:include data='blog' name='all-head-content'/>
    <title><data:blog.pageTitle/></title>
    <b:skin><![CDATA[/*
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">

try {
var pageTracker = _gat._getTracker("UA-9935139-10");
pageTracker._trackPageview();
} catch(err) {}</script>
-----------------------------------------------
Blogger Template Style
Name:     BloggerTube
Designer: Dante Araujo (www.dantearaujo.net)
Developers: Abu Farhan (www.abu-farhan.com) and Aneesh Joseph (www.bloggerplugins.org)
Date: September 2009     
----------------------------------------------- */

/*---------------------------------------------
                 CSS RESET
---------------------------------------------*/

#navbar-iframe {
display: none !important;
}

* {
margin:0;
padding:0;
list-style:none;
border:none;
vertical-align:baseline;
outline:none;
}


body {
background:transparent url(http://3.bp.blogspot.com/_WoCJXgXotb8/SrrsY0G_3FI/AAAAAAAAAAU/FGOXZBwWs0k/s1600/bodybg-5.gif) repeat scroll 0 0;
font-family:'Lucida Grande',Verdana,Arial,Sans-Serif;
font-size:12px;
line-height:1.4em;
Offline

Ricardo75 
Membro
Mensagens 1660 Gostos 0
Troféus totais: 28
Trófeus: (Ver todos)
Super Combination Combination Topic Starter 10 Poll Votes Poll Voter Level 5 Level 4 Level 3 Level 2 Level 1

Pedro, na consola do Googla Analytics és informado se o código está ou não a funcionar e até é relativamente rápido, em menos de 5 minutos tens essa informação disponível.

De qualquer forma o Google aconselha a colocar o código antes de </body> e não no <head>, assim caso haja algum problema com o analytics o teu site vai mostrar lentidão ou pode mesmo não abrir.
Offline

pedro teixeira 
Membro
Mensagens 237 Gostos 0
Troféus totais: 22
Trófeus: (Ver todos)
Super Combination Combination Topic Starter Poll Voter Level 4 Level 3 Level 2 Level 1 100 Posts 50 Posts

Pedro, na consola do Googla Analytics és informado se o código está ou não a funcionar e até é relativamente rápido, em menos de 5 minutos tens essa informação disponível.

De qualquer forma o Google aconselha a colocar o código antes de </body> e não no <head>, assim caso haja algum problema com o analytics o teu site vai mostrar lentidão ou pode mesmo não abrir.

no analytics nao aparece nada, fica la um triangulo. mas quando eu coloco antes do body o site dá erro.
alguma maneira? aquilo é um blogspot
Offline

Pedro Lopes 
Beta tester
Mensagens 3568 Gostos 18
Feedback +6

Troféus totais: 32
Trófeus: (Ver todos)
Level 6 Windows User Super Combination Combination Topic Starter 10 Poll Votes Poll Voter Level 5 Level 4 Level 3

Coloca dentro do body, antes de </body>, resumindo, no fim.
Offline

pedro teixeira 
Membro
Mensagens 237 Gostos 0
Troféus totais: 22
Trófeus: (Ver todos)
Super Combination Combination Topic Starter Poll Voter Level 4 Level 3 Level 2 Level 1 100 Posts 50 Posts

Coloca dentro do body, antes de </body>, resumindo, no fim.
desculpa agora fiquei confuso, podes por ai o meu codigo com um  exp?
Offline

Pedro Lopes 
Beta tester
Mensagens 3568 Gostos 18
Feedback +6

Troféus totais: 32
Trófeus: (Ver todos)
Level 6 Windows User Super Combination Combination Topic Starter 10 Poll Votes Poll Voter Level 5 Level 4 Level 3

Código: [Seleccione]
<html>
<head>
   <title>Titulo...</title>
</head>
<body>
Conteudo do site...

<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("UA-9935139-10");
pageTracker._trackPageview();
} catch(err) {}</script>
</body>
</html>
Offline

pedro teixeira 
Membro
Mensagens 237 Gostos 0
Troféus totais: 22
Trófeus: (Ver todos)
Super Combination Combination Topic Starter Poll Voter Level 4 Level 3 Level 2 Level 1 100 Posts 50 Posts

Código: [Seleccione]
<html>
<head>
   <title>Titulo...</title>
</head>
<body>
Conteudo do site...

<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("UA-9935139-10");
pageTracker._trackPageview();
} catch(err) {}</script>
</body>
</html>

Ok, obrigado eu coloquei lá de para ja tudo bem, continua é o triangulo amarelo no google analytics.
quanto tempo leva ao analyticsaceitar o meu site?