Title: Problem with header
Last modified: August 19, 2016

---

# Problem with header

 *  [montsemarnaucom](https://wordpress.org/support/users/montsemarnaucom/)
 * (@montsemarnaucom)
 * [16 years, 6 months ago](https://wordpress.org/support/topic/problem-with-header-2/)
 * Hello, may anyone help me with some code problems?
 * I want to move an image from my stylesheet to my header.php file, but I don’t
   know exactly where to put it. I tried different positions but it always wrecks
   my layout.
 * The page is [here](http://www.marnau.com/blog)
 * Stylesheet.css
 *     ```
       /*** Main ***/
   
       	.main { /*width:expression(((document.documentElement.clientWidth || document.body.clientWidth) < 980)? "960px" : "100%"); min-width:980px;*/}
   
       	.main {}
   
       	.main-width { width:1014px; margin:0 auto;}
   
       	.main-bg { background:url(images/bg.gif) repeat-y 0 0;}
   
       	.header { height:255px;  background:url(images/header.jpg) no-repeat 26px 81px;}
       ```
   
 * Header.php
 *     ```
       </head><body>
       <div class="main">
       <div class="main-width"><div class="main-bg">
       <div class="header">
       <div class="menu-bg">
       <div class="corner-left"><div class="corner-right">
       <div class="search">
       <div class="indent">
       <?php get_search_form(); ?>
       </div>
       </div>
       <?php
       wp_page_menu('show_home=0&sort_column=menu_order, post_title&link_before=&link_after=');
       ?>
       </div>
       </div>
       </div>
       ```
   

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [rademem](https://wordpress.org/support/users/rademem/)
 * (@rademem)
 * [16 years, 6 months ago](https://wordpress.org/support/topic/problem-with-header-2/#post-1222218)
 * they are different files…
 * php files hold infos like which image where to be and functions etc..
 * css shape ur style like width, color of font background etc….
 * there are no mean to move image name etc to php files from css
 * if u explain better , we can help u
 *  Thread Starter [montsemarnaucom](https://wordpress.org/support/users/montsemarnaucom/)
 * (@montsemarnaucom)
 * [16 years, 6 months ago](https://wordpress.org/support/topic/problem-with-header-2/#post-1222222)
 * by other words
 * i want to take this background image `background:url(images/header.jpg)` from
   the css to the php so i can make it linkable
 *  [miocene22](https://wordpress.org/support/users/miocene22/)
 * (@miocene22)
 * [16 years, 6 months ago](https://wordpress.org/support/topic/problem-with-header-2/#post-1222239)
 * Within the <div id=”main-bg”> place an image tag with your desired image.
 * E.g.
 *     ```
       <div id="main-bg">
       <img src="http://imagelocation.png alt="alttxt"/>
       </div>
       ```
   
 * 1. use the entire path to the image e.g. [http://&#8230](http://&#8230);.. not
   a relative one as the one in the stylesheet is the location of the image relative
   to the stylesheet, not the page.
 * 2. If you want to link it just surround it in an `<a href=""></a>` tag
 * 3. You may also wish to define the size of the containing div in your css to 
   match that of your image. I.e. height: xx; width: xx;
 *  Thread Starter [montsemarnaucom](https://wordpress.org/support/users/montsemarnaucom/)
 * (@montsemarnaucom)
 * [16 years, 6 months ago](https://wordpress.org/support/topic/problem-with-header-2/#post-1222641)
 * thanks miocene, but still, when i put it within the <div id=”main-bg”>, the image
   appears above the menu. i want it to replace the actual image in the exact same
   place.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Problem with header’ is closed to new replies.

## Tags

 * [header](https://wordpress.org/support/topic-tag/header/)

 * 4 replies
 * 3 participants
 * Last reply from: [montsemarnaucom](https://wordpress.org/support/users/montsemarnaucom/)
 * Last activity: [16 years, 6 months ago](https://wordpress.org/support/topic/problem-with-header-2/#post-1222641)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
