← WordPress

[Dúvida] Optimizar header.php

Lida 1647 vezes

Offline

Tomé Mendes 
Membro
Mensagens 92 Gostos 0
Feedback +1

Troféus totais: 26
Trófeus: (Ver todos)
Level 5 Tenth year Anniversary Nineth year Anniversary Windows User Super Combination Combination Topic Starter Level 4 Level 3 Level 2

Boas,

Ultimamente tenho andado a fazer alterações por todo o meu site. Tanto para fins de SEO como a nível de Design. O que queria perguntar é o seguite:

Se eu colocar aqui o meu header.php, ajudam-me a optimiza-lo?

Isto é, dizer o que faz falta e o que pode ser removido sem problema...

Pode ser? :D


EDIT:
Código: [Seleccione]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
<head profile="http://gmpg.org/xfn/11">
<meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" />
<meta name='google-site-verification' content='LKQSrCBP4S4d690hqltP1LN0SXG3UfW-KocAPi-ks3U' />
<title><?php wp_title(''); ?><?php if(wp_title(''false)) { echo ' :'; } ?> <?php bloginfo('name'); ?></title>

<link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen" />
<link rel="alternate" type="application/rss+xml" title="<?php bloginfo('name'); ?> RSS Feed" href="<?php bloginfo('rss2_url'); ?>" />
<link rel="alternate" type="application/atom+xml" title="<?php bloginfo('name'); ?> Atom Feed" href="<?php bloginfo('atom_url'); ?>" />
<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />

<link rel="stylesheet" type="text/css" href="<?php bloginfo('template_directory'); ?>/glide.css" media="screen" />
<link rel="shortcut icon" href="http://www.ridfick.com/wp-content/uploads/favicon.ico" />

<?php 
wp_enqueue_script
('jquery');
wp_enqueue_script('cufon'get_stylesheet_directory_uri() . '/js/cufon.js');
wp_enqueue_script('easing'get_stylesheet_directory_uri() . '/js/jquery.easing.1.1.js');
wp_enqueue_script('carousal'get_stylesheet_directory_uri() . '/js/jcarousel.js');
wp_enqueue_script('Myriad'get_stylesheet_directory_uri() . '/js/Myriad_Pro_700.font.js');
wp_enqueue_script('Effects'get_stylesheet_directory_uri() .'/js/effects.js');


?>


<script type="text/javascript"><!--//--><![CDATA[//><!--
sfHover = function() {
if (!document.getElementsByTagName) return false;
var sfEls1 = document.getElementById("catmenu").getElementsByTagName("li");
for (var i=0; i<sfEls1.length; i++) {
sfEls1[i].onmouseover=function() {
this.className+=" sfhover1";
}
sfEls1[i].onmouseout=function() {
this.className=this.className.replace(new RegExp(" sfhover1\\b"), "");
}
}
var sfEls1 = document.getElementById("menu").getElementsByTagName("li");
for (var i=0; i<sfEls1.length; i++) {
sfEls1[i].onmouseover=function() {
this.className+=" sfhover";
}
sfEls1[i].onmouseout=function() {
this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
}
}
}
if (window.attachEvent) window.attachEvent("onload", sfHover);
//--><!]]></script>

<?php //comments_popup_script(); // off by default ?>
<?php 
if ( is_singular() ) wp_enqueue_script'comment-reply' );
wp_head(); ?>


</head>

<body>
<div id="catmenucontainer">

<?php wp_nav_menu( array( 'container_id' => 'catmenu','theme_location' => 'primary' ) ); ?>

</div>
<div id="wrapper">

<div id="top">

<div class="blogname">
<h1><a href="<?php bloginfo('siteurl');?>"><?php bloginfo('name');?></a></h1>
<h2><?php bloginfo('description'); ?></h2>
</div>



<?php include (TEMPLATEPATH '/topad.php'); ?>

</div>



<div id="foxmenucontainer">

<?php include (TEMPLATEPATH '/searchform.php'); ?>
<?php wp_nav_menu( array( 'container_id' => 'menu''theme_location' => 'secondary','fallback_cb'=> '' ) ); ?>

</div>

<div id="casing">



Obrigado desde já! :)
Offline

Riey 
Membro
Mensagens 1001 Gostos 0
Feedback +4

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

Era melhor teres colocado logo o código...
Offline

Tomé Mendes 
Membro
Mensagens 92 Gostos 0
Feedback +1

Troféus totais: 26
Trófeus: (Ver todos)
Level 5 Tenth year Anniversary Nineth year Anniversary Windows User Super Combination Combination Topic Starter Level 4 Level 3 Level 2

Era melhor teres colocado logo o código...

EDIT feito! :)
Offline

Tomé Mendes 
Membro
Mensagens 92 Gostos 0
Feedback +1

Troféus totais: 26
Trófeus: (Ver todos)
Level 5 Tenth year Anniversary Nineth year Anniversary Windows User Super Combination Combination Topic Starter Level 4 Level 3 Level 2

Sugestões? :D
Offline

GhostMaster 
Membro
Mensagens 1374 Gostos 0
Feedback +10

Troféus totais: 26
Trófeus: (Ver todos)
Super Combination Combination Topic Starter Poll Voter Level 5 Level 4 Level 3 Level 2 Level 1 1000 Posts

Pelo que eu vi, nao tens nada de mais no codigo, mas os mais entendidos que se pronunciem.