SitePoint Sponsor

User Tag List

Results 1 to 8 of 8

Thread: PHPLib

  1. #1
    SitePoint Addict isuru's Avatar
    Join Date
    Nov 2000
    Posts
    206
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I am creating my own forum (for learning purpose) in PHP/MySQL and I was wondering whether I should use the built-in mysql_connect etc. functions or use PHPLib.

    I was talking to a friend and he said that PHPLib wasn't very good

  2. #2
    Dumb PHP codin' cat
    Join Date
    Aug 2000
    Location
    San Diego, CA
    Posts
    5,460
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Did he give a reason? I use it in nearly every one of my scripts and to tell you the truth I really like it it takes so much of the work out of it for you. I mean would you rather do this

    $db = new DB;
    $db->query("SELECT * from tablename");
    while ($db->next_record()) {
    print $db->f(fieldname);
    }

    or

    $db = mysql_connect("host", "user", "pass");
    mysql_select_db("dbname", $db);
    $sql = "select * from tablename";
    $result = mysql_query($sql);
    while($row = mysql_fetch_array($result)) {
    print $row["fieldname"];
    }


    I choose the first, its object-oriented and cleaner.
    Please don't PM me with questions.
    Use the forums, that is what they are here for.

  3. #3
    SitePoint Addict isuru's Avatar
    Join Date
    Nov 2000
    Posts
    206
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    He said it was "junk" and "pretty junky".

    He also said that the class vBulletin uses (which is based on PHPLib) was much better.

  4. #4
    Dumb PHP codin' cat
    Join Date
    Aug 2000
    Location
    San Diego, CA
    Posts
    5,460
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hmmm... All he could say was it is "junk" without giving reasons why? Well I guess its up to you? I prefer like I said becasue it is object oriented and cleaner but you can do as you please. As far as vBulletin being junk, Did you know this site uses vBulletin, Do you think this site is "junk" I certianly don't
    Please don't PM me with questions.
    Use the forums, that is what they are here for.

  5. #5
    SitePoint Addict isuru's Avatar
    Join Date
    Nov 2000
    Posts
    206
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally posted by freddydoesphp
    Hmmm... All he could say was it is "junk" without giving reasons why? Well I guess its up to you? I prefer like I said becasue it is object oriented and cleaner but you can do as you please. As far as vBulletin being junk, Did you know this site uses vBulletin, Do you think this site is "junk" I certianly don't
    NO NO NO, you misunderstood me. What he said was the the vBulletin class was good. He said it was better than the PHPLib class.(because it has been modified)

    He did NOT say the class used by vBulletin was junk

  6. #6
    Dumb PHP codin' cat
    Join Date
    Aug 2000
    Location
    San Diego, CA
    Posts
    5,460
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I think you are confusing things. PHPLib has many classes, some are good and some aren't so good. The Session Class was good for PHP3 but is not really all that needed since PHP4 is out. The db class is the only one I use, and it is very handy. vBulletin is a class to run a forum such as this one. I am not sure if you are asking whther you should use vBulletin's class for interacting with your db? Again I cannot overemphasize that if you are gonna use classes to build your forum you should definetly use PHPLib or another object-oriented db class to handle your db interaction, believe me it will save you so much time.
    Please don't PM me with questions.
    Use the forums, that is what they are here for.

  7. #7
    SitePoint Addict isuru's Avatar
    Join Date
    Nov 2000
    Posts
    206
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    OK thanks for your help freddydoesphp, how long did it take you to learn php and what books/tutorials did you use?

  8. #8
    Dumb PHP codin' cat
    Join Date
    Aug 2000
    Location
    San Diego, CA
    Posts
    5,460
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I have been doing it for about 10 months now. I just started building stuff for the hell of it. I use a book from wrox press for awhile, but I grew out of it in a few months. I also look for posts in this forum to answer, if I don't know the answer I figure it out and test it, and then answer it, that helps me learn a lot.
    Please don't PM me with questions.
    Use the forums, that is what they are here for.


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
  •