01-06-2012, 03:21 AM
|
#1 (permalink)
|
|
The Visitor
Join Date: Dec 2011
Posts: 1
Thanks: 0
|
print_r noting happen with my class
i build new class to loop field html but when i print_r it nothing "FeildHTML Object ( )"
here my code
class FeildHTML
{
public function setFeildCheck ($field,$fieldval,$unsetbutton)
{
$field = array($field);
$fieldval = array($fieldval);
$label = array_combine($field,$fieldval);
unset($_POST [$unsetbutton]);
foreach($_POST as $k=>$v)
{
$$key = $v;
echo $label[$k]."=$v<br />";
}
}
}
$a = new FeildHTML();
$a->setFeildCheck('a','b','c');
print_r($a);
?>
|
|
|
|