/**
  * Insert buttonbar resources
  * 
  * This method is abstracted because it is invoked by two different 
  * controllers.
  * 
  * @param Gdn_Controller $Sender 
  */
 protected function AttachButtonBarResources($Sender, $Formatter)
 {
     $Sender->AddCssFile('buttonbar.css', 'plugins/ButtonBar');
     $Sender->AddJsFile('buttonbar.js', 'plugins/ButtonBar');
     $Sender->AddJsFile('jquery.hotkeys.js', 'plugins/ButtonBar');
     $Sender->AddDefinition('InputFormat', $Formatter);
 }
 /**
  * Insert buttonbar resources
  * 
  * This method is abstracted because it is invoked by multiple controllers.
  * 
  * @param Gdn_Controller $Sender 
  */
 protected function AttachButtonBarResources($Sender, $Formatter)
 {
     if (!in_array($Formatter, $this->Formats)) {
         return;
     }
     $Sender->AddJsFile('buttonbar.js', 'plugins/ButtonBar');
     $Sender->AddJsFile('jquery.hotkeys.js', 'plugins/ButtonBar');
     $Sender->AddDefinition('ButtonBarLinkUrl', T('ButtonBar.LinkUrlText', 'Enter your URL:'));
     $Sender->AddDefinition('ButtonBarImageUrl', T('ButtonBar.ImageUrlText', 'Enter image URL:'));
     $Sender->AddDefinition('ButtonBarBBCodeHelpText', T('ButtonBar.BBCodeHelp', 'You can use <b><a href="http://en.wikipedia.org/wiki/BBCode" target="_new">BBCode</a></b> in your post.'));
     $Sender->AddDefinition('ButtonBarHtmlHelpText', T('ButtonBar.HtmlHelp', 'You can use <b><a href="http://htmlguide.drgrog.com/cheatsheet.php" target="_new">Simple Html</a></b> in your post.'));
     $Sender->AddDefinition('ButtonBarMarkdownHelpText', T('ButtonBar.MarkdownHelp', 'You can use <b><a href="http://en.wikipedia.org/wiki/Markdown" target="_new">Markdown</a></b> in your post.'));
     $Sender->AddDefinition('InputFormat', $Formatter);
 }
 /**
  * 
  * @param Gdn_Controller $Controller
  */
 public function AddPasswordStrength($Controller)
 {
     $Controller->AddJsFile('password.js');
     $Controller->AddDefinition('MinPassLength', C('Garden.Registration.MinPasswordLength'));
     $Controller->AddDefinition('PasswordTranslations', T('Password Translations', 'Too Short,Contains Username,Very Weak,Weak,Ok,Good,Strong'));
 }
Esempio n. 4
0
   /**
    *
    * @param Gdn_Controller $Sender
    */
	private function _Emotify($Sender) {
		$Sender->AddJsFile('plugins/Emotify/emotify.js');   
      $Sender->AddCssFile('plugins/Emotify/emotify.css');
      $Sender->AddDefinition('FormatEmoticons', C('Plugins.Emotify.FormatEmoticons', TRUE));
	}
Esempio n. 5
0
 /**
  *
  * @param Gdn_Controller $Controller
  */
 public function AddPasswordStrength($Controller)
 {
     $Controller->AddJsFile('password.js');
     $Controller->AddDefinition('MinPassLength', C('Garden.Registration.MinPasswordLength'));
     $Controller->AddDefinition('PasswordTranslations', implode(',', array(T('Password Too Short', 'Too Short'), T('Password Contains Username', 'Contains Username'), T('Password Very Weak', 'Very Weak'), T('Password Weak', 'Weak'), T('Password Ok', 'OK'), T('Password Good', 'Good'), T('Password Strong', 'Strong'))));
 }