Inheritance: extends Plugin
 function register($category, $path)
 {
     $success = parent::register($category, $path);
     $this->addLocaleData();
     $templateMgr =& TemplateManager::getManager();
     $templateMgr->register_modifier('bibtex_escape', array(&$this, 'bibtexEscape'));
     return $success;
 }
Example #2
0
 function register($category, $path)
 {
     $success = parent::register($category, $path);
     $this->addLocaleData();
     return $success;
 }
 /**
  * Display a custom-formatted citation.
  * @param $paper object
  * @param $conference object
  * @param $schedConf object
  */
 function displayCitation(&$paper, $conference, $schedConf)
 {
     header('Content-Disposition: attachment; filename="' . $paper->getId() . '-proCite.ris"');
     header('Content-Type: application/x-Research-Info-Systems');
     echo parent::fetchCitation($paper, $conference, $schedConf);
 }
 /**
  * Display a custom-formatted citation.
  * @param $article object
  * @param $issue object
  * @param $journal object
  */
 function displayCitation(&$article, &$issue, &$journal)
 {
     header('Content-Disposition: attachment; filename="' . $article->getId() . '-proCite.ris"');
     header('Content-Type: application/x-Research-Info-Systems');
     echo parent::fetchCitation($article, $issue, $journal);
 }
Example #5
0
 /**
  * Return an HTML-formatted citation. Default implementation displays
  * an HTML-based citation using the citation.tpl template in the plugin
  * path.
  * @param $article object
  * @param $issue object
  */
 function fetchCitation($article, $issue, $journal)
 {
     $templateMgr = TemplateManager::getManager($this->getRequest());
     $templateMgr->register_modifier('bibtex_escape', array($this, 'bibtexEscape'));
     return parent::fetchCitation($article, $issue, $journal);
 }
 /**
  * Return a custom-formatted citation.
  * @param $article object
  * @param $issue object
  * @param $journal object
  */
 function displayCitation(&$article, &$issue, &$journal)
 {
     header('Content-Disposition: attachment; filename="' . $article->getId() . '-endNote.enw"');
     header('Content-Type: application/x-endnote-refer');
     echo parent::fetchCitation($article, $issue, $journal);
 }
 /**
  * Return an HTML-formatted citation. Default implementation displays
  * an HTML-based citation using the citation.tpl template in the plugin
  * path.
  * @param $article Article
  * @param $issue Issue
  * @param $journal Journal
  */
 function downloadCitation($article, $issue, $journal)
 {
     $output = parent::fetchCitation($article, $issue, $journal);
     $this->setHeaders($article, $issue, $journal);
     echo $output;
 }
 /**
  * Execute a management verb on this plugin
  * @param $verb string
  * @param $args array
  * @param $message string If a message is returned from this by-ref
  *  argument then it will be displayed as a notification if (and only
  *  if) the method returns false.
  * @return boolean will redirect to the plugin category page if false,
  *  otherwise will remain on the same page
  */
 function manage($verb, $args, &$message)
 {
     switch ($verb) {
         case 'settings':
             $templateMgr =& TemplateManager::getManager();
             $templateMgr->register_function('plugin_url', array(&$this, 'smartyPluginUrl'));
             $journal =& Request::getJournal();
             $this->import('AbntSettingsForm');
             $form = new AbntSettingsForm($this, $journal->getId());
             if (Request::getUserVar('save')) {
                 $form->readInputData();
                 if ($form->validate()) {
                     $form->execute();
                     Request::redirect(null, 'manager', 'plugin');
                     return false;
                 } else {
                     $this->setBreadCrumbs(true);
                     $form->display();
                 }
             } else {
                 $this->setBreadCrumbs(true);
                 if ($form->isLocaleResubmit()) {
                     $form->readInputData();
                 } else {
                     $form->initData();
                 }
                 $form->display();
             }
             return true;
         default:
             // Unknown management verb, delegate to parent
             return parent::manage($verb, $args, $message);
     }
 }
Example #9
0
 /**
  * Display a custom-formatted citation.
  * @param $paper object
  * @param $conference object
  * @param $schedConf object
  */
 function displayCitation(&$paper, &$conference, &$schedConf)
 {
     header('Content-Disposition: attachment; filename="' . $paper->getId() . '-endNote.enw"');
     header('Content-Type: application/x-endnote-refer');
     echo parent::fetchCitation($paper, $conference, $schedConf);
 }