[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 148
  • Last Modified:

Removing contents off the tables

Helle everyone,
I need to remove tables from about 700 pages, in a batch. Here is the problem. To create a frame effect I had built two tables and then placed my images or text in em. Now if i remove the tables it takes the content away too. Is there any way to remove the template and then remove the 'titles and meta' from page and contents from within the tables and apply content to new template in a batch. I am pressing for time and can't strip them out pages by pages. Your assistance would be greatly appreciated. Here is the sample code:

<html>
<head>
<title>Times Trinidad Port of Spain</title>
<META Name="description" Content="Times">
<META Name="keywords" Content="Time Times Table">
</head>
<body><table width="100%" border="1" cellspacing="10" cellpadding="7" bgcolor="#AAAAAA" bordercolor="#000000">
<tr>
<td>
<table width="100%" border="1" cellspacing="0" cellpadding="0" bgcolor="#FFFFFF" bordercolor="#CCCCCC">
<tr>    
<td valign="top" width="646" bgcolor="#FFFFFF" bordercolor="#000000">
<p align="center"><img src="../../images/Times/TrinidadSpain.gif"
alt="Image is loading ............" name="Trinidad" width="720"
height="1751" id="Trinidad"></p>
</td>    
</tr>
<tr>
</tr>
</table>
</body>
</html>
0
tahirr
Asked:
tahirr
  • 2
  • 2
1 Solution
 
EsopoCommented:
Hi,

>>Is there any way to remove the template...<<
What template? Is this design based on a DW template? if so, it should be as easy as 1, 2, 3.

If you did not build your site based on a template, then it's easy too.

First of all back-up your files ;) (we don't want to click the wrong button and damage 700 pages)

Now, DreamWeaver allows you to Search & Replace code in the entire site.

Basically, what you want to do is hit - Ctrl + F - to open the Search dialog and so something like this:

**********************
FIND IN: Entire current local site (or selected folder, or selected files)

SEARCH: Source code

FIND:
<table width="100%" border="1" cellspacing="10" cellpadding="7" bgcolor="#AAAAAA" bordercolor="#000000">
<tr>
<td>
<table width="100%" border="1" cellspacing="0" cellpadding="0" bgcolor="#FFFFFF" bordercolor="#CCCCCC">
<tr>    
<td valign="top" width="646" bgcolor="#FFFFFF" bordercolor="#000000">


REPLACE:
<table width="100%" border="1" cellspacing="0" cellpadding="0" bgcolor="#FFFFFF" bordercolor="#CCCCCC">
<tr>    
<td valign="top" width="646" bgcolor="#FFFFFF" bordercolor="#000000">

click REPLACE ALL.
**********************

That search will look for the unique code of the table you want to remove and then replace it with similar code but without the first table.
That search will remove to upper code for the table, now you remove the lower part with a new similar search.

Make sure you check ALL your pages are ok after this. Chances are you might have to modify a few by hand.

Good luck,

Esopo.



0
 
tahirrAuthor Commented:
Hi Esop,

Thanks for the posting.
Yes they are attached to Dreamweaver template. But when I detach them from template they loose the link to that one tempalate but the coding remains intact. Know any way to remove the design of template to be removed too when I detach it? and how can I detach the whole site from template instead of doing one at a time.

Thanks.
Tahirr.
0
 
tahirrAuthor Commented:
Hi.

Thanks Esopo for intruducing me to that valuable search and replace feature in dreamweaver. I did not have to search and replace. All I did was that pasted the codes needed to be replaced and left the replace field empty. Cleaned out the whole site. Thanks again.

Tahirr.
0
 
EsopoCommented:
You are welcome! I'm glad it worked for you. I use Search & Replace all the time, it's very useful and powerful.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now