Greetings, I've read some threads about this topic, but actually I was unable to find or to think of a adequate solution (see for example: http://stackoverflow.com/questions/121656/regular-expression-to-remove-xml-tags-and-their-content).
I have an xml tag like that:
<bla_tag size="100"
diameter="50"
ratio="0.2"
path="/user/home/something.pdf">
</bla_tag>
Aim: Having a regular expression that removes everything in between <bla_tag ...>
.
Problem: the values like size, etc. change in each of the bla_tags (about 1000 bla-tags in the file).
Failed attempt: I tried it with: <bla_tag .*?>
(the ? to make it less greedy...).
Result of failure: Only <bla_tag
has been marked, but not the content within the entire bracket!
What am I doing wrong - or is it actually possible to solve this problem based on regex (I read somewhere that it would not be possible due to xml property to be an type-2 language, can you confirm that?)
Thanks in advance and with best regards
Daniyal