...

View Full Version : layout correction



plasma
09-24-2004, 07:43 PM
Here is template page I use to display search results(perl script). Its display results inside a table. I just want correct a little page appearance: to reduce a little font size inside table itself; set page background color RGB #C0C0C0, and table background-color: white. Just not sure where correct this on a right place.
Also, not sure is this first line on right place?
<!-- "start template" -->
<template>




<html>
<head>
<title></title>
</head>
<body>
<font face="Verdana" size="2"><b>
Total number of records:</b> <<#_total>><b> Matching records:</b> <<#_matches>><br>
<br>
<!-- "start template" -->
<template>

<table border="1" cellpadding="1" cellspacing="0" width="100%">
<tr>
<td>Artist</font></td>
<td>Albums</font></td>
<td>Year</font></td>
<td>Size Mb</font></td>
<td>Mode</font></td>
<td>Kbps</font></td>
<td>Location</font></td>
<td>Time</font></td>
<td>Track</font></td>
<td>Style</font></td>
</tr>

<template>
<tr>
<td><<Artist>></td>
<td><<Albums>></td>
<td><<Year>></td>
<td><<Size Mb>></td>
<td><<Mode>></td>
<td><<Kbps>></td>
<td><<Location>></td>
<td><<Time>></td>
<td><<Track>></td>
<td><<Style>></td>
</tr>
</template>

</table>

<!-- "end template" -->
<b>
Total number of records:</b> <<#_total>> <b>Matching records:</b> <<#_matches>></font>
</body>
</html>

bradyj
09-24-2004, 09:05 PM
In the head of the document or in an external file:


body {
font-size: 12px;
background-color: #C0C0C0;
}
table {
background-color: white;
}


You can dump those font tags too you have in there and just do it via CSS, a good reference can be found at:
http://www.w3schools.org

:thumbsup:

Roy Sinclair
09-24-2004, 09:10 PM
Maybe this?:



<html>
<head>
<title></title>
<style type="text/css">
body td {font-family: Verdana; }
body {font-size: x-small; background-color: #C0C0C0; }
td {font-size: xx-small; background-color: #FFF;}
</style>
</head>
<body>
<!-- "start template" -->
<template>
<b>Total number of records:</b> <<#_total>><b> Matching records:</b> <<#_matches>>
<br>
<br>

<table border="1" cellpadding="1" cellspacing="0" width="100%">
<tr>
<td>Artist</font></td>
<td>Albums</font></td>
<td>Year</font></td>
<td>Size Mb</font></td>
<td>Mode</font></td>
<td>Kbps</font></td>
<td>Location</font></td>
<td>Time</font></td>
<td>Track</font></td>
<td>Style</font></td>
</tr>

<template>

<tr>
<td><<Artist>></td>
<td><<Albums>></td>
<td><<Year>></td>
<td><<Size Mb>></td>
<td><<Mode>></td>
<td><<Kbps>></td>
<td><<Location>></td>
<td><<Time>></td>
<td><<Track>></td>
<td><<Style>></td>
</tr>
</template>

</table>

<b>
Total number of records:</b> <<#_total>> <b>Matching records:</b> <<#_matches>></font>
</template>
<!-- "end template" -->
</body>
</html>

bradyj
09-24-2004, 09:30 PM
Is this something for databases I don't know about? Why are there closing font tags in the table cells :confused:

plasma
09-27-2004, 12:27 PM
Yes, that was ready template for perl database, its intended to display search result. I mean reduce a little font size inside table; top and footer fonts ( <font face="Verdana" size="2"> Total number of records ) was OK.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum