Find and Replace HTML Macro

G

Greg

For any one who can help me, I would greatly appreciate it. In the past I've
only built macros using recorders, the more mindless method, so I have
limited experience with writing them from scrath. Anyway...

I would like to develop a macro that removes all style and class attributes
as well as all font and span tags. I was driving myself nuts last night
trying to figure it out.

If any one has any suggestions, please don't hesitate to post a reply. Thank
you!!
 
S

Steve Easton

You don't need one, it's built into FrontPage.

In design view, click Edit > Select All and then click Format > Remove
Formatting


--
Steve Easton
Microsoft MVP FrontPage
95isalive
This site is best viewed............
........................with a computer
 
G

Greg

The goal is to clean the code even further. When working with MS Office
documents saved as web pages there are still styles and classes remaining.
There are the lingering classes such as MsoNormal and embedded styles such as:

style="mso-element:frame;mso-element-frame-width:432.05pt;mso-element-frame-height:
15.25pt;mso-element-wrap:no-wrap-beside;mso-element-left:95.85pt;mso-element-top:
121.6pt;mso-height-rule:exactly"

The advanced find and replace method allows for classes and stytles to be
removed within any given tag. I was hoping to automate this query within a
macro.
 
S

Stefan B Rusynko

See http://grahamwideman.com/gw/tech/html/htmltagclean/index.htm

--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


| The goal is to clean the code even further. When working with MS Office
| documents saved as web pages there are still styles and classes remaining.
| There are the lingering classes such as MsoNormal and embedded styles such as:
|
| style="mso-element:frame;mso-element-frame-width:432.05pt;mso-element-frame-height:
| 15.25pt;mso-element-wrap:no-wrap-beside;mso-element-left:95.85pt;mso-element-top:
| 121.6pt;mso-height-rule:exactly"
|
| The advanced find and replace method allows for classes and stytles to be
| removed within any given tag. I was hoping to automate this query within a
| macro.
|
| "Steve Easton" wrote:
|
| > You don't need one, it's built into FrontPage.
| >
| > In design view, click Edit > Select All and then click Format > Remove
| > Formatting
| >
| >
| > --
| > Steve Easton
| > Microsoft MVP FrontPage
| > 95isalive
| > This site is best viewed............
| > ........................with a computer
| >
| >
| >
| > | > > For any one who can help me, I would greatly appreciate it. In the past
| > > I've
| > > only built macros using recorders, the more mindless method, so I have
| > > limited experience with writing them from scrath. Anyway...
| > >
| > > I would like to develop a macro that removes all style and class
| > > attributes
| > > as well as all font and span tags. I was driving myself nuts last night
| > > trying to figure it out.
| > >
| > > If any one has any suggestions, please don't hesitate to post a reply.
| > > Thank
| > > you!!
| >
| >
| >
 
R

Rob Giordano \(Crash\)

ah that looks cool...thanks for the link!



| See http://grahamwideman.com/gw/tech/html/htmltagclean/index.htm
|
| --
|
| _____________________________________________
| SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
| "Warning - Using the F1 Key will not break anything!" (-;
| To find the best Newsgroup for FrontPage support see:
| http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
| _____________________________________________
|
|
|| The goal is to clean the code even further. When working with MS Office
|| documents saved as web pages there are still styles and classes
remaining.
|| There are the lingering classes such as MsoNormal and embedded styles
such as:
||
||
style="mso-element:frame;mso-element-frame-width:432.05pt;mso-element-frame-height:
||
15.25pt;mso-element-wrap:no-wrap-beside;mso-element-left:95.85pt;mso-element-top:
|| 121.6pt;mso-height-rule:exactly"
||
|| The advanced find and replace method allows for classes and stytles to be
|| removed within any given tag. I was hoping to automate this query within
a
|| macro.
||
|| "Steve Easton" wrote:
||
|| > You don't need one, it's built into FrontPage.
|| >
|| > In design view, click Edit > Select All and then click Format > Remove
|| > Formatting
|| >
|| >
|| > --
|| > Steve Easton
|| > Microsoft MVP FrontPage
|| > 95isalive
|| > This site is best viewed............
|| > ........................with a computer
|| >
|| >
|| >
|| > || > > For any one who can help me, I would greatly appreciate it. In the
past
|| > > I've
|| > > only built macros using recorders, the more mindless method, so I
have
|| > > limited experience with writing them from scrath. Anyway...
|| > >
|| > > I would like to develop a macro that removes all style and class
|| > > attributes
|| > > as well as all font and span tags. I was driving myself nuts last
night
|| > > trying to figure it out.
|| > >
|| > > If any one has any suggestions, please don't hesitate to post a
reply.
|| > > Thank
|| > > you!!
|| >
|| >
|| >
|
|
 
G

Greg

Thank you very much for the link!! This will help considerably! I thought I
reached the end of the Internet searching for something like this. :) Html
Filter 2.0 used to work really well until it was no longer compatible with FP
2003. Anyway, thanks again!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top