html issue

Discussion in 'Software' started by PeterK2003, Sep 18, 2006.

  1. PeterK2003

    PeterK2003 Private E-2

    ok if you look at this page:

    http://krumkast2.krum.name:8080/test/top.html

    In IE6/7 it functions as i want it to.
    But if you look at it in firefox i get a green bar at the top.(b/c the image isn't all the way at the top like i want it)

    Any ideas?

    There might be an entirely different way to do this which would be better--feel free to tell me that i am stupid.
     
  2. matt.chugg

    matt.chugg MajorGeek

    Firefox renders CSS differently to IE.

    How about this:

    Code:
    <html>
    	<head>
    		<title>Some Title</title>	
    	
    		<style type="text/css">
    			body {background-color:#2FA17F; margin:0px 0px 0px 0px;}
    			imgbanner {width:100%; height:187; margin:0px 0px 0px 0px; padding:0px 0px 0px 0px;}
    		</style>
    	</head>
    
    	<body>
    		<img class="imgbanner" src="[i][color=red]http://krumkast2.krum.name:8080/test/[/color][/i]images/summer-bright-sunset.jpg">
    	</body>
    </html>
    
    You don't really need the red bit
     
  3. PeterK2003

    PeterK2003 Private E-2

    well that got rid of the bar at the top but i want the image to scale to the size of the window if someone knows how to get it to do that i think your solution would work i think.

    I posted your code here:
    http://krumkast2.krum.name:8080/test/top--temp.html

    thanks,
    ~Peter
     
  4. matt.chugg

    matt.chugg MajorGeek

    Hm the css should have done that, change width:100%; to width="100%" and move it to the image tag as below and try again

    Code:
    <html>
    	<head>
    		<title>Some Title</title>	
    	
    		<style type="text/css">
    			body {background-color:#2FA17F; margin:0px 0px 0px 0px;}
    			imgbanner {height:187; margin:0px 0px 0px 0px; padding:0px 0px 0px 0px;}
    		</style>
    	</head>
    
    	<body>
    		<img width="100%" class="imgbanner" src="[i][color=red]http://krumkast2.krum.name:8080/test/[/color][/i]images/summer-bright-sunset.jpg">
    	</body>
    </html>
    
     
  5. PeterK2003

    PeterK2003 Private E-2

    ok i got it. Here is what i did

    Code:
    <html>
    	<head>
    		<title></title>	
    	
    		<style type="text/css">
    			body {background-color:#2FA17F; margin:0px 0px 0px 0px;}
    			imgbanner {height:187; margin:0px 0px 0px 0px; padding:0px 0px 0px 0px;}
    		</style>
    	</head>
    
    	<body>
    		<div style="position: absolute; width: 100%; height: 100px; z-index: 1" id="layer1">
    			<p align="center"><font color="#cc6600" face="Arial Black" size="6">
    			<span style="text-decoration: none;">Krumkast.com V2.0 Powered By PHP</span></font></div>
    		<img width="100%" height="187" class="imgbanner" src="images/summer-bright-sunset.jpg">
    	</body>
    </html>
    
    i had to add the height="187" to the image tag but it does what i want it to do now.

    Thanks!
    ~Peter
     
  6. matt.chugg

    matt.chugg MajorGeek

    ahh I see my mistake, I missed out the unit in the imgbanner class, it should read height:187px;

    if you've added it to the tag you can remove it from the imgbanner class

    Glad you got it working
     

MajorGeeks.Com Menu

Downloads All In One Tweaks \ Android \ Anti-Malware \ Anti-Virus \ Appearance \ Backup \ Browsers \ CD\DVD\Blu-Ray \ Covert Ops \ Drive Utilities \ Drivers \ Graphics \ Internet Tools \ Multimedia \ Networking \ Office Tools \ PC Games \ System Tools \ Mac/Apple/Ipad Downloads

Other News: Top Downloads \ News (Tech) \ Off Base (Other Websites News) \ Way Off Base (Offbeat Stories and Pics)

Social: Facebook \ YouTube \ Twitter \ Tumblr \ Pintrest \ RSS Feeds