Forums

  • # October 18, 2012 at 4:06 pm

    I am still using good ol’ mysql in order to access databases. It’s served me well, and I can use it pretty well without issue.

    I know it’s depreciated so I should be moving on, so I read up about PDO and mysqli.
    [PDO DB Access Tutorial](http://net.tutsplus.com/tutorials/php/php-database-access-are-you-doing-it-correctly/ “PDO DB Access Tutorial”)

    It stresses prepared statements. This brings me to my question:
    I use HTMLPurifier, so what does preparing statements do that I will benefit from? Can I dump HTMLPurifier?

    Thanks for any guidance!

    # October 24, 2012 at 12:21 pm

    That’s a very good question. I tend to open the connection right before I begin my first query, then close it after the last one. I figured opening a new connection for each operation would increase server processes, but I’ve never actually verified if that would be the case.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.

icon-anchoricon-closeicon-emailicon-linkicon-logo-staricon-menuicon-nav-guideicon-searchicon-staricon-tag