[support] Error when execute query
bharani kumar
bharanikumariyerphp at gmail.com
Sun Feb 14 17:45:35 UTC 2010
Hi i got error
recoverable fatal error: Object of class mysqli_result could not be
converted to string in
F:\wamp\www\vijaishopping\themes\garland\block.tpl.php on line 10.
Hi i tried custom module, it through the error ,
What i do now,
my snippet below
<?php
function alphabeticalsearch_block($op = 'list', $delta = 0, $edit =
array()){
if($op == "list") {
$block = array();
$block[0]["info"] = t('Alphabetical Search');
return $block;
}
elseif($op == 'view'){
$alphabetical_search_result = db_query("SELECT node.nid AS nid,
node.title AS node_title, node_revisions.body AS node_revisions_body,
node_revisions.format AS node_revisions_format FROM node node
LEFT JOIN node_revisions node_revisions
ON node.vid = node_revisions.vid where node.title like
'%a'");
$block['subject'] = 'Click to send request';
$block['content'] = $alphabetical_search_result;
return $block;
}
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/support/attachments/20100214/ff762321/attachment.html
More information about the support
mailing list