Im trying to compare words for equality, and the case [upper and lower] is irrelevant. However PHP does not seem to agree!
Onları karşılaştırma yaparken kelimelerin harf görmezden PHP zorlamak için nasıl Herhangi bir fikir?
Herhangi bir yardım mutluluk!
$arr_query_words = array( "hat","Cat","sAt","maT" );
// for each element in $arr_query_words -
for( $j= 0; $j < count( $arr_query_words ); $j++ ){
// Split the $query_string on "_" or "%" :
$story_body = str_replace( $arr_query_words[ $j ],
'<span style=" background-color:yellow; ">' . $arr_query_words[ $j ] . '</span>',
$story_body );
// --- This ONLY replaces where the case [upper or lower] is identical ->
}
Durum farklı olsa bile yerine yürütmek için bir yolu var mı??
Orijinal soru belirsizlik için özür dilemek.
Donal