Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
ファイルを検索して、"foo" が前にない "bar" のすべてのインスタンスを見つけたいと考えています (前の空白とその後のすべてを無視します)。
だから私たちが持っているなら
foo foo bar baz bar a bunch of monkeys
1行目と4行目だけを返します
否定後読みを使用します。パターンは次のようになります。
(?<!foo )bar
「ファイルを検索する」が何を意味するかは、あなた次第です。行ごとに読む?
IE9 のバグを修正するために、「DOCTYPE」宣言をページの上部に配置する必要がありました。
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <?php require_once 'navBar.php';