ADOdb

Database Abstraction Layer for PHP

User Tools

Site Tools


v5:reference:connection:param

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revisionBoth sides next revision
v5:reference:connection:param [2020/01/25 00:30] – [Usage] full section rewrite with cleaner layout and more realistic example. dregadv5:reference:connection:param [2020/01/25 00:31] – [Usage] split long line dregad
Line 22: Line 22:
  
 <code php> <code php>
-$sql1 = 'SELECT * FROM accounts WHERE name = ' . $db->param('account') . ' AND total = ' . $db->param('amount');+$sql1 = 'SELECT * FROM accounts WHERE name = ' . $db->param('account' 
 +    . ' AND total = ' . $db->param('amount');
 $db->param(false); $db->param(false);
 $sql2 = 'SELECT * FROM accounts WHERE id = ' . $db->param('id'); $sql2 = 'SELECT * FROM accounts WHERE id = ' . $db->param('id');
v5/reference/connection/param.txt · Last modified: 2021/02/26 01:35 by dregad