Changing Multiple HTML code in cell

ftpalliance

New Member
Joined
Aug 6, 2013
Messages
2
I have a large Spreadsheet of information that has HTML coded for my eCommerce website although some of the HTML tags are not allowed on the other eCommerce platform that I am merging into.For example: I have a description that is similar to this:
Code:
<h1>Ginsu 04817 International Traditions 14-Piece Knife Set with Block, Natural</h1>
<h3>Description:</h3>
Many associate Ginsu knives with the product’s kitschy infomercial from the ‘70s that begins with a karate kick to a watermelon and proceeds with a demo 
of these knives cutting through just about anything in the house. Like the original product, Ginsu’s International Traditions is designed for the home 
cook who is not attuned to the maintenance required of a more high-end knife. However, this line is an improvement on the original, offering the 
weight, balance, and style of a commercial-quality knife, while meeting current design trends and performance expectations.
<br><br>
This 14-piece set stocks a kitchen with most cutlery needs, and packs all knives in a contemporary black hardwood storage block. The set includes: an 
8-inch chef’s knife, an 8-inch slicer, a 7-inch santoku knife, a 5-1/2-inch boning knife, a 5-inch utility knife, a 3-1/2-inch paring knife, and six 4-
1/2-inch steak knives, plus a pair of shears.
<br><br>
Ginsu blades are constructed from stainless steel and feature a two-dimensional serrated edge that is symmetrically cut on either side for more 
accurate slicing and for either right- or left-handed use. Edges are still as low-maintenance as ever and never require sharpening. The blades have 
full tangs that extend through lightweight bakelite handles and are triple-riveted for strength. Ginsu covers these International Traditions knives 
under a limited, lifetime warranty and recommends manual cleaning with hot, soapy water to keep them in top shape.
<br><br>
<b>What's in the Box</b><br><br>
3-1/2-inch paring knife, 5-inch utility knife, 5-1/2-inch boning knife, 7-inch santoku knife, 8-inch slicer, 8-inch chef’s knife, six 4-1/2-inch steak 
knives, shears, hardwood block<h3>Key Features:</h3><div><ul style=""><li>14-Piece Knife Set with Natural 
Wood Block</li><ul><li>Events are stored & forwarded to server when out of coverage</li></ul></ul>
The other merchant will not accept the following tags, therefore, I'd like to change it into the following:
Code:
<h1>  ---><b>   <h2>  ---><b>   <h3>  ---><b>    </h1>  ---></b>   </h2>  ---></b>   </h3>  ---></b>    <ul style="">    --->   <ul>   <div>    --->    <br>  </div> ---> <br>
I've already tried adapting the macro from this other post - but honestly, I'm not too familiar with editing VB. (http://www.mrexcel.com/forum/excel-questions/405460-removing-html-code-excel-cell.html)I'm sure it's fairly minor to make these changes from the macro from the above post... this is the one that gets rid of ALL HTML.
Code:
Sub RemoveTags()Dim r As RangeSelection.NumberFormat = "@"  'set cells to text numberformatWith CreateObject("vbscript.regexp")  .Pattern = "\<.*?\>"  .Global = True  For Each r In Selection    r.Value = .Replace(r.Value, "")  Next rEnd WithEnd Sub
Any ideas? Thanks again for your help in advance.​
 
Last edited:

Excel Facts

Why are there 1,048,576 rows in Excel?
The Excel team increased the size of the grid in 2007. There are 2^20 rows and 2^14 columns for a total of 17 billion cells.
Sorry if this is a bit too confusing, this is my first time posting on this forum. Please let me know if there is a better place / way to ask my questions.

Thanks!
 
Upvote 0

Forum statistics

Threads
1,215,695
Messages
6,126,263
Members
449,307
Latest member
Andile

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top