32 include_once
'class.ilMDBase.php';
39 $this->entity = $a_entity;
48 if ($this->db->autoExecute(
53 $this->
setMetaId($this->db->getLastInsertId());
65 if ($this->db->autoExecute(
69 "meta_entity_id = " . $ilDB->quote($this->
getMetaId())
77 public function delete()
82 $query =
"DELETE FROM il_meta_entity " .
83 "WHERE meta_entity_id = " . $ilDB->quote($this->
getMetaId());
108 $query =
"SELECT * FROM il_meta_entity " .
109 "WHERE meta_entity_id = " . $ilDB->quote($this->
getMetaId());
131 $writer->xmlElement(
'Entity', null, $this->
getEntity());
136 public function _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
140 $query =
"SELECT meta_entity_id FROM il_meta_entity " .
141 "WHERE rbac_id = " . $ilDB->quote($a_rbac_id) .
" " .
142 "AND obj_id = " . $ilDB->quote($a_obj_id) .
" " .
143 "AND parent_id = " . $ilDB->quote($a_parent_id) .
" " .
144 "AND parent_type = " . $ilDB->quote($a_parent_type);
148 $ids[] =
$row->meta_entity_id;
150 return $ids ? $ids :
array();
const MDB2_AUTOQUERY_UPDATE
setMetaId($a_meta_id, $a_read_data=true)
foreach($_POST as $key=> $value) $res
_getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
static stripSlashes($a_str, $a_strip_html=true, $a_allow="")
strip slashes if magic qoutes is enabled
Create styles array
The data for the language used.
static prepareDBString($a_str)
prepare a string for db writing (insert/update)
const MDB2_AUTOQUERY_INSERT
setParentType($a_parent_type)