Show block in particular nodes having some string in title
Try:

if (strpos($url, 'myword') !== FALSE) {
  $match = TRUE;
}


strpos() returns the zero-based index of the first occurrence of the substring. 

So if "myword" is at the start of the URI string strpos() will return 0, and since 0 == FALSE in terms of a conditional, it will fail.

I've just tested your code and it works fine with the slight change.