protected function add_S_MIME($id) { $attrs = array($this->_attrs['suffix']->dup('suffix', DMsg::ALbl('l_suffix'), mimesuffix), DTblDefBase::NewParseTextAttr('type', DMsg::ALbl('l_mimetype'), "/^[A-z0-9_\\-\\.\\+]+\\/[A-z0-9_\\-\\.\\+]+(\\s*;?.*)\$/", DMsg::ALbl('parse_mimetype'), false, 'mimetype')); $this->_tblDef[$id] = DTbl::NewIndexed($id, DMsg::ALbl('l_mimetypeentry'), $attrs, 'suffix'); }
protected function add_VT_CTXG($id) { $attrs = array_merge($this->get_ctx_attrs('uri'), array($this->_attrs['ctx_location'], DTblDefBase::NewBoolAttr('allowBrowse', DMsg::ALbl('l_allowbrowse'), false), $this->_attrs['note']), $this->get_expires_attrs(), array($this->_attrs['extraHeaders'], DTblDefBase::NewParseTextAreaAttr('addMIMEType', DMsg::ALbl('l_mimetype'), "/[A-z0-9_\\-\\.\\+]+\\/[A-z0-9_\\-\\.\\+]+(\\s+[A-z0-9_\\-\\+]+)+/", DMsg::ALbl('parse_mimetype'), true, 2, NULL, 0, 0, 1), DTblDefBase::NewParseTextAttr('forceType', DMsg::ALbl('l_forcemimetype'), "/^([A-z0-9_\\-\\.\\+]+\\/[A-z0-9_\\-\\.\\+]+)|(NONE)\$/i", DMsg::ALbl('parse_forcemimetype')), DTblDefBase::NewParseTextAttr('defaultType', DMsg::ALbl('l_defaultmimetype'), "/^[A-z0-9_\\-\\.\\+]+\\/[A-z0-9_\\-\\.\\+]+\$/", DMsg::ALbl('parse_defaultmimetype')), $this->_attrs['indexFiles'], $this->_attrs['autoIndex']), $this->get_ctx_attrs('auth'), $this->get_ctx_attrs('rewrite'), $this->get_ctx_attrs('charset')); $defaultExtract = array('type' => 'NULL'); $this->_tblDef[$id] = DTbl::NewIndexed($id, DMsg::ALbl('l_ctxg'), $attrs, 'uri', 'generalContext', $defaultExtract); }