1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How long does it take to learn PHP?

Discussion in 'PHP' started by thesickearth, Aug 4, 2012.

  1. GrandPlaton

    GrandPlaton Greenhorn

    Messages:
    6
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    13
    #61
    so as i see i need to know well C, C++ and etc. and everything be easy?!))
     
    GrandPlaton, Apr 1, 2014 IP
  2. techmentro

    techmentro Greenhorn

    Messages:
    1
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    11
    #62
    It depends on your programming and logical skills.If you are good in programming and logical skills, it will not take much time to learn PHP and even it takes less time to learn than other high level programming languages.Since most of the websites and applications are built in PHP so it will be good for you to learn PHP.
     
    techmentro, Apr 8, 2014 IP
  3. Asif Mallik

    Asif Mallik Greenhorn

    Messages:
    8
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    11
    #63
    Took me only three days.
     
    Asif Mallik, Apr 15, 2014 IP
  4. PoPSiCLe

    PoPSiCLe Illustrious Member

    Messages:
    4,623
    Likes Received:
    725
    Best Answers:
    152
    Trophy Points:
    470
    #64
    Which means you're either a prodigy (which I, sorry to say, doubt), or you're an idiot for making that statement. If it's the first one, good for you. If it's the second, not so good for either you nor the rest of us. You don't learn PHP in three days. You might learn how to put together something more or less working, but that's hardly the issue - anyone can do that. What takes time is to learn how to do it right! And that, unfortunately, takes more than 3 days.
     
    PoPSiCLe, Apr 15, 2014 IP
    ryan_uk and malky66 like this.
  5. malky66

    malky66 Acclaimed Member

    Messages:
    3,996
    Likes Received:
    2,248
    Best Answers:
    88
    Trophy Points:
    515
    #65
    PHP is an ever evolving language, you can never stop learning it and to say you have learnt it in 3 days is frankly complete and utter bollocks.
     
    malky66, Apr 15, 2014 IP
    ryan_uk likes this.
  6. iMarketingGuru

    iMarketingGuru Well-Known Member

    Messages:
    486
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    160
    #66
    I'd start with editing and modifying complex php scripts such as mediawiki, wordpress and others so then you get to learn php, html 5, css3 and then mysql and just get into it via the usual method of hacking the coding of the sites. AFTER this as well as during if you have time, build sites and take training in php, mysql and the LAMP structure. I'd then move into ajax and learning jquery as well as the web 2.0 and even web 3.0 tech like learning languages such as python followed by ruby and getting into the arena of R which is the basis of getting you past the starting languages into the advanced ones which are very math based (if you REALLY want to get into advanced areas, learn R and machine learning courses from MIT as well as on coursera)
     
    iMarketingGuru, Apr 17, 2014 IP
  7. cronik

    cronik Well-Known Member

    Messages:
    863
    Likes Received:
    93
    Best Answers:
    1
    Trophy Points:
    180
    #67
    Don't think it depends on your IQ nearly as much as it depends on the time and effort you're willing to put into learning PHP. Almost everyone is capable if they apply themselves and have the time to study.
     
    cronik, Aug 15, 2015 IP
  8. JEET

    JEET Notable Member

    Messages:
    3,825
    Likes Received:
    502
    Best Answers:
    19
    Trophy Points:
    265
    #68
    This is based on my personal experience. I started with PHP, and today I code in PHP, JAVA, and somewhat in C++ too.
    I started in 2004 (Dec) by making a wysiwyg website on freewebs.com
    Then at some point I wanted to control more than what their interface allowed. This is where I learnt HTML and little bit of CSS.
    When I had a html/css static website coded on my own, I wanted to add some functionality to it, which is when PHP came in.
    Then came the need to store user information, and MYSQL jumped in.
    All this had happened by 2005 April.
    So I guess I can say that to make something useful, you'd probably need 3-5 months.

    If you don't have any programming background, PHP is a good start because it is very forgiving.
    Additionally, you don't have to decide on variable types (int,char,bool,etc.), and not perform too much validations like you have to do in JAVA and C++.
    At the max, PHP will throw a NOTICE/WARNING" error, but the script will still work. It's not like JAVA where the program won't even compile.
    It's very frustrating when a small piece of code in JAVA won't compile for days. That normally doesn't happen with PHP.
    So starting with php is a very good choice, but on the other hand it spoils you!!!

    If you are going with php, here are a few things that might help you.
    First, stop and install a WAMP or XAMP server on your computer. That will make your life a lot easier.
    Now fire up your notepad. I prefer this because it doesn't bug me while I'm coding.
    You can get a free copy of Notepad+ if you want. It's much like notepad, but with a few more features. I'm still on notepad though.
    On WAMP, your code goes inside WWW folder.
    Make a file here: first.php
    Put in this code:

    <?php
    echo "Hello";
    ?>

    Save the file and go to:
    http:)//)localhost/first.php

    Remove the () signs from that URL. DP is not allowing the localhost URL so I added those signs.

    With that file in hand, try reading some php tutorials, apply the code in those examples in this code you have in first.php
    Don't just read the tutorials, instead think of something you want, like a contact form.
    Now try making one, using the code you find on those tutorial sites. That is probably the easiest way to learn php.

    With PHP, beware of a few security tips:

    1. Avoid using "include" function. Use require instead.
    2. If you want to store something in sessions or cookies, read about security for these first.

    When you start with MYSQL, then follow best practices for:
    1. SQL injection. Read some articles on this. There are many good ones.
    2. Validate your input data before sending a query, specially if the data is coming from a POST or GET request.
    3. Always use LIMIT.

    This should get you going.
    Good Luck!

    P.S. I'm still learning. It's not over yet...
     
    JEET, Aug 19, 2015 IP
  9. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,998
    Best Answers:
    253
    Trophy Points:
    515
    #69
    That goes with something another programmer told me 30 years ago, the day you stop learning is the day the rest of the world leaves you behind.

    'tis doubly so for any IT related topic. This is an industry where 3 years is obsolete and 5 years is the scrap heap; thinking you can simply learn something and "be done learning" is ridiculously flawed and short-sighted.

    I've been programming since 1977, I've been dealing with PHP since sometime around 2000... and it's ALWAYS changing. What was good acceptable practice 3 years ago is today's security vulnerabilities! Take the people who learned (and still vomit up) PHP 4.x and wonder why their error logs are overflowing when running their code on 5.x -- look at the fact that 6 is here and ready to go and go look at what's been changed, removed and added! Look at all the things added and removed for 5.1, 5.2, 5.3, 5.4, 5.5, 5.6

    Sometimes security holes get plugged requiring you to learn new ways of doing things (mysql_ vs. mysqli for example), new functionality is added in the process (PDO)... sometimes programming is made simpler (no longer having to say array and just going []) ... and sometimes something comes along that is a colossal step BACKWARDS or is just a really bad idea; learning as much as you can and WHY things exist can often help you recognize that last part.

    See HTML 5, or as I call it the bleeding edge of 1997 development practices and the antithesis of everything 4 STRICT was about -- it's not an improvement and I'm able to recognize that because I learned STRICT and bothered learning semantics -- MOST of the people who are embracing HTML 5 with open arms never learned that and were still basically sleazing out HTML 3.2 and slapping 4 tranny on it.

    But even if you disagree with it, LEARN IT. That's one thing of my distaste for 5 that really pisses off it's fanboys -- I bothered learning it and reading / comprehending the specification, so I know EXACTLY where to stick the knife and twist.

    Anywho, PHP is constantly having improvements and changes made to it -- EVERY version of the past decade has gotten rid of some functions while bringing in new ones.

    Learning enough PHP to build something useful? Depends on if you already have a programming background. If you know other programming languages I figure a week or two tops. A proper knowledge of HTML (WHICH YOU SHOULD LEARN BEFORE YOU EVEN THINK ABOUT TOUCHING PHP!!!) would decrease that time. SQL which you would likely want to use in one form or another shouldn't take long after that. If coming from other languages one of the biggest things to get past is going to be "PHP already has a function for that" on things most languages you have to "brute force" code.

    But if you have ZERO programming experience? Could be months, could be years, and you're going to stumble a LOT. All the outdated web rot

    ... but that's just learning enough to make something with it. Learning it completely? That's a never-ending struggle that I don't even think the people making it have even fully accomplished. In many ways that's PHP's biggest strength AND weakness.

    One should also keep in mind what PHP is for... to put it as simply as possible used PROPERLY PHP is glue; you use it to take a request from the user, pull together static information from files or dynamic information from databases, and glue it into your markup. (HTML). That's what it's FOR. While it can be used as a general purpose programming language the amount of "real programming" logic should be kept to a minimum since, well... it's painfully slow at that. (Not as slow or inefficient as disasters like RUBY, but it's still no prize pig).

    It's why you'll see major projects leverage all sorts of different languages for different parts of their sites. PHP as the glue and markup control, SQL for databases, JavaScript, Flash, Silverlight or Java client side, Python for anything going to hardware level, Ruby for... well Christmas only knows what... Java, C or even native assembler code where speed is the most important thing server-side and where that effort is actually worth the payback, etc, etc...

    Done best, it becomes a "right tool for the right job" scenario. That's a problem I see a lot of PHP developers face -- as PHP is their hammer; every problem they see is a nail -- Whilst one can drive a screw with a hammer (or as Uncle Red calls it, a flathead screwdriver), don't expect it to hold very well.
     
    deathshadow, Aug 20, 2015 IP
  10. joice33

    joice33 Banned

    Messages:
    44
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    36
    #70
    It's really depends on you. How much time you'll devote for it.
     
    joice33, Aug 20, 2015 IP
  11. tanvirahmedodesk

    tanvirahmedodesk Greenhorn

    Messages:
    3
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    21
    #71
    know , basically php program is not easy . it has lots of complexity . Many complex jobs are done using php. even which is very hard to understand .
    thanks
     
    tanvirahmedodesk, Sep 11, 2015 IP
  12. Maria Fernandez

    Maria Fernandez Greenhorn

    Messages:
    6
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    21
    #72
    If you alredy know another programming language, it will take you just some days. However, if it is your first language, it could take you some weeks.
     
    Maria Fernandez, Sep 12, 2015 IP
  13. phplduser

    phplduser Member

    Messages:
    297
    Likes Received:
    28
    Best Answers:
    0
    Trophy Points:
    43
    #73
    I did try this but when i started to get my head around it things changed, Maybe i'm just a very slow learner, I think it is just a continuous learning curve and how well things stick.

    J
     
    phplduser, Jun 28, 2017 IP
  14. NetStar

    NetStar Notable Member

    Messages:
    2,471
    Likes Received:
    541
    Best Answers:
    21
    Trophy Points:
    245
    #74
    He's not an idiot for saying that he learned PHP in 3 days. Perhaps in 3 days he learned everything he needs to know about programming in PHP. We all have different needs.. he never claimed to be a master in PHP.
     
    NetStar, Jun 28, 2017 IP
  15. Blank ™

    Blank ™ Well-Known Member

    Messages:
    223
    Likes Received:
    18
    Best Answers:
    6
    Trophy Points:
    110
    #75
    ¡Hola! Spanish, right? Have I learned Spanish? No. It is simply unacceptable to tell anyone you have learned something if it is only up to an extent of your own needs. Our washing machine broke the other day (last week) - I fixed it. Do I know how to fix washing machines? No. The same goes with any programming language.
     
    Blank ™, Jun 28, 2017 IP
  16. NetStar

    NetStar Notable Member

    Messages:
    2,471
    Likes Received:
    541
    Best Answers:
    21
    Trophy Points:
    245
    #76
    Poor example. If you spoke broken spanish or broken english but enough to communicate with people you would reply "Yes" to "Can you speak spanish/english?".

    My favorite programming language is Perl. It's also my first. I have officially been writing in Perl for 20 years. I can write anything and everything I need to write in Perl. I know Perl. However, I am not the best Perl programmer in the world. I also don't feel I know everything there is to know about Perl. But I write in Perl and I can do everything I need it to do. I definitely wouldn't say "I don't know Perl" after years of writing in it.
     
    NetStar, Jun 28, 2017 IP
    Blank ™ likes this.
  17. Blank ™

    Blank ™ Well-Known Member

    Messages:
    223
    Likes Received:
    18
    Best Answers:
    6
    Trophy Points:
    110
    #77
    Valid point. I've hard people saying similar things (learned this or that language in 3 days) and all I was able to do is laugh. You simply can't do that. Please bare in mind that learning something isn't about just saving something in your memory, but actually understanding it. It doesn't mean you need to understand everything, but the basics at least. PHP basics .. Um, no, W3Schools is not enough. Not even close.
     
    Blank ™, Jun 28, 2017 IP
  18. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,998
    Best Answers:
    253
    Trophy Points:
    515
    #78
    First off, fun bump of a two year old thread...

    Second:

    Whereas I'd sooner suck the business end of a high velocity chemical expansion lead projector than deal with PERL... It's like someone looked at C and went "this isn't anywhere NEAR cryptic enough"

    But I started out hand assembling RCA 1802 Machine Language, and my favorite programming language is a toss up between modern "Object Pascal" and ADA.... so what do I know?
     
    Last edited: Jun 28, 2017
    deathshadow, Jun 28, 2017 IP
    Blank ™ likes this.
  19. NetStar

    NetStar Notable Member

    Messages:
    2,471
    Likes Received:
    541
    Best Answers:
    21
    Trophy Points:
    245
    #79
    I can admit it's my favorite because it's what i've wrote so fluently in for years before checking out other languages. It isn't the most practical and I actually believe there are better languages than Perl. However, for a quick few lines of code to clean up text or do something on the server I'd go right to Perl. I wouldn't bother writing anything for the web with it.
     
    NetStar, Jul 3, 2017 IP
  20. (BN)Nolan

    (BN)Nolan Well-Known Member

    Messages:
    74
    Likes Received:
    8
    Best Answers:
    0
    Trophy Points:
    135
    #80
    I'm still learning everyday. I just started learning PHP again practically from the beginning. I've been messing around with it for years. But, my knowledge right now is pretty limited in the full scope of it.
     
    (BN)Nolan, Jul 26, 2017 IP