Copy link to clipboard
Copied
Hi Adobe Forum,
Is there a simple way to insert a Background Image Into a Table, just the table, Not The Entire Document Window, Using DW CS4. I have been spinning my wheels trying to do it. All I can do is get the Background Image to fill up the entire document window, not just the table.
THanks,
Ken
1 Correct answer
In the following, adjust position and size of image as per your requirement
...
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Untitled Document</title>
<style>
body {
width: 85%;
margin: auto;
}
table {
width: 400px;
background: url(http://loremflickr.com/320/240);
}
</style>
</head>
<body>
<table>
<thead>
<tr>
<th>col</th>
<th>col</th>
<th>col</th>
<th>col</th>
</tr>
</thead>
<tbody>
<tr>
<td>row</td>
<td>row</td>
<td>row</td>
<td>row</td>
</tr>
<tr>
<td>row</td>
<td
Copy link to clipboard
Copied
In the following, adjust position and size of image as per your requirement
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Untitled Document</title>
<style>
body {
width: 85%;
margin: auto;
}
table {
width: 400px;
background: url(http://loremflickr.com/320/240);
}
</style>
</head>
<body>
<table>
<thead>
<tr>
<th>col</th>
<th>col</th>
<th>col</th>
<th>col</th>
</tr>
</thead>
<tbody>
<tr>
<td>row</td>
<td>row</td>
<td>row</td>
<td>row</td>
</tr>
<tr>
<td>row</td>
<td>row</td>
<td>row</td>
<td>row</td>
</tr>
<tr>
<td>row</td>
<td>row</td>
<td>row</td>
<td>row</td>
</tr>
<tr>
<td>row</td>
<td>row</td>
<td>row</td>
<td>row</td>
</tr>
<tr>
<td>row</td>
<td>row</td>
<td>row</td>
<td>row</td>
</tr>
</tbody>
</table>
</body>
</html>
Copy link to clipboard
Copied
I hope you're not using 20th century Tables for your page layout.
Tables are for tabular data like charts and spreadsheets only.
Use CSS to create layouts.

