I have a form that is being used as a content mambot for Sobi2 directory component and everything is working as desired except for one thing. I need to protect the email address that I am pulling from the Sobi2 directory service. Currently a copy of email goes to administrator which is default email configuration and I have a BCC using "special fields" that is pulled from the Sobi2 component. I am using a hidden field which any decent email harvester will be able to find. Any advise on how I can hide this information and maybe pass the variable directly to the special fields or email system?
Sample code is below, any help would be much appreciated 😀
Sample code is below, any help would be much appreciated 😀
<div id="test">
<?php // "getinfo" is very bad name. It is very probably that someone has defined function with this name before
function getMySobiSpecData() {
// global $database;
// do not use global - it is dangerous
$config =& sobi2Config::getInstance();
$db =& $config->getDb();
$sid = (int) sobi2Config::request( $_GET, 'sobi2Id', 0 );
$sql = "SELECT data_txt FROM #__sobi2_item AS sitem, #__sobi2_fields_data AS sdata WHERE ( sitem.itemid = {$sid} AND sdata.itemid = {$sid} AND (sdata.fieldid = 7 ) )";
// this query gives only one result
$db->setQuery( $sql );
$result = $db->loadResult();
if ( $db->getErrorNum() ) {
echo $db->stderr();
}
return $result;
}
getMySobiSpecData();
?>
</div>
<input name="sobivendor" type="hidden" id="hiddenField" value="<?php echo getMySobiSpecData(); ?>" />