Deleting certain parts of a multilingual XML file
Questions about XML that are not covered by the other forums should go here.
-
- Posts: 2
- Joined: Wed Feb 17, 2016 4:07 pm
Deleting certain parts of a multilingual XML file
Post by BartJanssen »
Hello all,
I'm fairly new to Oxygen, and I've been fiddling around now.
I'm working on a multilingual XML file, which contains Dutch, French, German and English.
I need to extract the French, German and English strings from the file, so only the Dutch remains.
What I'm looking for, is some kind of 'wildcard' search to find any text between a couple of tags.
They look like this:
<text_eng>Step 2: Check and approve resend</text_eng>
Basically, I wish to find all occurrences of <text_eng>...</text_eng> and delete those.
How do I prepare the wildcard search for this?
Thanks, any help is more than welcome!
Bart
I'm fairly new to Oxygen, and I've been fiddling around now.
I'm working on a multilingual XML file, which contains Dutch, French, German and English.
I need to extract the French, German and English strings from the file, so only the Dutch remains.
What I'm looking for, is some kind of 'wildcard' search to find any text between a couple of tags.
They look like this:
<text_eng>Step 2: Check and approve resend</text_eng>
Basically, I wish to find all occurrences of <text_eng>...</text_eng> and delete those.
How do I prepare the wildcard search for this?
Thanks, any help is more than welcome!
Bart
-
- Posts: 2879
- Joined: Tue May 17, 2005 4:01 pm
Re: Deleting certain parts of a multilingual XML file
Hello,
If you prefer the text search, you can make use of regular expressions for wildcards in the Find/Replace dialog (Find > Find/Replace).
Find: <text_eng>.*?</text_eng>
Replace with: <leave empty>
Options [x]Regular expression
If you want to also remove line breaks and indents (whitespaces) add \s+ at the beginning of the find expression (before the start tag).
Regards,
Adrian
If you prefer the text search, you can make use of regular expressions for wildcards in the Find/Replace dialog (Find > Find/Replace).
Find: <text_eng>.*?</text_eng>
Replace with: <leave empty>
Options [x]Regular expression
If you want to also remove line breaks and indents (whitespaces) add \s+ at the beginning of the find expression (before the start tag).
Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
-
- Posts: 2
- Joined: Wed Feb 17, 2016 4:07 pm
Re: Deleting certain parts of a multilingual XML file
Post by BartJanssen »
Hello Adrian,
Works like a charm, thank you SO much!
Bart
Works like a charm, thank you SO much!
Bart
adrian wrote:Hello,
If you prefer the text search, you can make use of regular expressions for wildcards in the Find/Replace dialog (Find > Find/Replace).
Find: <text_eng>.*?</text_eng>
Replace with: <leave empty>
Options [x]Regular expression
If you want to also remove line breaks and indents (whitespaces) add \s+ at the beginning of the find expression (before the start tag).
Regards,
Adrian
Return to “General XML Questions”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service