今天就学习课程吧!
今天就开通帐号,24,700 门业界名师课程任您挑!
What are variables?
- [Instructor] Printing information onto the screen is great but we don't always know exactly what information we'll need when we're writing our code. For example, if we want to print the visitor's name, there's no possible way of knowing that information before they visit. That's where variables come in. Variables are a way to store information in order to reference it later. Variables could be used to store names, numbers, and other important data. All PHP programs, including Wordpress, heavily use variables. All variables must start with a dollar sign followed by an alpha-numeric character string. Here's an example. We have the variable age written as $age, an equal sign, the number 34 and a semicolon. Age is a placeholder that we're using to store the number 34. PHP knows age is 34 because of the equal sign, which means is assigned or gets. I'll usually say gets when referring to variable assignments. We can…
随堂练习,边学边练
下载课堂讲义。学练结合,紧跟进度,轻松巩固知识。
内容
-
-
-
What is PHP?2 分钟 1 秒
-
(已锁定)
Printing information3 分钟 15 秒
-
(已锁定)
What are variables?6 分钟
-
(已锁定)
Strings in PHP5 分钟 57 秒
-
(已锁定)
Using arrays7 分钟 59 秒
-
(已锁定)
Arithmetic operators and math in PHP4 分钟 38 秒
-
(已锁定)
Challenge: Perform a mathematic operation and store it1 分钟 14 秒
-
(已锁定)
Solution: Perform a mathematic operation and store it3 分钟 33 秒
-
-
-
-
-