//--------------------------------------------------------------------------------- // getQuotedString function // 12/28/98 // http://www.blazonry.com/java/ // // returns the portion of 'str' inbetween two quotes // REGEXP would be something like "(.*)" // does not work with more than one set of quotes // // built for reading in ini file, NOT parsing HTML values // // returns string // //--------------------------------------------------------------------------------- public static String getQuotedString(String str) { String qStr = ""; int indx1 = str.indexOf("\"") + 1; int indx2 = str.indexOf("\"", indx1); if ((indx1 != 0) && (indx2 != -1)) { qStr = str.substring(indx1, indx2); } else { qStr = ""; } return qStr; }