1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

php vs python for bh apps

Discussion in 'PHP & Perl' started by aliskorn, Aug 9, 2009.

  1. aliskorn

    aliskorn Jr. VIP Jr. VIP Premium Member

    Joined:
    Apr 21, 2008
    Messages:
    484
    Likes Received:
    459
    Occupation:
    Psychologist & programmer
    What do guys think? I like python very much but php has curl which makes it so easy to build scrapers and account creators. Does python have something like that?
     
  2. orangejuice

    orangejuice Registered Member

    Joined:
    Jul 25, 2009
    Messages:
    54
    Likes Received:
    16
    In my opinion, PHP > Python due to it's portability. You can buy hosting for a cent that has full PHP/Curl support, but few that will support Python scripts. Also better manual (php.net), better examples and good community support :) The hosting point was simply that you can upload your scrapers to multiple hosting accounts, so more IPs.
     
    • Thanks Thanks x 1
  3. cyklotrial

    cyklotrial Regular Member

    Joined:
    Oct 13, 2008
    Messages:
    248
    Likes Received:
    82
    Location:
    Wonderland
    In Python you can use PyCurl.
     
    • Thanks Thanks x 1
  4. blackcat.private

    blackcat.private Newbie

    Joined:
    Apr 23, 2009
    Messages:
    18
    Likes Received:
    0
    Just prefer python, so much powerfull....BUT I just started perl, and it's overpowered too, and many more packages than python.
     
  5. stargazerrrrr

    stargazerrrrr Newbie

    Joined:
    Nov 18, 2010
    Messages:
    3
    Likes Received:
    0
    Python is better better due to it's short code. It also forces you to write a better code. It has a huge amount of packeges that are well-coded and it's faster than php :)
     
  6. savvypro

    savvypro Regular Member

    Joined:
    Jan 14, 2010
    Messages:
    211
    Likes Received:
    133
    I've seen a lot of PHP guys go on about curl, giving the impression that it's only available in PHP. But in reality it's a language independent library written in C.

    Oh and the curl website, has the following in the "1.3 What is curl not?" FAQ section:

    I do agree that there are less hosts that support Python out of the box. But that's where a VPS comes into play, it's always better to have greater control of the environment then being a guest.
     
  7. MaDeuce

    MaDeuce Newbie

    Joined:
    Oct 24, 2008
    Messages:
    45
    Likes Received:
    16
    Location:
    Austin, TX
    +1 for python and pycurl. And add in a dose of BeautifulSoup.

    I'm not trying to start a religious war, but python is designed from the ground up to be a cohesive and extremely well thought-out language (from the 'formal languages' perspective). Python was OO from the outset, although using that paradigm isn't required.

    Keep in mind that PHP is not a general purpose programming language -- it is designed for web scripting. It's simply not as powerful, or as well suited for general purpose programming, as perl, python, C, etc... It is, however, wonderfully suited for web programming.

    As far as debugging environments go, Python's is far superior. Python's support for testing, especially automated regression testing, blows away PHP as well.

    If I were designing large-scale systems that have to be maintained (and this is exactly what I do), I'd choose Python. I can't imagine developing anything with even moderate complexity with PHP, although people do it all the time.

    As is usually the case with languages, there is no right answer.

    --Ma
     
  8. Ornani

    Ornani Newbie

    Joined:
    Dec 12, 2010
    Messages:
    13
    Likes Received:
    0
    PHP development is much faster.
     
  9. Autumn

    Autumn Elite Member

    Joined:
    Nov 18, 2010
    Messages:
    2,197
    Likes Received:
    3,041
    Occupation:
    I figure out ways to make money online and then au
    Location:
    Spamville
    The right language is the one that you know the best. Python is technically superior and comes with a much more comprehensive, thoroughly tested standard library for doing all kinds of cool stuff. However there are way more PHP developers out there, so if you're going to be getting other people to modify the code, PHP could be the way to go.
     
  10. nipester

    nipester Regular Member

    Joined:
    Feb 1, 2009
    Messages:
    256
    Likes Received:
    28
    Python forces you to write better code? No I don't think so. From what I've seen in tutorials python is a very forgiving language with syntax so if anything it would encourage you to write sloppy code compared to something like C which demands tight coding due to it's strict syntax.

    But having said that I'm aware of the good reputation python has and it's used by a lot of people doing reverse engineering and very much preferred by people who can write their own code very fast for things like scraping and sys admin. Not trying to bash python here but what you said contradicts what I've seen in basic tutorials.
     
  11. roachZ

    roachZ Newbie

    Joined:
    Jun 22, 2009
    Messages:
    14
    Likes Received:
    73
    Occupation:
    Developer
    Location:
    The Netherlands
    PHP Is far way the best portable language there is currently out there. But hey; its all by the user standard, so decide for yourself ;-)
     
  12. puremagic

    puremagic Junior Member Premium Member

    Joined:
    Sep 26, 2010
    Messages:
    110
    Likes Received:
    24
    If i have to choose one of them , then I will definitely go with php as you can get lots of library in php and you will get lots of people to help in various forums too
     
  13. headliner

    headliner Registered Member

    Joined:
    Oct 2, 2009
    Messages:
    51
    Likes Received:
    5
    Hmm... Whatever happened to pick the right tool for the job?

    -HL