2 Divs are not showing when I upload to a server, but they show ok on my localhost(wampp). Can anyone offer assistance on why this may be? The divs in question are'footer' and 'poster'

html

<body>
   <div class="wrapper">
      <?php include '../inc/header.php';?>
       <div id="info">
         <div id="what">
               <span class="h1">WHAT IS IT?</span>
         </div>
         <?php 
           include '../inc/connect.php';
           $data = mysql_query("SELECT info FROM mainhomepagecontent")
           or die(mysql_error());          
           while($info = mysql_fetch_array( $data )) {
              echo "<span class='text'>";
              echo nl2br($info['info']);
              echo "</span>";
           } 
         ?> 
         </div>       
        <?php include '../inc/poster.php';?>
        <?php include '../inc/footer.php';?>
   </div>
   </body>

poster.php

<?php
   $poster ='<div class="poster">';
   $poster .='<div class="posterfixed">';
   $poster .='<div class="eighteenlogo">';
   $poster .= '<img src="../images/siteimages/18logo.png" />';
   $poster .= '</div>';
   $poster .='<div id="wherewhen">';
   $poster .='<div id="when">';
   $poster .='<span class="h2">WHEN IS IT?</span><br /> <span class="text2">9TH/10TH FEBUARY 2014</span>';
   $poster .='</div>';
   $poster .='<div id="where">';
   $poster .='<span class="h2">WHERE IS IT?</span><br /> <span class="text2">Holiday Inn (EAST)<br />
                                                                             London Rd<br />
                                                                             Newport Pagnell<br />
                                                                             Milton Keynes<br /> MK16 0JA</span>';
    $poster .='</div>';
    $poster .='</div>';
    $poster .='</div>';
    $poster .='</div>';

   echo $poster;
?>

footer.php

<?php
   $footer = "<div class='footer'>";
   $footer .= "<div class='wsd'>";
   $footer .= "Site Developed by Webslinger Development";
   $footer .= "</div>";
   $footer .= "<div class='ngcopyright'>";
   $footer .= "All Rights Reserved 2013 &copy Needle Gangsta's ";
   $footer .= "</div>";
   $footer .= "</div>";


   echo $footer;
?>

css file

html, body{
   margin:0; 
   padding:0;
   width:100%;
   height:100%;
   overflow:auto;
   background:#000000;
}

.header{
   float:left;
   margin:15px 0 0 0;
   width:280px;
   min-height:382px;
}

.headerfixed{
   position:fixed;
   width:280px;
   min-height:382px;
   background-image:url(../images/siteimages/logo.png);
   background-repeat:no-repeat;

}

.wrapper{
   width:1280px;
   position:relative;
   border-left:1px solid #ffffff;
   border-right:1px solid #ffffff;
   margin: 0 auto 0 auto;
   background:#000000;
   overflow:hidden;
}

/*sets the left side div*/
.poster{
   position:absolute;
   top:20px;
   right:0;
   width:390px;
   min-height:512px;

}

.posterfixed{
   position:fixed;
   width:390px;
   min-height:512px;
   background-image:url(../images/siteimages/background.png);

}

.eighteenlogo{
   position:absolute;
   right:10px;
   top:450px;
 }



/*sets the footer*/
.footer{
   float:left;
   min-width:1280px;
   overflow:hidden;
}

.wsd{
   float:right;
   font-size:.7em;
   margin-left:1em;
   color:#ffffff;
}


.ngcopyright{
   float:left;
   font-size:.7em;
   margin-left:1em;
   color:#ffffff;
}

#wherewhen{
   width:200px;
   position:absolute;
   left:5px;
   top:430px;
   text-shadow: 1px 1px #fc0808;

}

#expoinfo{
   width:300px;
   line-height:30px;
   position:absolute;
   left:5px;
   top:430px;
   text-shadow: 1px 1px #f3fc08;

}

#where{
   text-align:center;
}

#when{
   text-align:center;
}

#what{
   width:400px;
   text-align:center;
   margin:0 auto 0 auto;
}

#info{
   width:580px;
   background:red;
   min-height:700px;
   margin:20px 20px 0 295px;
   text-shadow: 2px -2px #000000;
   word-wrap:break-word;
}

Can anyone help me out on this? It's really frustrating me now!

Thanks

Recommended Answers

All 6 Replies

Any one got any ideas at all on this?......................

Member Avatar for iamthwee

If they don't show at all sounds like a file path issue.

But every other div has css in the same file, and also the 2 unshown divs show ok locally!

Member Avatar for iamthwee

I don't have the facility to test this, but given the symptoms I can only see two issues.

  1. It's a file path issue on the live server. You've placed poster.php and footer.php in the wrong folder or the files are corrupt or their names are wrong.

  2. A .htaccess file is doing something funky on the live server. But this would seem unlikely as you say it is reading header.php OK.

The css has little to do with the problem I would have thought... The only thing I could think of is if your css sets the xy position to be way off the page so you can't see it. But if it is EXACTLY the same as your local server I doubt this is the problem. Can only go on what you tell us.

Member Avatar for iamthwee

Actually, it could be your db username and password for the live server might be different.
Have you checked this first? Does the query $data = mysql_query("SELECT info FROM mainhomepagecontent") return data?

Is the parent file also called something.php or is it something.htm ? Needs to be the former, not the latter.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.