Greetings, my ultimate goal is to compare the lines!

There is a variable with type

string $param = '<Delai dobro';

ATTENTION is worth the sign LESS.

So, I get such a string from a file in order to further compare strings (the entry of strings). And then the problem: the lines are not compared, and why?

When I started to print with echo, I found that there was no output, and when var_dump <Delai dobro

And I compare files, and look for an entry like this

 stripos($string_from_file1,$string_from_file2,24); 

thank

  • To display information to the user, use the function php.net/manual/ru/function.htmlspecialchars.php - Visman
  • what should it be compared with? What does “not compare” mean? show the code that does not work, and explain what should happen, and what happens instead ... but somehow it is not very clear ... - AlexandrX
  • and the output from echo - it is, only the browser perceives it as an incomprehensible tag and ignores ... ctrl-U will confirm) - AlexandrX
  • When outputting, one has to conceptually test characters like < - SkiesX

1 answer 1

the htmlcpecialchars function more than copes, i.e. no need for byte reads.