public static String appendImageUrl(String imageUrl,String suffix){
  if (TextUtils.isEmpty(imageUrl)) {
    return "";
  }
  if (TextUtils.isEmpty(suffix)) {
    return imageUrl;
  }
  int dot=imageUrl.lastIndexOf('.');
  if (dot == -1) {
    return imageUrl + suffix;
  }
 else {
    return imageUrl.substring(0,dot) + suffix + imageUrl.substring(dot,imageUrl.length());
  }
}

public static String appendImageUrl ( String imageUrl , String suffix ) { if ( TextUtils . isEmpty ( imageUrl ) ) { return "" ; } if ( TextUtils . isEmpty ( suffix ) ) { return imageUrl ; } int dot = imageUrl . lastIndexOf ( '.' ) ; if ( dot == - 1 ) { return imageUrl + suffix ; } else { return imageUrl . substring ( 0 , dot ) + suffix + imageUrl . substring ( dot , imageUrl . length ( ) ) ; } }
append a suffix to an image url . assumes the url has no suffix ( but may have an extension or not .
