![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
PHP
zhz459880251
这个作者很懒,什么都没留下…
展开
-
Yii2 Activefrom表单部分组件
文本框:textInput(); 密码框:passwordInput(); 单选框:radio(),radioList(); 复选框:checkbox(),checkboxList(); 下拉框:dropDownList(); 隐藏域:hiddenInput(); 文本域:textarea(['rows'=>3]); 文件上传:fileInput(); 提交按钮:submitButton(); 重置转载 2015-12-20 12:04:46 · 2425 阅读 · 0 评论 -
PHP基础--数据类型
<?php //数据类型 /* * 字符串 * 整数 * 浮点型 * 逻辑 * 数组 * 对象 * NULL */ ?><?php //1. 字符串 //字符串可以是 引号内的任何文本, 可以使用单引号 或双引号 $br = "<br/>"; $str = "Hello World!"; echo $str . $br;$str = "O(∩_∩)O哈哈~"; echo $s原创 2015-12-04 00:34:33 · 244 阅读 · 0 评论 -
PHP基础--字符串操作和运算符
<?php //字符串操作 $string = "Hello World!";//1. strlen()函数 // 函数返回字符串的长度,以字符计 //strlen() 常用于循环和其他函数,在确定字符串何时结束很重要时。(例如,在循环中,我们也许需要在字符串的最后一个字符之后停止循环) echo strlen($string);//2. strpos()函数 //用于检索字原创 2015-12-04 11:58:58 · 397 阅读 · 0 评论 -
PHP--时区配置
如果不修改的话使用Date(“H-i-s”), 输出的时间会相差8个小时 修改时区选择: http://php.net/manual/en/timezones.asia.php原创 2015-12-22 15:16:48 · 392 阅读 · 0 评论 -
XAMPP安装(Apache+MySQL+PHP+PERL)
一直想学PHP, 但每次都因为其复杂的环境搭建望而止步, 最近在两位大神的帮助下终于搞定了, 分享安装过程及踩到的各种坑下载安装XAMPP官网: http://sourceforge.net/projects/xampp/files/ 我下的是XAMPP5.6.14-4版本下载完后解压按步骤安装即可, 这里我就遇到奇葩的坑了, 每次解压完安装时第一遍都会失去响应, 必须force quit安原创 2015-12-03 00:20:50 · 3103 阅读 · 0 评论 -
PHP基础--变量
<!DOCTYPE html> <html> <body><h1>我的第一张 php页面</h1><?php echo "Hello World";//php支持三种注释: //1. 单行 #2. 单行 /* * 3. 多行 */$color="red"; echo "<br/>My car is " . $color . "<br/>"; //echo "My house is " . $CO原创 2015-12-03 21:20:29 · 347 阅读 · 0 评论 -
PHP基础--分支语句和array操作
<!DOCTYPE html> <html> <body bgcolor="#f5f5dc"><?php //条件语句 和iOS用法 一样 $t = date("H"); if ($t < "20") { echo "现在时间: " . $t; } else { echo "大于20"; } ?><?php //switch 语句 //作用 和 iOS 用法一样 /* *原创 2015-12-04 16:12:07 · 402 阅读 · 0 评论 -
PHP基础--页面传值,输入验证
<!DOCTYPE html> <html> <body> <?php $name = $email = $gender = $comment = $website = ""; $nameErr = $emailErr = $genderErr = $websiteErr = "";if ($_SERVER['REQUEST_METHOD'] == "POST") { if(empty($_原创 2015-12-07 15:02:30 · 430 阅读 · 0 评论