Answers for "get string between two strings"

1

java find substring between two strings

StringUtils.substringBetween(str, "<%=", "%>");
Posted by: Guest on September-18-2020
0

string between two strings

// Gegasoft found this useful and use in helper class

function get_string_between($string, $start, $end){
    $string = ' ' . $string;
    $ini = strpos($string, $start);
    if ($ini == 0) return '';
    $ini += strlen($start);
    $len = strpos($string, $end, $ini) - $ini;
    return substr($string, $ini, $len);
}
Posted by: Guest on October-30-2020

Code answers related to "get string between two strings"

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language