Lines Matching refs:this

38         $this->sqlitehelper = plugin_load('helper', 'blogtng_sqlite');
39 $this->entry = $this->prototype();
52 $this->entry = $this->prototype();
53 $this->taghelper = null;
54 $this->commenthelper = null;
57 if (!$this->is_valid_pid($pid)) {
62 if(!$this->sqlitehelper->ready()) {
69 $resid = $this->sqlitehelper->getDB()->query($query, $pid);
74 if ($this->sqlitehelper->getDB()->res2count($resid) == 0) {
75 $this->entry['pid'] = $pid;
79 $result = $this->sqlitehelper->getDB()->res2arr($resid);
80 $this->entry = $result[0];
81 $this->entry['pid'] = $pid;
82 if($this->poke()){
98 $this->entry = $row;
99 if($this->poke()){
113 … if (!in_array($key, array('pid', 'page', 'created', 'login')) || empty($this->entry[$key])) {
114 $this->entry[$key] = $entry[$key];
145 if(!$this->entry['page'] or !page_exists($this->entry['page']) OR !$this->entry['blog']){
146 $this->delete();
156 if(!$this->entry['pid']) return false;
157 if(!$this->sqlitehelper->ready()) {
162 if(!$this->commenthelper) {
163 $this->commenthelper = plugin_load('helper', 'blogtng_comments');
165 $this->commenthelper->delete_all($this->entry['pid']);
168 if(!$this->taghelper) {
169 $this->taghelper = plugin_load('helper', 'blogtng_tags');
171 $this->taghelper->setPid($this->entry['pid']);
172 $this->taghelper->setTags(array()); //empty tag set
173 $this->taghelper->save();
177 $ret = $this->sqlitehelper->getDB()->query($sql,$this->entry['pid']);
178 $this->entry = $this->prototype();
188 if(!$this->entry['pid'] || $this->entry['pid'] == md5('')){
192 if (!$this->sqlitehelper->ready()) {
198 $this->sqlitehelper->getDB()->query(
200 $this->entry['pid'],
201 $this->entry['page'],
202 $this->entry['title'],
203 $this->entry['blog'],
204 $this->entry['image'],
205 $this->entry['created'],
206 $this->entry['lastmod'],
207 $this->entry['author'],
208 $this->entry['login'],
209 $this->entry['mail'],
210 $this->entry['commentstatus']
213 $result = $this->sqlitehelper->getDB()->query(
215 $this->entry['page'],
216 $this->entry['title'],
217 $this->entry['blog'],
218 $this->entry['image'],
219 $this->entry['created'],
220 $this->entry['lastmod'],
221 $this->entry['login'],
222 $this->entry['author'],
223 $this->entry['mail'],
224 $this->entry['commentstatus'],
225 $this->entry['pid']
248 $posts = $this->get_posts($conf);
251 $rendererBackup =& $this->renderer;
252 $this->renderer =& $renderer;
253 $entryBackup = $this->entry;
258 $this->load_by_row($row);
259 $this->tpl_content($conf['tpl'], $templatetype);
265 $this->entry = $entryBackup; // restore previous entry in order to allow nesting
266 $this->renderer =& $rendererBackup; // clean up again
280 return $this->xhtml_list($conf, $renderer, 'tagsearch');
289 if(!$this->sqlitehelper->ready()) return '';
292 $this->sqlitehelper->getDB()->quote_and_join($conf['blog'],
297 $this->sqlitehelper->getDB()->quote_and_join($conf['tags'],
308 $resid = $this->sqlitehelper->getDB()->query($query);
310 $count = $this->sqlitehelper->getDB()->res2count($resid);
346 '" class="prev">'.$this->getLang('prev').'</a> ';
369 '" class="next">'.$this->getLang('next').'</a> ';
384 $this->tpl_related($conf['limit'],$conf['blog'],$conf['page'],$conf['tags']);
400 if(!$this->toolshelper) {
401 $this->toolshelper = plugin_load('helper', 'blogtng_tools');
403 $new = $this->toolshelper->mkpostid($conf['format'],'dummy');
413 …helper_plugin_blogtng_tools::filterExplodeCSVinput($conf['select']), '', $this->getLang('title'), …
415 …$form->addElement(form_makeTextField('new-title', '', $this->getLang('title'), 'btng__nt', 'edit')…
418 … '?') $conf['tags'] = helper_plugin_blogtng_tools::filterExplodeCSVinput($this->getConf('default_t…
419 …$form->addElement(form_makeTextField('post-tags', implode(', ', $conf['tags']), $this->getLang('ta…
422 if($conf['type'][0] == '?') $conf['type'] = $this->getConf('default_commentstatus');
423 …('post-commentstatus', ['enabled', 'closed', 'disabled'], $conf['type'], $this->getLang('commentst…
427 $form->addElement(form_makeButton('submit', null, $this->getLang('create')));
450 $entry = $this; //used in the included template
465 $htmlcontent = $this->get_entrycontent($readmore, $inc_level, $skipheader);
468 $htmlcontent = $this->_convert_footnotes($htmlcontent);
469 $htmlcontent .= $this->_edit_button();
484 echo wl($this->entry['page']).(!empty($anchor) ? '#'.$anchor : '');
493 …echo '<a href="' . wl ($this->entry['page']) . '" title="' . hsc($this->entry['title']) . '">' . $…
503 $this->_load_abstract();
505 $abstract = utf8_substr($this->entry['abstract'], 0, $len).'…';
507 $abstract = $this->entry['abstract'];
516 print hsc($this->entry['title']);
525 if(!$this->entry['created']) return; // uh oh, something went wrong
526 print dformat($this->entry['created'],$format);
535 if(!$this->entry['lastmod']) return; // uh oh, something went wrong
536 print dformat($this->entry['lastmod'], $format);
543 if(empty($this->entry['author'])) return;
544 print hsc($this->entry['author']);
553 if(empty($this->entry['author'])) return;
561 hsc($this->entry['author']) . '</a>' . DOKU_LF
576 if ($this->entry['commentstatus'] == 'disabled') return;
577 if(!$this->commenthelper) {
578 $this->commenthelper = plugin_load('helper', 'blogtng_comments');
580 $this->commenthelper->setPid($this->entry['pid']);
581 $this->commenthelper->tpl_comments($name,$types);
594 if(!$this->commenthelper) {
595 $this->commenthelper = plugin_load('helper', 'blogtng_comments');
597 $this->commenthelper->setPid($this->entry['pid']);
598 $this->commenthelper->tpl_count($fmt_zero_comments, $fmt_one_comment, $fmt_comments);
612 if(!$this->sqlitehelper->ready()) return;
622 $res = $this->sqlitehelper->getDB()->query($query);
623 $res = $this->sqlitehelper->getDB()->res2arr($res);
631 $tags = $this->sqlitehelper->getDB()->quote_and_join($tags,',');
633 $this->sqlitehelper->getDB()->quote_and_join($blogs,
646 $res = $this->sqlitehelper->getDB()->query($query);
647 if(!$this->sqlitehelper->getDB()->res2count($res)) return; // no results found
648 $res = $this->sqlitehelper->getDB()->res2arr($res);
666 …if ($this->entry['commentstatus'] == 'closed' || $this->entry['commentstatus'] == 'disabled') retu…
667 if(!$this->commenthelper) {
668 $this->commenthelper = plugin_load('helper', 'blogtng_comments');
670 … $this->commenthelper->tpl_form($this->entry['page'], $this->entry['pid'], $this->entry['blog']);
681 if (!$this->taghelper) {
682 $this->taghelper = plugin_load('helper', 'blogtng_tags');
684 $this->taghelper->load($this->entry['pid']);
685 $this->taghelper->tpl_tags($target);
693 if (!$this->taghelper) {
694 $this->taghelper = plugin_load('helper', 'blogtng_tags');
696 $this->taghelper->load($this->entry['pid']);
697 $this->taghelper->tpl_tagstring($target, $separator);
711 $out = $this->_navi_link($tpl, 'prev', $id);
732 $out = $this->_navi_link($tpl, 'next', $id);
765 if ($this->entry != null) {
766 return $this->entry['blog'];
785 if(!$this->sqlitehelper->ready()) return array();
791 …$blog_query = '(blog = ' . $this->sqlitehelper->getDB()->quote_and_join($conf['blog'], ' OR blog =…
800 …$tag_query .= ' (tag = ' . $this->sqlitehelper->getDB()->quote_and_join($conf['tags'], ' OR tag = …
816 $resid = $this->sqlitehelper->getDB()->query($query);
817 return $this->sqlitehelper->getDB()->res2arr($resid);
830 $id = $this->entry['page'];
851 $this->_convert_instructions($ins, $inc_level, $readmore, $skipheader);
854 … $handleTOC = ($this->renderer !== null); // the call to p_render below might set the renderer
860 $renderer =& $this->renderer; // save the renderer before p_render changes it
876 $this->renderer =& $renderer;
897 if (!$this->taghelper) {
898 $this->taghelper = plugin_load('helper', 'blogtng_tags');
900 return ($this->taghelper->count($this->entry['pid']) > 0);
916 if(!$this->sqlitehelper->ready()) return $related;
931 $res = $this->sqlitehelper->getDB()->query($query, $pid);
932 if ($this->sqlitehelper->getDB()->res2count($res) > 0) {
933 $result = $this->sqlitehelper->getDB()->res2arr($res);
945 if(!$this->commenthelper) {
946 $this->commenthelper = plugin_load('helper', 'blogtng_comments');
947 $this->commenthelper->setPid($this->entry['pid']);
949 return $this->commenthelper;
957 if (!$this->taghelper) {
958 $this->taghelper = plugin_load('helper', 'blogtng_tags');
959 $this->taghelper->load($this->entry['pid']);
961 return $this->taghelper;
969 if(isset($this->entry['abstract'])) return;
970 $id = $this->entry['page'];
972 $this->entry['abstract'] = p_get_metadata($id,'description abstract',true);
985 $id = $this->entry['page'];
1007 $ins[$i][1][0] = $this->_convert_internal_link($ins[$i][1][0], $ns);
1075 $this->_read_more($ins, $i, $open_wraps, $inc_level);
1082 $this->_finish_convert($ins, $open_wraps['sections']);
1108 return $this->entry['page'].$link;
1158 …ns[] = array('internallink',array($this->entry['page'].'#readmore_'.str_replace(':', '_', $this->e…
1187 $id = str_replace(':', '_', $this->entry['page']);
1203 $id = $this->entry['page'];
1237 $related = $this->getAdjacentLinks($id);