salve, vorrei impostare il mio sfondo in modo che si adatti a qualsiasi risoluzione. Ho costruito il mio template con artisteer, e uso wordpress per gestire il mio sito...nn ho molta conoscenza sul campo dell'informatica...Finora ho provato a modificare il css e l'html seguendo le istruzioni di alcuni siti ma niente(lo sfondo rimane bianco). Vi lascio i codici sperando mi possiate dare una mano
![]()
CSS:
body
{
margin:0;
padding:0;
width:100%;
height:100%;
overflow:hidden;
}
#background
{
position:absolute;
width:100%;
height:100%;
}
header.php (wordpress):
<!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') ?>" />
<title><?php wp_title( '|', true, 'right' ); bloginfo( 'name' ); ?></title>
<link rel="stylesheet" href="<?php bloginfo('stylesheet_url') ?>" type="text/css" media="screen" />
<?php if(WP_VERSION < 3.0): ?>
<link rel="alternate" type="application/rss+xml" title="<?php printf(__('%s RSS Feed', THEME_NS), get_bloginfo('name')); ?>" href="<?php bloginfo('rss2_url'); ?>" />
<link rel="alternate" type="application/atom+xml" title="<?php printf(__('%s Atom Feed', THEME_NS), get_bloginfo('name')); ?>" href="<?php bloginfo('atom_url'); ?>" />
<?php endif; ?>
<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />
<?php
remove_action('wp_head', 'wp_generator');
wp_enqueue_script('jquery');
if ( is_singular() && get_option( 'thread_comments' ) ) {
wp_enqueue_script( 'comment-reply' );
}
wp_head(); ?>
<script type="text/javascript" src="<?php bloginfo('template_url'); ?>/script.js"></script>
<script src="fixedbackground.js" type="text/javascript"></script>
</head>
<body>
<div>
[img]sfondo.jpg[/img]
</div>
<div id="art-main">
<div class="cleared reset-box"></div>
<div class="art-header"
<div class="art-header-wrapper">
<div class="art-header-inner">
<div class="art-headerobject" onclick="location.href='http://www.*****.com/';" style="cursor: pointer;"></div>
<div class="art-logo"
</div>
</div>
</div>
</div>
<div class="cleared reset-box"></div>
<div class="art-nav">
<div class="art-nav-l"></div>
<div class="art-nav-r"></div>
<div class="art-nav-outer">
<div class="art-nav-wrapper">
<div class="art-nav-inner">
<?php
echo theme_get_menu(array(
'source' => theme_get_option('theme_menu_source'),
'depth' => theme_get_option('theme_menu_depth'),
'menu' => 'primary-menu',
'class' => 'art-hmenu'
)
);
?>
</div>
</div>
</div>
</div>
<div class="cleared reset-box"></div>
<div class="art-sheet">
<div class="art-sheet-body">

...Finora ho provato a modificare il css e l'html seguendo le istruzioni di alcuni siti ma niente(lo sfondo rimane bianco). Vi lascio i codici sperando mi possiate dare una mano
Rispondi quotando