Sinisterly
Step 1: Beginners Introduction - Printable Version

+- Sinisterly (https://sinister.ly)
+-- Forum: Coding (https://sinister.ly/Forum-Coding)
+--- Forum: Coding (https://sinister.ly/Forum-Coding--71)
+--- Thread: Step 1: Beginners Introduction (/Thread-Step-1-Beginners-Introduction)



Step 1: Beginners Introduction - iC0D3 - 04-30-2013

ChitChat N Code?


You heard it right. Welcome to step 1 of the very simplest PHP script.
I will explain the script, what it does, and why each line is written.

Step 1) We want to make a PHP file. Generally, "index.php" or "test.php"
Step 2) You will need some sort of web host, or local PHP such as XAMPP
Step 3) Create the file, make it 3 lines with the following:

PHP Code:
<?php ?>

Now considering the file is .php and your tags and opened, and you have a closing point - all thats left is our code inbetween. Below are two examples to help you get the idea.

PHP Code:
<?php echo 5 + 9; // This is a comment for coders to read, it will not be ran // As long as it begins with the two // ?>

PHP Code:
<?php $myForum = "ChitNChat"; $myName = "iC0D3"; echo "Hello, {$myName} is a member of {$myForum}"; ?>

For more tips and tricks read part 2 Smile


RE: Step 1: Beginners Introduction - Sirius - 04-30-2013

Can you give credits please?

Credits : iCOD3 and if other helped you type down.


RE: Step 1: Beginners Introduction - iC0D3 - 04-30-2013

I just wrote it specifically for CnC.
No credits necessary.


RE: Step 1: Beginners Introduction - Wonders - 04-30-2013

Nice thread/guide, thanks a lot for sharing this man Smile


RE: Step 1: Beginners Introduction - iC0D3 - 04-30-2013

Thanks for your reply. Typing part two now.. Explaining variables, and if checks.


RE: Step 1: Beginners Introduction - Zurchi - 04-30-2013

He doesn't need to give credits to himself haha.

Great job, its great to have you do this!


RE: Step 1: Beginners Introduction - Sirius - 04-30-2013

Great job anyways, thought anyone else helped you or something like that.
Good job Wink


RE: Step 1: Beginners Introduction - iC0D3 - 04-30-2013

Thanks! Thats as basic as it gets, so I can't say I had any assistance XD.


RE: Step 1: Beginners Introduction - Sirius - 04-30-2013

Good luck with the part 2 or step 2.