0

これらのコードを書き直すのを手伝ってください:

if (eregi($asked,$accepted)) {
 $this->plot_type = $which_pt;
 return true;
} else {
 $this->DrawError('$which_pt not an acceptable plot type');
 return false;
}

Google から入手したすべての修正を試しましたが、修正できませんでした。

ありがとう。

4

1 に答える 1

0
if ( preg_match($asked."i",$accepted) ) // there is no case insensitive version of preg_match
{
    $this->plot_type = $which_pt;
    return true;
} else {
    $this->DrawError("$which_pt not an acceptable plot type"); // i think you want " instead of ' here
    return false;
}

するべきです。そうでない場合は、 の正規表現の内容をお知らせください$asked

于 2010-07-16T16:16:20.410 に答える