Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 01-28-2013, 04:26 PM   PM User | #1
benjbear
New to the CF scene

 
Join Date: Jan 2013
Posts: 6
Thanks: 2
Thanked 0 Times in 0 Posts
benjbear is an unknown quantity at this point
Scrolling and Image problem

Hello all,

I am making a website (exogenese.altervista.org)and I have got 2 problems:

1) As you can see the picture on the index page is far to big, and it doesn't auto re-size, any ideas?

2) I have to scroll right when I am on my main pages, when I would like the text to be in the center of the page...

Any help would be appreciated, thanks in advance, Ben

Last edited by vinyl-junkie; 01-29-2013 at 04:14 AM.. Reason: Edited so the URL would show up in the post
benjbear is offline   Reply With Quote
Old 01-29-2013, 04:37 PM   PM User | #2
sunfighter
Senior Coder

 
Join Date: Jan 2011
Location: Missouri
Posts: 2,382
Thanks: 18
Thanked 350 Times in 349 Posts
sunfighter is on a distinguished road
This is for problem 1)
You can reposition the container div to suite your tastes. You should have a doctype in all pages. Your image has a slight border that should be removed:
Code:
<!DOCTYPE html>
<html>
<head>
<title>index</title>
<base href="http://exogenese.altervista.org">
<style>
body
{
	margin: 0px;
	padding: 0px;
//JUST TO SHOW YOU WHERE THINGS ARE REMOVE COMMENTS FOR FINAL
	//background-color: #000;
}
#container
{
	position:relative;
	width: 960px;
	margin: auto;
}
#lang
{
	position:absolute;
	top: 250px;
	left: 730px;
}
</style>
</head>

<body>
<div id="container" >
<img src="images/bg0.jpg" width="960px"><!--  THE SAME AS YOUR CONTAINER WIDTH   -->

<div id="lang">
<img src="images/fr.gif" alt="drapeau 1" width=200px height=100px><br>
<img src="images/uk.jpg" alt="drapeau 2" width=200px height=100px>
</div>
</div>
</body>
</html>
For problem 2: set the width to something smaller in the css file:
Code:
.c {
  width: 1500px ;  // TRY 960PX AND GO FROM THERE
  margin-left: auto ;
  margin-right: auto ;
}

Last edited by sunfighter; 01-29-2013 at 04:49 PM..
sunfighter is online now   Reply With Quote
Users who have thanked sunfighter for this post:
benjbear (02-02-2013)
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 06:25 PM.


Advertisement
Log in to turn off these ads.