public static String getTextBetweenNestedDelims( String originalText, String beginDelim, String endDelim )
	{
		StringBuffer sb = new StringBuffer( originalText.length() );
		// Check to see that both delimiters exist in the string
		if( (originalText.indexOf( beginDelim ) < 0) || (originalText.lastIndexOf( endDelim ) < 0) )
		{
			return "";
		}
		int begidx = originalText.indexOf( beginDelim ) + beginDelim.length();
		int endidx = originalText.lastIndexOf( endDelim );
		int holder = 0;
		if( begidx < endidx )
		{
			sb.append( originalText.substring( begidx, endidx ) );
		}
		else
		{
			while( (begidx > endidx) && (endidx > -1) )
			{
				holder = endidx;
				endidx = originalText.lastIndexOf( endDelim, holder + 1 );
			}
			if( (begidx < endidx) && (endidx > -1) )
			{
				sb.append( originalText.substring( begidx, endidx ) );
			}
		}
		return sb.toString();
	}