return true;
}
- function onEndShowStyles($action)
+ function onEndShowStyles(Action $action)
{
$action->element('style', null,
'.form-train-spam input.submit { background: url('.$this->path('icons/bullet_black.png').') no-repeat 0px 0px } ' . "\n" .
return true;
}
- function onEndShowHTML($action)
+ function onEndShowHTML(Action $action)
{
if (!common_logged_in()) {
// Set a place to return to when submitting forms
}
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
// Setup ajax calls for favoriting. Usually this is only done when
// a user is logged in.
parent::__construct();
}
- function onEndShowScripts($action){
+ function onEndShowScripts(Action $action){
if (common_logged_in()) {
$action->element('span', array('id' => 'autocomplete-api',
'data-url' => common_local_url('autocomplete')));
return null;
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$action->script(common_path('plugins/TinyMCE/js/jquery.tinymce.js'));
$action->inlineScript('var _tinymce_path = "'.common_path('plugins/TinyMCE/js/tiny_mce.js').'";'."\n".
*
* @return boolean hook value
*/
- function onEndShowStyles($action)
+ function onEndShowStyles(Action $action)
{
$action->cssLink($this->path('css/bookmark.css'));
return true;
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$action->script($this->path('js/bookmark.js'));
return true;
parent::__construct();
}
- function onEndShowScripts($action){
+ function onEndShowScripts(Action $action){
if (common_logged_in()) {
$user = common_current_user();
$action->inlineScript('var maxNoticeLength = ' . User_urlshortener_prefs::maxNoticeLength($user));
*
* @param Action $action
*/
- function onEndShowScripts($action){
+ function onEndShowScripts(Action $action){
if (common_logged_in()) {
$action->script($this->path('jquery.DirectionDetector.js'));
}
}
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$action->script($this->path('js/event.js'));
}
- function onEndShowStyles($action)
+ function onEndShowStyles(Action $action)
{
$action->cssLink($this->path('css/event.css'));
return true;
* @param Action $action the current action
*
*/
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
if ($this->needsScripts($action)) {
_('Photo gallery'), $nav->action->trimmed('action') == 'photos', 'nav_photos');
}
- function onEndShowStyles($action)
+ function onEndShowStyles(Action $action)
{
$action->cssLink('/plugins/GNUsocialPhotos/res/style.css');
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$action->script('plugins/GNUsocialPhotos/res/gnusocialphotos.js');
}
}
}
- function onEndShowStyles($action)
+ function onEndShowStyles(Action $action)
{
$action->cssLink('/plugins/GNUsocialProfileExtensions/res/style.css');
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$action->script('plugins/GNUsocialProfileExtensions/js/profile.js');
}
parent::__construct();
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$code = common_config('googleanalytics', 'code');
if (empty($code)) {
parent::__construct();
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$action->inlineScript('var infinite_scroll_on_next_only = ' . ($this->on_next_only?'true':'false') . ';');
$action->inlineScript('var ajax_loader_url = "' . ($this->path('ajax-loader.gif')) . '";');
* @param Action $action
* @return boolean hook result
*/
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$user = common_current_user();
if ($user && common_config('attachments', 'process_links')) {
*
* @return boolean event handler return
*/
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$actionName = $action->trimmed('action');
return true;
}
- function noticeAsJson($notice)
+ function noticeAsJson(Notice $notice)
{
// FIXME: this code should be abstracted to a neutral third
// party, like Notice::asJson(). I'm not sure of the ethics
}
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
// @todo FIXME: "Show Navigation" / "Hide Navigation" needs i18n
$action->inlineScript('
*/
class OpenExternalLinkTargetPlugin extends Plugin
{
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$action->inlineScript('$(document).on("click", "a[rel~=external]:not([class~=attachment])", function () { window.open(this.href); return false; });');
*
* @return boolean ignored
*/
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
// Slight modification to the default code.
// Loading the piwik.js file from a <script> created in a document.write
*
* @return boolean hook value
*/
- function onEndShowStyles($action)
+ function onEndShowStyles(Action $action)
{
$action->cssLink($this->path('css/poll.css'));
return true;
}
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$action->script($this->path('js/qna.js'));
return true;
}
- function onEndShowStyles($action)
+ function onEndShowStyles(Action $action)
{
$action->cssLink($this->path('css/qna.css'));
return true;
return true;
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$channel = $this->_getChannel($action);
return false; // No default processing
}
- function noticeAsJson($notice)
+ function noticeAsJson(Notice $notice)
{
// FIXME: this code should be abstracted to a neutral third
// party, like Notice::asJson(). I'm not sure of the ethics
return $arr;
}
- function getNoticeTags($notice)
+ function getNoticeTags(Notice $notice)
{
$tags = null;
*
* @return boolean hook return value
*/
- function onEndScriptMessages($action, &$messages)
+ function onEndScriptMessages(Action $action, &$messages)
{
// TRANS: Text label for realtime view "play" button, usually replaced by an icon.
$messages['realtime_play'] = _m('BUTTON', 'Play');
return true;
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
if (isset($action->recaptchaPluginNeedsOutput) && $action->recaptchaPluginNeedsOutput) {
// Load the AJAX API
return true;
}
- function onStartRegistrationTry($action)
+ function onStartRegistrationTry(Action $action)
{
$resp = recaptcha_check_answer ($this->private_key,
$_SERVER["REMOTE_ADDR"],
*
* @return boolean hook value
*/
- public function onStartRegistrationTry($action)
+ public function onStartRegistrationTry(Action $action)
{
$ipaddress = $this->_getIpAddress();
* @return
*/
- function onStartShowSiteNotice($action)
+ function onStartShowSiteNotice(Action $action)
{
return false;
}
return true;
}
- function onEndShowStyles($action)
+ function onEndShowStyles(Action $action)
{
$action->element('style', null, '#site_notice { width: 100% }');
return true;
parent::__construct();
}
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
$action->script($this->path('tabfocus.js'));
}
// "richedit" role get it.
public $restricted = false;
- function onEndShowScripts($action)
+ function onEndShowScripts(Action $action)
{
if (common_logged_in() && $this->isAllowedRichEdit()) {
$action->script(common_path('plugins/TinyMCE/js/jquery.tinymce.js'));
return true;
}
- function onEndShowStyles($action)
+ function onEndShowStyles(Action $action)
{
if ($this->isAllowedRichEdit()) {
$action->style('span#notice_data-text_container, span#notice_data-text_parent { float: left }');
return true;
}
- function onStartRegistrationTry($action)
+ function onStartRegistrationTry(Action $action)
{
$this->_checkMaxUsers();
return true;