Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialKwame Gyau
Courses Plus Student 402 PointsWordPress database query functions help
Which functions are used to query a database in WordPress?
I mean the equivalents of mysqli_query(), mysqli_fetch_assoc() etc in native PHP.
4 Answers
Andrew McCormick
17,730 Pointsyou use the wpdb() class.. see here WordPress codex on databases
Kwame Gyau
Courses Plus Student 402 PointsMany thanks, Andrew.
Andrew McCormick
17,730 Pointsno problem. Spend more than 5minutes in Wordpress development and the codex will become your best friend
Kwame Gyau
Courses Plus Student 402 PointsBy the way, is there a way to search for native php functions equivalents in WordPress from Codex? The equivalents of trim, mysql_real_escape_string etc