下面的代码演示了php中的函数参数如何设置和使用默认值
/**
* php函数参数默认值的使用
*
* @param
* @arrange 512-笔记网: 512Pic.com
**/
function textonweb ($content,$fontsize=3){
echo <font SIZE=$fontsize>$content</font>;
}
textonweb (A <br />,7);
textonweb (AA.<br />);
textonweb (AAA. <br />);
textonweb (AAAA! <br />);
/*** 来自编程之家 jb51.cc(jb51.cc) ***/