An open API service indexing awesome lists of open source software.

https://github.com/codeadamca/php-output

A basic example of using echo to create output with PHP.
https://github.com/codeadamca/php-output

echo learning-code output php

Last synced: 11 months ago
JSON representation

A basic example of using echo to create output with PHP.

Awesome Lists containing this project

README

          

# A Basic Introduction to PHP and Output

A basic example of using `echo` to create output with PHP.

This tutorial will review how to use the PHP `echo` command to create output. Here is a basic sample of using `echo` to output a "Hello World" message:

```php
Hello World!';

?>
```

## Steps

1. Open up a new file and name it output.php.
2. Copy the content from sample.html and paste it into your new PHP file.
3. Convert the HTML code in between the `` and `` from HTML to PHP.
4. For example the first line of HTML in the `` tag is:

```html

PHP and Creating Output


```

After this line is converted to PHP it will be something like this:

```php
PHP and Creating Output';

?>
```

Hint: Convert each line of HTML to PHP one line at a time. Test your PHP after converting each line of code.

> Full tutorial URL:
> https://codeadam.ca/learning/php-output.html

***

## Repo Resources

* [Visual Studio Code](https://code.visualstudio.com/) or [Brackets](http://brackets.io/) (or any code editor)
* [Filezilla](https://filezilla-project.org/) (or any FTP program)