-
-
/**
- php数据流应用
- date:2013/2/19
- */
- $count = 5;
- start:
- if($count echo "Put Password: ";
- $handle = fopen ("php://stdin","r");
- $line = fgets($handle);
- if(trim($line) != '123456'){
- $count--;
- if(!$count) goto error;
- goto start;
- }
- goto success;
- error:
- echo "Please try after 1 hour! http://bbs.it-home.org";
- goto out;
- success:
- echo "Logined!";
- out:
- ?>
复制代码
效果图如下所示:
|