27 $this->setAllowDeletion(
true);
28 $this->
setSuffixes(array(
"jpg",
"jpeg",
"png",
"gif"));
40 $this->allow_deletion = $a_val;
50 return $this->allow_deletion;
60 $this->cache = ($a_cache) ?
true :
false;
80 $this->image = $a_image;
120 $i_tpl =
new ilTemplate(
"tpl.prop_image_file.html",
true,
true,
"Services/Form");
128 $i_tpl->setCurrentBlock(
"delete_bl");
129 $i_tpl->setVariable(
"POST_VAR_D", $this->
getPostVar());
130 $i_tpl->setVariable(
"TXT_DELETE_EXISTING",
131 $lng->txt(
"delete_existing_file"));
132 $i_tpl->parseCurrentBlock();
137 $i_tpl->setCurrentBlock(
"has_value");
138 $i_tpl->setVariable(
"TEXT_IMAGE_NAME", $this->
getValue());
139 $i_tpl->parseCurrentBlock();
141 $i_tpl->setCurrentBlock(
"image");
144 $pos = strpos($this->
getImage(),
'?');
147 $i_tpl->setVariable(
"SRC_IMAGE", $this->
getImage() .
"&time=" . time());
151 $i_tpl->setVariable(
"SRC_IMAGE", $this->
getImage() .
"?time=" . time());
156 $i_tpl->setVariable(
"SRC_IMAGE", $this->
getImage());
158 $i_tpl->setVariable(
"ALT_IMAGE", $this->
getAlt());
159 $i_tpl->parseCurrentBlock();
165 $i_tpl->setCurrentBlock(
"pending");
166 $i_tpl->setVariable(
"TXT_PENDING", $lng->txt(
"file_upload_pending").
168 $i_tpl->parseCurrentBlock();
171 $i_tpl->setVariable(
"POST_VAR", $this->
getPostVar());
172 $i_tpl->setVariable(
"ID", $this->
getFieldId());
173 $i_tpl->setVariable(
"TXT_MAX_SIZE", $lng->txt(
"file_notice").
" ".
178 $i_tpl->setVariable(
"DISABLED",
179 " disabled=\"disabled\"");
182 $a_tpl->setCurrentBlock(
"prop_generic");
183 $a_tpl->setVariable(
"PROP_GENERIC", $i_tpl->get());
184 $a_tpl->parseCurrentBlock();