This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
en:create:php [09.01.2015 12:41] – admin | en:create:php [22.02.2017 10:26] – [Functions] aitorme.uni-saarland | ||
---|---|---|---|
Line 24: | Line 24: | ||
===== Functions ===== | ===== Functions ===== | ||
- | A comupter | + | A computer |
Commands in PHP are called functions. A function looks like this: | Commands in PHP are called functions. A function looks like this: | ||
Line 58: | Line 58: | ||
To use the output of this function (in this case the random number), we need to file it somewhere. To do so, most programming languages use variables. You can write anything into a variable. But at the beginning, no one will see this. | To use the output of this function (in this case the random number), we need to file it somewhere. To do so, most programming languages use variables. You can write anything into a variable. But at the beginning, no one will see this. | ||
- | In PHP, variables start wit a dollar-sign ($). The example | + | In PHP, variables start wit a dollar-sign ($). The example |
The equal sign (%%=%%) is an operator. In this case it makes sure, the output of the function | The equal sign (%%=%%) is an operator. In this case it makes sure, the output of the function |