SitePoint Sponsor

User Tag List

Page 3 of 3 FirstFirst 123
Results 51 to 56 of 56
  1. #51
    SitePoint Guru momos's Avatar
    Join Date
    Apr 2004
    Location
    Belgium
    Posts
    920
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    eval gets my vote

  2. #52
    SitePoint Wizard stereofrog's Avatar
    Join Date
    Apr 2004
    Location
    germany
    Posts
    4,324
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    What's so bad about eval (except that it is "evil")?

  3. #53
    SitePoint Zealot
    Join Date
    Apr 2004
    Location
    RS, Brazil
    Posts
    128
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    eval is dangerous as hell! (eval, evil, hell... hum...)

  4. #54
    Accredited Master scotty2260's Avatar
    Join Date
    Apr 2004
    Location
    California
    Posts
    423
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Alright... I get this email from someone complaining that this script some other 'PHP coder' made him. He said it was laggy and didn't even work right.

    Note that this function was being used in the admin section to view all of his 3000+ members on one page.
    PHP Code:
    function get2()
    {
    include 
    "dbconn.php";
    $result mysql_query("SELECT username FROM members WHERE id=$id");
      
    $result2 mysql_query("SELECT firstname FROM members WHERE id=$id");
      
    $result3 mysql_query("SELECT lastname FROM members WHERE id=$id");
    echo 
    "$result - $result2 - $result3";

    Scott

  5. #55
    SitePoint Member
    Join Date
    Jun 2002
    Location
    Germany
    Posts
    13
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    That is awful...wouldn't it just print "resource #blah" or something? It's ridiculous. The code is so bad, it makes me laugh (that reminds of http://www.thedailywtf.com)
    ://phoop.net
    Home of the Papercut Template Engine - latest release 0.9.3alpha

  6. #56
    Non-Member coo_t2's Avatar
    Join Date
    Feb 2003
    Location
    Dog Street
    Posts
    1,819
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    Without eval I couldn't do this:

    eval (" $className::methodName();");


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
  •