Regex for hyperlinks in SDL Studio, json files
Thread poster: Claudia Infantes Villafranca

Claudia Infantes Villafranca  Identity Verified
Spain
Local time: 07:34
English to Spanish
+ ...
Dec 1, 2016

Hi all,

I am working with json files in Studio 2015, and given the amount of HTML codes etc found inside them I am defining tag definition rules in order to avoide them or define them as placeholders, etc. Generally speaking I am not having much problem with that.

However, when dealing with hyperlinks inside the files, I cannot handle them appropriately and no matter which Regex I use, Studio ignores my rules and extract the content of the Hyperlink resulting in a very ugly file and I guess resulting in a misguiding analysis, since it might take into account the content of the hyperlink.

The type of links are as follows:

Ich akzeptiere die "a class=\"PFX-link\" href=\"https://www.xx.de/xx/xx/nutzungsbedingungen/teilnahmebedingungen-gesundheitscoach/58965\" target=\"_blank\"" Teilnahmebedingungen für den XX-Coach""/a"

(there should be angular brackets at the beginning and end of the hyperlink, however if I use it, it is not properly shown in the body of the message)


In order to define the tag pair of the hyperlink I am using this regex tag pair:

"a class=.*\""

(it should beging and end with angular brackets)

"\/.*" or simply "/a"

(they should beging and end with angular brackets)

When I use this Regex to search for any hyperlink in a Notepad, it definitely searchs the first part of the hyperlink; however, when setting this rule in Studio it keeps on extracting the content of the hyperlink ignoring my order to handle it as Tag pair.

I guess I am doing something wrong with it, but I certainly don't know what else to do.
Below the settings I am using:

Tag type > Tag Pair
Regular Expression
Start Tag: a class=.*\"
End Tag: \/.*
Tag Properties
Translate> Translatable
Advanced> Segmentation hint> Include

Is there any other tag definition rule I can use in order to avoid the hyperlinks appearing in Studio when dealing with json files?

Thanks a lot in advance!


[Editado a las 2016-12-01 11:49 GMT]


 


To report site rules violations or get help, contact a site moderator:


You can also contact site staff by submitting a support request »

Regex for hyperlinks in SDL Studio, json files

Advanced search







memoQ translator pro
Kilgray's memoQ is the world's fastest developing integrated localization & translation environment rendering you more productive and efficient.

With our advanced file filters, unlimited language and advanced file support, memoQ translator pro has been designed for translators and reviewers who work on their own, with other translators or in team-based translation projects.

More info »
SDL MultiTerm 2017
Guarantee a unified, consistent and high-quality translation with terminology software by the industry leaders.

SDL MultiTerm 2017 allows translators to create one central location to store and manage multilingual terminology, and with SDL MultiTerm Extract 2017 you can automatically create term lists from your existing documentation to save time.

More info »



Forums
  • All of ProZ.com
  • Term search
  • Jobs
  • Forums
  • Multiple search