Tag Archives: PHP

PHP is a server-side scripting language designed for web development but also used as a general-purpose programming language. PHP is now installed on more than 244 million websites and 2.1 million web servers.

maths symbols 2

Tutorials – Other Maths Operators in PHP

  Subtraction in PHP We’re not going to weigh things down by subjecting you to torrents of heavy Math! But you do need to know how to use the basic operators. First up is subtracting.         To add up using PHP variables, you did this: <?php $first_number = 10; $second_number = 20; […]

basic_maths

Tutorials – Addition in PHP

OK, let’s do some adding up. To add up in PHP, the plus symbol (+) is used. (If you still have the code open from the previous page, try changing the full stop to a plus symbol. Run the code, and see what happens.) To add up the contents of variables, you just separate each […]

puss

Tutorials – PHP Concatenation

You can join together direct text, and whatever is in your variable. The full stop (period or dot, to some) is used for this. Suppose you want to print out the following “My variable contains the value of 10”. In PHP, you can do it like this: <?php $first_number = 10; $direct_text = ‘My variable […]

OPTS31.feat_swat.target-280-75

Tutorials – More PHP Variable Practice

In the previous section, you started to work with variables. You outputted text to a page. In the next few sections, you’ll do some more work with variables, and learn how to do your sums with PHP. But now that you can print text to a page, let’s try some numbers. Start with the basic […]

Practice pinned on noticeboard

Tutorials – Some Practice with PHP Variables

In the previous section, you saw what variables are: storage areas to hold things like numbers and text. You tell PHP to remember these values because you want to do something with them. In this section, you’ll get some practice using variables. Off we go. Testing variables with PHP First, we’ll take a look at […]

3d-text

Tutorials – Putting Text into Variables in PHP

In the previous section, you saw how to put numbers into variables. But you can also put text into your variables. Suppose you want to know something about the coats you own. Are they Winter coats? Jackets? Summer coats? You decide to catalogue this, as well. You can put direct text into your variables. You […]

shoebox

Tutorials – PHP Variables

A variable is just a storage area. You put things into your storage areas (variables) so that you can use and manipulate them in your programmes. Things you’ll want to store are numbers and text. If you’re ok with the idea of variables, then you can move on. If not, think of them like this. […]

php

Tutorials – What is PHP?

PHP is probably the most popular scripting language on the web. It is used to enhance web pages. With PHP, you can do things like create username and password login pages, check details from a form, create forums, picture galleries, surveys, and a whole lot more. If you’ve come across a web page that ends […]

obama-inaugural-speech-tag-cloud1

Tutorials – How to Build a Better Tag Cloud in WordPress

Once you’ve defined a great set of tags for your WordPress posts (or pages), you’ll want to display a tag cloud from somewhere in your template. This is normally achieved using the wp_tag_cloud() or wp_generate_tag_cloud() functions which do the hard work for you: <a href=”http://www.mysite.com/tag/word” title=”1 topic” style=”font-size: 8pt;”>word</a> <a href=”http://www.mysite.com/tag/tag” title=”2 topics” style=”font-size: 14.3pt;”>tag</a> […]