If the value 0 in the field do not see for visitors
please help
If the value 0 in the field: Activated do not see for visitors
If the value 1 in the field : Activated he sees for visitors
Activated=0 The table not shows for visitors
Activated=1 The table shows for visitors
Meaning it does not cleanse the table to visitors only on condition that if the value of 1 Activated concert
userlevelid :0
userlevelname: Default
I tried this code and failure:
function UserID_Loaded() {
//echo "UserID Loaded: " . $this->UserIDList() . "<br>";
global $Page;
if ($Page && $Page->TableName == "programs" && CurrentUserLevel() == "0") {
$this->AddUserID(-1);
ew_AddFilter($filter, " Activated <> 0 ");
}
The table is:
CREATE TABLE programs
(
Programs_id
int(11) NOT NULL,
Programs_name
varchar(255) NOT NULL,
initiative
int(11) NOT NULL,
goal
text,
Brief
text,
From_date
date DEFAULT NULL,
To_date
date DEFAULT NULL,
implementation_period
int(11) DEFAULT NULL,
Type_Length
int(11) DEFAULT NULL,
Beneficiaries
int(11) DEFAULT NULL,
number_beneficiaries
int(11) DEFAULT NULL,
Results
text NOT NULL,
pictures
varchar(100) DEFAULT NULL,
Video
longblob,
Identity
int(11) DEFAULT NULL,
Activated
int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8;