$fsize = filesize($filename);
echo "21kb";
echo "21kb";
2020-06-11
class Car {
private $s = 0;
function getS() {
return $this->s;
}
protected function sUp() {
$this->s += 10;
echo $this->getS();
}
function start()
{
$this->sUp();
}
}
$car = new Car();
$car->start();
?>
這樣也是對的 只不過驗(yàn)證 start()需要public
private $s = 0;
function getS() {
return $this->s;
}
protected function sUp() {
$this->s += 10;
echo $this->getS();
}
function start()
{
$this->sUp();
}
}
$car = new Car();
$car->start();
?>
這樣也是對的 只不過驗(yàn)證 start()需要public
2020-06-11
1.感覺就像是講了一元一次函數(shù)樣子是其中包含一個(gè)x
2.舉的例子是怎么求解x的過程
3.然后是把求根公式給你讓你解方程
可能是我基礎(chǔ)太差,給我的體驗(yàn)就像123條
2.舉的例子是怎么求解x的過程
3.然后是把求根公式給你讓你解方程
可能是我基礎(chǔ)太差,給我的體驗(yàn)就像123條
2020-02-16
$fruit = array("蘋果","香蕉","菠蘿");
print_r($fruit);
print_r($fruit);
2020-01-14
$str = '主要有以下幾個(gè)文件:index.php, style.css, common.js';
$p = '/\w+\.\w+/i';
$str = preg_replace($p, '<em>$0</em>', $str);
echo $str;
echo "<br />";
$str = preg_replace($p, '&lt;em&gt;$0&lt;/em&gt;', $str);
echo $str;
echo "<br />";
$p = '/\w+\.\w+/i';
$str = preg_replace($p, '<em>$0</em>', $str);
echo $str;
echo "<br />";
$str = preg_replace($p, '&lt;em&gt;$0&lt;/em&gt;', $str);
echo $str;
echo "<br />";
2020-01-04
服務(wù)器上沒有數(shù)據(jù),執(zhí)行下面就可以成功下一步了
$row = mysql_fetch_array($result);
if (empty($row)) {
echo '<pre>';
print_r(array());
echo '</pre>';
} else {
echo '<pre>';
print_r($row);
echo '</pre>';
}
$row = mysql_fetch_array($result);
if (empty($row)) {
echo '<pre>';
print_r(array());
echo '</pre>';
} else {
echo '<pre>';
print_r($row);
echo '</pre>';
}
2019-12-17
$pattern ='/(\w+.\w+)/';
$replacement = '<em>$1</em>';
$str1 = preg_replace($pattern,$replacement, $str);
echo $str1;
$replacement = '<em>$1</em>';
$str1 = preg_replace($pattern,$replacement, $str);
echo $str1;
2019-10-30