Java - Removing the double quotes in XML attributes
问题 I have an xml string which I get via a REST call. However, some of the attributes have corrupted values. For example: <property name="foo" value="Some corrupted String because of "something" like that"/> How can I replace double-quotes either not preceded by value= or not follown by /> with a single quote and get a valid XML string out of that corrupted one in Java 6? EDIT: I have tried to modify this lookahead/lookbehind regex that was used for VisualBasic. But because of the incompatibility