Copy link to clipboard
Copied
I want to delete multiple tags of both opening and closing tags.
For example, in the next tags,
<span class="b">text</span>
I want to delete both <span class="b"> and </span>
but text should not be deleted.
There are a lot of codes like
<span class="b">text</span>
<span class="b">happy</span>
<span class="b">time</span>
How can I delete not only <span class="b">, but also </span> but keep the
text
happy
time
? (in the example above)
Thank you for your help.
@tomoakin33355574 try using search in files (Ctrl Shift F) then in advanced mode
search for SPAN node
havin an attribut class equal to B
then in action of replacement choose
cleaning node
it will remove the node, but not the node text
(be sure to make a back up of your site, before dealing with large search and replace in files
Copy link to clipboard
Copied
You could use the Find and Replace option in Dreamweaver:
Find:
<span class="b">text</span>
Replace with:
text
Copy link to clipboard
Copied
Thank you.
But I want to delete all the
<span class="b"></span>
at the same time because 100 of the texts which uses
<span class="b"></span>
Copy link to clipboard
Copied
I think I need to do it manually for all. I appreciate your help a lot.
Copy link to clipboard
Copied
I mean at the same time. like using find and replace all. not manually. I use dreamweaver. I really appreciate your help.
Copy link to clipboard
Copied
Well just perform 'Find and Replace' 3 times 1 for each situation, DW will take care of all the instances it finds.
Find:
<span class="b">happy</span>
Replace with:
happy
Find:
<span class="b">time</span>
Replace with:
time
There may be an expression you can use to just find all instances of:
<span class="b"></span>
and replace it with nothing, lets see if anyone can help out with an expression.
Copy link to clipboard
Copied
There may be an expression you can use to just find all instances of:
<span class="b"></span>
and replace it with nothing, lets see if anyone can help out with an expression.
yes, exactly! this is what I wanted to find out. I thought the same thing with you and thought it should not be difficult. But so far, adobe support even does not know it, so this can be very challenging topic.
I just wanted to get rid of all the unnecessary tags which is accidentally added.
If we know this method, I think it helps a lot of blogers time, including me.
Copy link to clipboard
Copied
Have a look at https://superuser.com/questions/1515036/regex-select-a-particular-tag-from-a-text-and-replace-with-a...
Copy link to clipboard
Copied
Thank you very much for your help!
I will try the method you showed me!
Copy link to clipboard
Copied
@tomoakin33355574 try using search in files (Ctrl Shift F) then in advanced mode
search for SPAN node
havin an attribut class equal to B
then in action of replacement choose
cleaning node
it will remove the node, but not the node text
(be sure to make a back up of your site, before dealing with large search and replace in files
Copy link to clipboard
Copied
This is the absolute best solution and should be identified as such