Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 30

Thread: Day 1 - Getting Started - Become PHP Expert in 30 days

  1. #11
    Join Date
    Sep 2003
    Posts
    3,040

    Default

    Quote Originally Posted by sherlyk View Post
    Day 1 PHP programming

    http://php.flashwebhost.com/sherly/indian.php

    Code:
    <?php
    
    echo "I am an Indian!";
    
    ?>

    Don't use closing tag for PHP only code.

    Code:
    <?php
    
    echo "I am an Indian!";
    This is fine.
    Become PHP Expert in 30 days
    FreeMarriage.com - Free Online Matrimonial
    FlashWebHost.com - Professional Web Hosting, Designing.

  2. #12
    Join Date
    Sep 2003
    Posts
    3,040

    Default

    Quote Originally Posted by image View Post
    Good wok, experiment with the code like that, make mistakes, fix it, you won;t forget.

    Can anyone tell how to fix the error in following code

    hello_2.php

    Code:
    <?php
    
    echo 'Ranan's new production - Andhar Nogori Choupot Raja';
    Become PHP Expert in 30 days
    FreeMarriage.com - Free Online Matrimonial
    FlashWebHost.com - Professional Web Hosting, Designing.

  3. #13
    Join Date
    Feb 2007
    Posts
    26,214

    Default

    http://php.flashwebhost.com/tom/hello_2.php

    Code:
    <?php
    
     echo "Ranan's new production - Andhar Nogori Choupot Raja";
    Last edited by image; 05-08-2014 at 11:09 AM.

  4. #14
    Join Date
    Sep 2003
    Posts
    3,040

    Default

    Quote Originally Posted by image View Post
    http://php.flashwebhost.com/tom/hello_2.php

    Code:
    <?php
    
     echo "Ranan's new production - Andhar Nogori Choupot Raja";
    That is one way. It is better use single quote for string when ever possible.

    Code:
    <?php
    
    echo 'Ranan\'s new production - Andhar Nogori Choupot Raja';
    Become PHP Expert in 30 days
    FreeMarriage.com - Free Online Matrimonial
    FlashWebHost.com - Professional Web Hosting, Designing.

  5. #15
    Join Date
    Oct 2003
    Location
    Kochi, Kerala, India
    Posts
    21,389

    Default

    Day 1 - Another post

    http://php.flashwebhost.com/vineesh/myoffice.php

    My Code:
    Code:
    <?php
    
    echo 'I am <b>Vineesh Mohan</b>. <br /> <br /> Working in <b><I>
    <a href="http://www.FlashWebHost.com">FlashWebHost.com</a></I></b> <br /> <br />
    My collegues are <br /><br /> 
    <b>Tom <br /> Sherly <br /> Annie <br /> Sibichan <br /> Suneesh <br /> Steephan <br /> Ramesh <br /> and Mini</b>';
    Is there any other way to insert line breaks in php ?

  6. #16
    Join Date
    Sep 2003
    Posts
    3,040

    Default

    PHP don't have line breaks. You have to use HTML <br>

    HTML 5, you don't need to close Tags like img, br. So just use <br> instead of <br />
    Become PHP Expert in 30 days
    FreeMarriage.com - Free Online Matrimonial
    FlashWebHost.com - Professional Web Hosting, Designing.

  7. #17
    Join Date
    Oct 2003
    Location
    Kochi, Kerala, India
    Posts
    21,389

    Default

    Ok, now my code is:

    Code:
    <?php
    echo 'I am <b>Vineesh Mohan</b>. <br> <br>
    Working in <b><I><a href="http://www.FlashWebHost.com">FlashWebHost.com</a></I></b> <br> <br>
    My collegues are <br><br> 
    <b>Tom <br> Sherly <br> Annie <br> Sibichan <br> Suneesh <br> Steephan <br> Ramesh <br> and Mini</b>';

  8. #18
    Join Date
    Nov 2009
    Posts
    76,596

    Default

    Day 1 - 2nd Post

    http://php.flashwebhost.com/sherly/animals.php

    Code:
    <?php
    
    echo 'Wild <b>Animals</b>. 
    Names are <br /><br /> 
    <b>Tiger <br /> Fox <br /> Elephant <br /> Rabbit <br /> Deer <br /> Wolf <br /> Cheetah <br /> and Horse </b>';


    Learning PHP


  9. #19
    Join Date
    Nov 2009
    Posts
    76,596

    Default

    Day 1- 3rd post

    http://php.flashwebhost.com/sherly/thanksprayer.php

    Code:
    <?php
    
    
    echo '<h1><b><center>Prayer</center></b></h1>' ;
    
    
    echo '<p>A prayer of thanks is something that every person should say everyday. Everyone has something that they are thankful for. Even if it is just getting out of bed every day. A simple prayer of thanks is: God of Love, I thank You for the people in my life who are easy to love. I thank You for my family and friends who understand my actions, who support me in my decisions, and whose presence can lift the burden of a thorny day. Help me with those who are difficult to love. Let me recognize their flaws and their dangers. But then let me remember your attitude toward them, and lead me to see them in the light of Your love. Amen.  </p>';

  10. #20
    Join Date
    Jan 2008
    Location
    india,kerala-god's own country
    Posts
    14,007

    Default

    Day 1 PHP programming

    http://php.flashwebhost.com/ramesh/1.php

    Code:
    <?php
    
    echo "hello i am ramesh now i am starting my php study";

Page 2 of 3 FirstFirst 123 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •