Text not centrered on guestbook

Dr. GBooky is here to help you with your guestbook problems ...
Post Reply
clubamigos99
Posts: 62
Joined: Mon Feb 20, 2006 4:20 pm

Text not centrered on guestbook

Post by clubamigos99 »

Script URL: http://www.club-amigos.co.uk/guestbook/gbook.php
Version of script: latest
Version of PHP: 4
Hosting company:
Have you searched THIS FORUM for your problem:
(if not please do before posting)
If so, what terms did you try:

Write your message below:

For some odd reason the text is not centered on the guestbook.
It appears to be aligned to the right and not centered as per the example guestbook.
Henrie
Posts: 1095
Joined: Sun Aug 14, 2005 8:57 pm

Post by Henrie »

Hello, clubamigos99

As far as I could see you have edited the gbook.php file and removed the headers in it which contained the link to the style.css which contains the most part of the gbook styles. Now only the parts which are hardcoded in the gbook.php file are used.
This leads to difference in displaying of the page in different browsers. For example in Internet Explorer entries are centered in the table cells and in Firefox the entries are left aligned in the table cells.
So you should create a link to the style.css file for GBook, or import the settings in your own css file.

Hope this helps you.

Greetings,
Henrie
clubamigos99
Posts: 62
Joined: Mon Feb 20, 2006 4:20 pm

Post by clubamigos99 »

[quote="Henrie"]Hello, clubamigos99

As far as I could see you have edited the gbook.php file and removed the headers in it which contained the link to the style.css which contains the most part of the gbook styles. Now only the parts which are hardcoded in the gbook.php file are used.
This leads to difference in displaying of the page in different browsers. For example in Internet Explorer entries are centered in the table cells and in Firefox the entries are left aligned in the table cells.
So you should create a link to the style.css file for GBook, or import the settings in your own css file.

Hope this helps you.
=======================
Hello,

I am not to sure as to how to do this , please can you explain to me.
The reason l edited gbook.php was that it was aligning the guestbook to the left.
Henrie
Posts: 1095
Joined: Sun Aug 14, 2005 8:57 pm

Post by Henrie »

Hello clubamigos99,

I guess you have added your own code in the header.txt file.
To add the Gbook styles add this

Code: Select all

<link href="http://club-amigos.co.uk/guestbook/style.css" rel="stylesheet" type="text/css" />
below the link to the stylesheet already in use <link href="http://club-amigos.co.uk/amigos_style.css" rel="stylesheet" type="text/css" />

To not interfere with your current styles you should edit the style.css file.
Delete the code marked red. I have also added orange marked code which can be changed as desired to change colors. Change the px sizes to your desired sizes (but i think the defaults are good).
BODY, TD {
color : black;
font-family : Verdana, Geneva, Arial, Helvetica, sans-serif;
font-size: 11px;
}


TD.upper {
color : #FFFFFF;
background : #23559C;
font-family : Verdana, Geneva, Arial, Helvetica, sans-serif;
font-size: 11px;
}

FONT.smaller {
font-size: 10px;
}

table.entries {
color : black;
font-family : Verdana, Geneva, Arial, Helvetica, sans-serif;
font-size: 11px;
BORDER-RIGHT: #23559C 1px solid;
BORDER-LEFT: #23559C 1px solid;
BORDER-TOP: #23559C 1px solid;
BORDER-BOTTOM: #23559C 1px solid;
}

A {
color : #0084BE;
text-decoration : underline;
}


A:HOVER {
color : Red;
text-decoration : none;
}


A.smaller {
font-size: 10px;
color : #0084BE;
text-decoration : underline;
}


A.smaller:HOVER {
font-size: 10px;
color : Red;
text-decoration : none;
}


INPUT {
font-size: 11px;
font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
color:#000000;
background-color:#FFFFFF;
}

HR {
color: #B8CFE7;
height: 1px;
}

I hope this is clear enough.

You should also edit the links to your pages in the header.txt file. Now the links don't work.
For example, change <a href="index.htm">Home</a> to <a href="../index.htm">Home</a> or <a href="http://club-amigos.co.uk/index.htm">Home</a>

Greetings,
Henrie
clubamigos99
Posts: 62
Joined: Mon Feb 20, 2006 4:20 pm

Post by clubamigos99 »

I tried this and no luck, it still aligns to the right.

http://www.club-amigos.co.uk/guestbook/gbook.php

These are the files l am using:

style.css
=====

TD.upper {
color : #FFFFFF;
background : #23559C;
font-size: 11px;
}

FONT.smaller {
font-size: 10px;
}

table.entries {
color : black;
font-size: 11px;
BORDER-RIGHT: #23559C 1px solid;
BORDER-LEFT: #23559C 1px solid;
BORDER-TOP: #23559C 1px solid;
BORDER-BOTTOM: #23559C 1px solid;
}


INPUT {
font-size: 11px;
font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
color:#000000;
background-color:#FFFFFF;
}

HR {
color: #B8CFE7;
height: 1px;
}

font.ip {
color : Gray;
font-family : Verdana, Geneva, Arial, Helvetica, sans-serif;
font-size: 9px;
}


header.txt
=======
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<title>Useful links</title>
<meta name="keywords" content="social clubs southampton,clubs southampton,single events hampshire,new friends hampshire,new friends southampton,looking new friends,meeting new people,social clubs south coast,looking friendship uk,social clubs UK">
<meta name="description" content="A social club for people to go out enjoy themselves and try new activites">
<meta name="robots" content="index,follow">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link href="http://club-amigos.co.uk/amigos_style.css" rel="stylesheet" type="text/css" />
<div id="wrapper">
<div id="header"></div>
<div id="navcontainer">
<ul>
<li> <a href="index.htm">Home</a> </li>
<li> <a href="faq.htm">FAQ's</a> </li>
<li> <a href="links.htm">Links</a> </li>
<li> <a href="feb.html">Calendar</a></li>
<li> <a href="http://www.club-amigos.co.uk/mboard/mbo ... um</a></li>
<li> <a href="http://www.club-amigos.co.uk/guestbook/ ... ok</a></li>
<li> <a href="contact.html" id="last">Contact</A>
</ul>
</div>
<div id="content">
<div id="rightcol">
</div>
<h1>Guestbook</h1>

footer.txt
=======
<div id="footer">x</div>

</div>
</div>
</div>
clubamigos99
Posts: 62
Joined: Mon Feb 20, 2006 4:20 pm

Post by clubamigos99 »

clubamigos99 wrote:I tried this and no luck, it still aligns to the right.

http://www.club-amigos.co.uk/guestbook/gbook.php

These are the files l am using:

style.css
=====

TD.upper {
color : #FFFFFF;
background : #23559C;
font-size: 11px;
}

FONT.smaller {
font-size: 10px;
}

table.entries {
color : black;
font-size: 11px;
BORDER-RIGHT: #23559C 1px solid;
BORDER-LEFT: #23559C 1px solid;
BORDER-TOP: #23559C 1px solid;
BORDER-BOTTOM: #23559C 1px solid;
}


INPUT {
font-size: 11px;
font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
color:#000000;
background-color:#FFFFFF;
}

HR {
color: #B8CFE7;
height: 1px;
}

font.ip {
color : Gray;
font-family : Verdana, Geneva, Arial, Helvetica, sans-serif;
font-size: 9px;
}


header.txt
=======
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<title>Useful links</title>
<meta name="keywords" content="social clubs southampton,clubs southampton,single events hampshire,new friends hampshire,new friends southampton,looking new friends,meeting new people,social clubs south coast,looking friendship uk,social clubs UK">
<meta name="description" content="A social club for people to go out enjoy themselves and try new activites">
<meta name="robots" content="index,follow">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link href="http://club-amigos.co.uk/amigos_style.css" rel="stylesheet" type="text/css" />
<div id="wrapper">
<div id="header"></div>
<div id="navcontainer">
<ul>
<li> <a href="index.htm">Home</a> </li>
<li> <a href="faq.htm">FAQ's</a> </li>
<li> <a href="links.htm">Links</a> </li>
<li> <a href="feb.html">Calendar</a></li>
<li> <a href="http://www.club-amigos.co.uk/mboard/mbo ... um</a></li>
<li> <a href="http://www.club-amigos.co.uk/guestbook/ ... ok</a></li>
<li> <a href="contact.html" id="last">Contact</A>
</ul>
</div>
<div id="content">
<div id="rightcol">
</div>
<h1>Guestbook</h1>

footer.txt
=======
<div id="footer">x</div>

</div>
</div>
</div>

THIS WORKS I FORGOT TO PUT THE CSS STYLE IN , SORRY.
PLEASE CAN YOU CLOSE THIS THREAD.
Post Reply