当前位置: 首页>>代码示例>>PHP>>正文


PHP IPSLib::fetchEmoticonsAsJson方法代码示例

本文整理汇总了PHP中IPSLib::fetchEmoticonsAsJson方法的典型用法代码示例。如果您正苦于以下问题:PHP IPSLib::fetchEmoticonsAsJson方法的具体用法?PHP IPSLib::fetchEmoticonsAsJson怎么用?PHP IPSLib::fetchEmoticonsAsJson使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在IPSLib的用法示例。


在下文中一共展示了IPSLib::fetchEmoticonsAsJson方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: chatRoom

 function chatRoom($options = array(), $chatters = array())
 {
     $IPBHTML = "";
     if (IPSLib::locationHasHooks('skin_ipchat', $this->_funcHooks['chatRoom'])) {
         $count_fc473221c0d8519b3b35e078488c45d5 = is_array($this->functionData['chatRoom']) ? count($this->functionData['chatRoom']) : 0;
         $this->functionData['chatRoom'][$count_fc473221c0d8519b3b35e078488c45d5]['options'] = $options;
         $this->functionData['chatRoom'][$count_fc473221c0d8519b3b35e078488c45d5]['chatters'] = $chatters;
     }
     $IPBHTML .= "" . $this->registry->getClass('output')->addJSModule("chat", "0") . "\n" . $this->registry->getClass('output')->addToDocumentHead('importcss', "{$this->settings['css_base_url']}style_css/{$this->registry->output->skin['_csscacheid']}/ipb_editor.css") . "\n<script type='text/javascript'>\n\t// Basic variables\n\tvar roomId\t\t= {$options['roomId']};\n\tvar userId\t\t= {$options['userId']};\n\tvar userName\t= '" . ($this->memberData['member_id'] ? "{$this->memberData['members_display_name']}" : "{$this->memberData['members_display_name']}_{$options['userId']}") . "';\n\tvar accessKey\t= '{$options['accessKey']}';\n\tvar serverHost\t= '{$options['serverHost']}';\n\tvar serverPath\t= '{$options['serverPath']}';\n\tvar ourUrl\t\t= '{$options['ourUrl']}';\n\tUSE_RTE\t\t\t= 0;\n\tvar isMobile\t= 0;\n\t// Chat settings\t\n\tipb.chat.condenseTime\t\t= parseInt({$this->settings['ipchat_limit_time']});\n\tipb.chat.maxMessages\t\t= parseInt({$this->settings['ipchat_max_messages']});\n\tipb.chat.moderator\t\t\t= parseInt({$options['moderator']});\n\tipb.chat.private\t\t\t= parseInt({$options['private']});\n\tipb.chat.hideEnterExit\t\t= parseInt({$this->settings['ipchat_hide_usermessage']});\n\tipb.chat.noBuffer\t\t\t= parseInt('{$this->settings['ipchat_no_buffer']}');\n\tipb.chat.inactiveKick\t\t= parseInt('{$this->settings['ipchat_inactive_minutes']}');\n\tipb.chat.user24hour \t\t= parseInt('{$this->settings['ipchat_24hour']}');\n\t\n\t// Set up templates\n\tipb.chat.templates['msg-1']\t\t\t\t= new Template( \"<li class='post chat-message #{ownclass}'>#{photo} <label>#{username}</label> <div>#{message}</div></li>\" );\n\tipb.chat.templates['msg-1-compound']\t= new Template( \"<li class='post chat-message #{ownclass}'><div class='hider'>&nbsp;</div><div>#{message}</div></li>\" );\n\tipb.chat.templates['msg-2']\t\t\t\t= new Template( \"<li class='post chat-notice'>#{photo} <label>#{username}</label> <div>#{action}</div></li>\" );\n\tipb.chat.templates['msg-3']\t\t\t\t= new Template( \"<li class='post chat-me'>#{photo} <label>#{username}</label> <div>**#{message}**</div></li>\" );\n\tipb.chat.templates['msg-4']\t\t\t\t= new Template( \"<li class='post chat-system'>{$this->lang->words['sys_message_pre']} #{message}</li>\" );\n\tipb.chat.templates['msg-5']\t\t\t\t= new Template( \"<li class='post chat-moderator'><label class='fluid'>#{username}</label> <div>{$this->lang->words['_kicked']} #{extra}</div></li>\" );\n\tipb.chat.templates['msg-K']\t\t\t\t= new Template( \"<li class='post chat-moderator'><div>{$this->lang->words['youve_been_kicked']}</div></li>\" );\n\tipb.chat.templates['send_private']\t\t= new Template( \"<div id='priv_#{id}_wrap'><h3 class='bar'>{$this->lang->words['sendprivatechat']}</h3><div class='chat-private-message'><textarea name='message_content' id='priv_chat_text_#{id}' cols='25' rows='2'></textarea> <input type='submit' value='{$this->lang->words['sendprivatebutton']}' class='input_submit add_folder' id='#{id}_submit' onclick='return ipb.chat.sendPrivateChat( #{id} );' /></div></div>\" );\n\tipb.chat.templates['new-tab']\t\t\t= new Template( \"<a href='#tab-#{id}' rel='#{id}'>#{name}&nbsp;&nbsp;&nbsp;<img src='{$this->settings['img_url']}/cross.png' alt='x' class='right' id='close-chat-tab-#{id}' /></a>\" );\n\tipb.chat.templates['count-title']\t\t= new Template( \"" . str_replace('%s', '#{count}', $this->lang->words['chattab_count']) . "\" );\n\t\n\t// Set some language vars\n\tipb.lang['time_am']\t\t\t\t= \"{$this->lang->words['time_am']}\";\n\tipb.lang['time_pm']\t\t\t\t= \"{$this->lang->words['time_pm']}\";\n\tipb.lang['entered_room']\t\t= \" {$this->lang->words['entered_room']}\";\n\tipb.lang['left_room']\t\t\t= \" {$this->lang->words['left_room']}\";\n\tipb.lang['chat_kick_user']\t\t= \"{$this->lang->words['chat_kick_user']}\";\n\tipb.lang['chat_ban_user']\t\t= \"{$this->lang->words['chat_ban_user']}\";\n\tipb.lang['chat_priv_user']\t\t= \"{$this->lang->words['chat_priv_user']}\";\n\tipb.lang['cant_kick_self']\t\t= \"{$this->lang->words['cant_kick_self']}\";\n\tipb.lang['youve_been_kicked']\t= \"{$this->lang->words['youve_been_kicked']}\";\n\tipb.lang['block_priv_user']\t\t= \"{$this->lang->words['block_priv_user']}\";\n\tipb.lang['unblock_priv_user']\t= \"{$this->lang->words['unblock_priv_user']}\";\n\tipb.lang['cant_block_user']\t\t= \"{$this->lang->words['cant_block_user']}\";\n\tipb.lang['noprivate_withignored'] = \"{$this->lang->words['noprivate_withignored']}\";\n\tipb.lang['ban_user_confirm']\t= \"{$this->lang->words['banconfirmpopup']}\";\n\t\n\t// Emoticons\n\tipb.chat.emoticons\t\t\t= \$H({ " . IPSLib::fetchEmoticonsAsJson($this->registry->output->skin['set_emo_dir'], true) . " });\n\tipb.vars['emoticon_url']\t= \"{$this->settings['emoticons_url']}\";\n\tipb.vars['img_url']\t\t\t= '{$this->settings['img_url']}';\n\t\n\t// Sound\n\tipb.chat.soundEnabled\t\t= " . (IPSCookie::get('chat_sounds') == 'off' ? "0" : "1") . ";\n\tipb.chat.soundOnImg\t\t\t= \"{$this->settings['img_url']}/bell.png\";\n\tipb.chat.soundOffImg\t\t= \"{$this->settings['img_url']}/bell_off.png\";\n\t\n\t// Chatters name formatting\n\t" . $this->__f__776f6e2cf0409238d7f8b06df58633b5($options, $chatters) . "\t// Ignore private chats from..\n\t" . $this->__f__5cb7dc707613b708061e35c39c0315de($options, $chatters) . "\t" . ((isset($this->memberData['_ignoredUsers']) and count($this->memberData['_ignoredUsers'])) ? "\n\t\t" . $this->__f__912a9882eb2468aa711103e006f1db77($options, $chatters) . "\t" : "") . "\n\t\n\t// Badwords\n\t" . ((is_array($this->caches['badwords']) and count($this->caches['badwords'])) ? "\n\t\t" . $this->__f__a322b0264fb42d72e2ed89b6f99a822a($options, $chatters) . "\t" : "") . "\n\t\n\t// Groups\n\t" . $this->__f__2a73ab0bb6c4c786423dde2785d55fd9($options, $chatters) . "</script>\n<script type='text/javascript' src='{$this->settings['public_dir']}js/ips.editor.js'></script>\n" . (!$this->request['_popup'] ? "\n\t<h1 class='ipsType_pagetitle'>" . IPSLib::getAppTitle('ipchat') . "</h1>\n\t<br /><br />\n" : "") . "\n<div class='ipsBox ipsLayout ipsLayout_withright ipsPostForm clearfix'>\n\t<div class='ipsBox_container ipsLayout_right ipsPostForm_sidebar'>\n\t\t<div id='chat-room-list' style='display:none'>\n\t\t\t<h3 class='bar'>{$this->lang->words['chats']}</h3>\n\t\t\t<div class='ipsPad ipsSideMenu'>\n\t\t\t\t<ul id='chat-tab-holder'>\n\t\t\t\t\t<li class='active' id='tab-chatroom'><a href='#tab-chatroom' rel='chatroom'>{$this->lang->words['chat_tab_home']}</a></li>\n\t\t\t\t</ul>\n\t\t\t</div>\n\t\t</div>\t\n\t\t<h3 class='bar'><span id='online-chat-count'>" . (($_count = count($chatters)) ? "{$_count}" : "0") . "</span> {$this->lang->words['whos_chatting_ttl']}</h3>\n\t\t<div class='ipsPad' id='chatters-online-wrap'>\n\t\t\t<ul id='chatters-online'>\n\t\t\t\t" . $this->__f__85f7a2a7de7bd273e202a92898fb0067($options, $chatters) . "\t\t\t</ul>\n\t\t</div>\n\t\t<div class='ipsPad right'>\n\t\t\t<ul class='ipsList_inline'>\n\t\t\t\t<li>\n\t\t\t\t\t<a class='ipsButton_secondary' href='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("module=ipschat&amp;section=chat&amp;do=leave&amp;room={$options['roomId']}&amp;user={$options['userId']}&amp;access_key={$options['accessKey']}&amp;secure_key={$this->member->form_hash}" . ($this->request['_popup'] ? "&amp;popup=1" : "") . "", "publicWithApp", ''), "", "") . "' title='{$this->lang->words['leave_room']}' id='leave_room'><img src='{$this->settings['img_url']}/cross.png' alt='{$this->lang->words['leave_room']}' /> {$this->lang->words['leave_room']}</a>\n\t\t\t\t</li>\n\t\t\t\t<li>\n\t\t\t\t\t<a class='ipsButton_secondary' href='#' title='{$this->lang->words['toggle_sound']}' id='sound_toggle'>&nbsp;<img id='sound_toggle_img' src='{$this->settings['img_url']}/" . (IPSCookie::get('chat_sounds') == 'off' ? "bell_off.png" : "bell.png") . "' alt='{$this->lang->words['toggle_sound']}' />&nbsp;</a>\n\t\t\t\t</li>\n\t\t\t\t" . (!$this->request['_popup'] ? "\n\t\t\t\t\t<li>\n\t\t\t\t\t\t<a class='ipsButton_secondary' href='#' title='{$this->lang->words['chat_new_window']}' id='chat_new_window'><img src='{$this->settings['img_url']}/chat/window_open.png' alt='{$this->lang->words['chat_new_window']}' /></a>\n\t\t\t\t\t</li>\n\t\t\t\t" : "") . "\n\t\t\t</ul>\n\t\t</div>\n\t</div>\n\t<div class='ipsBox_container ipsLayout_content'>\n\t\t<div id='scrollbar_container'>\n\t\t\t<div id='messages-display'><span id='initial_message'>{$this->lang->words['please_wait_chats']}</span></div>\n\t\t</div>\n\t\t<form id='chat-form' action='#' method='post'>\n\t\t\t<input type='hidden' name='1_wysiwyg_used' id='1_wysiwyg_used' value='0' />\n\t\t\t<input type='hidden' name='editor_ids[]' value='1' />\n\t\t\t<div class='ips_editor' id='editor_message'>\n\t\t\t\t<div id='message_controls' class='controls'>\n\t\t\t\t\t<ul id='message_toolbar_2' class='toolbar' style='display: none'>\n\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t<span id='message_cmd_bold' class='rte_control rte_button' title='{$this->lang->words['js_tt_bold']}'><img src='{$this->settings['img_url']}/rte_icons/bold.png' alt='{$this->lang->words['js_tt_bold']}' /></span>\n\t\t\t\t\t\t</li>\n\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t<span id='message_cmd_italic' class='rte_control rte_button' title='{$this->lang->words['js_tt_italic']}'><img src='{$this->settings['img_url']}/rte_icons/italic.png' alt='{$this->lang->words['js_tt_italic']}' /></span>\n\t\t\t\t\t\t</li>\n\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t<span id='message_cmd_underline' class='rte_control rte_button' title='{$this->lang->words['js_tt_underline']}'><img src='{$this->settings['img_url']}/rte_icons/underline.png' alt='{$this->lang->words['js_tt_underline']}' /></span>\n\t\t\t\t\t\t</li>\n\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t<span id='emoticons_custom_menu' class='ipbmenu rte_control rte_button' title='{$this->lang->words['js_tt_emoticons']}'><img src='{$this->settings['img_url']}/rte_icons/emoticons.png' alt='{$this->lang->words['js_tt_emoticons']}' /></span>\n\t\t\t\t\t\t</li>\n\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t<span id='message_cmd_link' class='rte_control rte_palette' title='{$this->lang->words['js_tt_link']}'><img src='{$this->settings['img_url']}/rte_icons/link.png' alt='{$this->lang->words['js_tt_link']}' /></span>\n\t\t\t\t\t\t</li>\n\t\t\t\t\t</ul>\n\t\t\t\t</div>\n\t\t\t\t<div id='message_wrap' class='editor'>\n\t\t\t\t\t<textarea name=\"message\" class=\"input_rte\" id=\"message_textarea\" rows=\"3\" cols=\"50\" tabindex=\"0\" maxlength=\"450\"></textarea>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<input type='submit' id='chat-submit' class='input_submit' value='{$this->lang->words['chat_post_button']}' />\n\t\t</form>\n\t</div>\n</div>\n<div id='mod-menu-container'>\n\t" . $this->__f__b9925e475553743bdec6c74675fb1a60($options, $chatters) . "</div>\n<div id='emoticons_custom_menu_menucontent'></div>\n<script type='text/javascript'>\n\tif( \$( 'message_toolbar_2' ) ){ \$( 'message_toolbar_2' ).show(); }\n\tipb.editor_values.get('templates')['link'] = new Template(\"<label for='#{id}_url'>{$this->lang->words['js_template_url']}</label><input type='text' class='input_text' id='#{id}_url' value='http://' tabindex='10' /><label for='#{id}_urltext'>{$this->lang->words['js_template_link']}</label><input type='text' class='input_text _select' id='#{id}_urltext' value='{$this->lang->words['js_template_default']}' tabindex='11' /><input type='submit' value='{$this->lang->words['js_template_insert_link']}' tabindex='12' />\");\n\tipb.editor_values.get('templates')['emoticons_showall'] = new Template(\"<input class='input_submit emoticons' type='button' id='#{id}_all_emoticons' value='{$this->lang->words['show_all_emoticons']}' />\");\n\tipb.editor_values.get('templates')['emoticon_wrapper'] = new Template(\"<h4><span>{$this->lang->words['emoticons_template_title']}</span></h4><div id='#{id}_emoticon_holder' class='emoticon_holder'></div>\");\n\tipb.editor_values.set( 'show_emoticon_link', false );\n\tipb.editor_values.set( 'emoticons', ipb.chat.emoticons );\n\tipb.editor_values.set( 'bbcodes', \$H(" . IPSLib::fetchBbcodeAsJson() . ") );\n\tipb.editors[ 'message' ] = new ipb.editor( 'message', 0 );\n\t/* Load emoticons on the fly ... */\n\tvar _emoticonsLoaded\t= false;\n\t\$('emoticons_custom_menu').observe( 'click', function( e ){ \n\t\tif( !_emoticonsLoaded )\n\t\t{\n\t\t\tnew Ajax.Request( \n\t\t\t\t\t\t\t\tipb.vars['base_url'] + \"&app=ipchat&module=ajax&section=getemoticons&md5check=\" + ipb.vars['secure_hash'], \n\t\t\t\t\t\t\t\t{ \n\t\t\t\t\t\t\t\t\tmethod: 'get',\n\t\t\t\t\t\t\t\t\tonSuccess: function(t)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\$('emoticons_custom_menu_menucontent').update( t.responseText );\n\t\t\t\t\t\t\t\t\t\t_emoticonsLoaded\t= true;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t);\n\t\t}\n\t});\n\tfunction addEmoImage(elem){\n\t\tvar code = elem.up('tr').down('a').innerHTML;\n\t\tvar title = elem.up('tr').down('img').readAttribute('title');\n\t\tipb.editors[ 'message' ].insert_emoticon('', title, code,'');\n\t}\n</script>\n\t\t\t\n<!--Iframes used for cross-domain \"AJAX\"-->\n<div id='iframeContainer'>\n<div id='storage_container_chatroom' class='storage-container'><ul id='storage_chatroom'></ul></div>\n</div>";
     return $IPBHTML;
 }
开发者ID:mover5,项目名称:imobackup,代码行数:11,代码来源:skin_ipchat.php

示例2: showConversation

 function showConversation($topic, $replies, $members, $jump = "")
 {
     $IPBHTML = "";
     $IPBHTML .= "<div id='conversation'>\n\t\n<div class='topic_controls'>\n\t{$topic['_pages']}\n\t<ul class='topic_buttons'>\n\t\t" . (1 == 1 ? "\n\t\t\t<li><a href='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("module=messaging&amp;section=send&amp;do=form", 'publicWithApp', ''), "", "") . "' title='Go to compose screen'>" . $this->registry->getClass('output')->getReplacement("compose_icon") . " Compose New</a></li>\n\t\t" : "") . "" . ($topic['_canReply'] ? "\n\t\t\t<li><a href='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("module=messaging&amp;section=send&amp;do=replyForm&amp;topicID={$topic['mt_id']}", 'publicWithApp', ''), "", "") . "'>" . $this->registry->getClass('output')->getReplacement("reply_icon") . " Add Reply</a></li>\n\t\t" : "\n\t\t\t<li class='disabled'><span>You cannot reply</span></li>\n\t\t") . "\n\t\t<!-- SKINNOTE: Can probably do with some kind of 'are you sure' dialogue here.. -->\n\t\t<li><a onclick='ipb.messenger.deletePM(this)' id='pm_delete_t_{$topic['mt_id']}' href='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("module=messaging&amp;section=view&amp;do=deleteConversation&amp;topicID={$topic['mt_id']}&amp;authKey={$this->member->form_hash}", 'publicWithApp', ''), "", "") . "'>" . $this->registry->getClass('output')->getReplacement("delete_msg_icon") . " Delete</a></li>\n\t</ul>\n</div>\n<br />\n<h2>{$topic['mt_title']}</h2>\n<ul class='topic_options'></ul>" . $this->__f__1ecf86a8538860412fe57ff8f7d8bfb8($topic, $replies, $members, $jump) . "<div class='topic_controls'>\n\t{$topic['_pages']}\n\t<ul class='topic_buttons'>\n\t\t" . (1 == 1 ? "\n\t\t\t<li><a href='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("module=messaging&amp;section=send&amp;do=form", 'publicWithApp', ''), "", "") . "' title='Go to compose screen'>" . $this->registry->getClass('output')->getReplacement("compose_icon") . " Compose New</a></li>\n\t\t" : "") . "" . ($topic['_canReply'] ? "\n\t\t\t<li><a href='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("module=messaging&amp;section=send&amp;do=replyForm&amp;topicID={$topic['mt_id']}", 'publicWithApp', ''), "", "") . "'>" . $this->registry->getClass('output')->getReplacement("reply_icon") . " Add Reply</a></li>\n\t\t" : "\n\t\t\t<li class='disabled'><span>You cannot reply</span></li>\n\t\t") . "\n\t\t<!-- SKINNOTE: Can probably do with some kind of 'are you sure' dialogue here.. -->\n\t\t<li><a onclick='ipb.messenger.deletePM(this)' id='pm_delete_b_{$topic['mt_id']}' href='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("module=messaging&amp;section=view&amp;do=deleteConversation&amp;topicID={$topic['mt_id']}&amp;authKey={$this->member->form_hash}", 'publicWithApp', ''), "", "") . "'>" . $this->registry->getClass('output')->getReplacement("delete_msg_icon") . " Delete</a></li>\n\t</ul>\n</div>\n<br />\n" . ($topic['_canReply'] ? "" . $this->registry->getClass('output')->addJSModule("editor", "0") . "\n\t<script type='text/javascript'>\n\t\t//<![CDATA[\n\t\t" . $this->registry->getClass('output')->getTemplate('editors')->editorJS() . "\n\t\t//]]>\n\t</script>\n\t\n\t<br />\n\t<div id='fast_reply' style='display: {$displayData['fast_reply']}'>\n\t\t<h3>Fast Reply</h3>\n\t\t<ul class='topic_options'></ul>\n\t\t<div class='general_box alt'>\n\t\t\t<form action='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("app=members&amp;module=messaging&amp;section=send&amp;do=sendReply&amp;topicID={$topic['mt_id']}", 'public', ''), "", "") . "' method='post'>\n\t\t\t\t" . $this->registry->getClass('output')->getTemplate('editors')->editorShell('fast-reply', 'msgContent', '', 1) . "\n\t\t\t\t<fieldset class='submit'>\n\t\t\t\t\t<input type=\"hidden\" name=\"authKey\" value=\"{$this->member->form_hash}\" />\n\t\t\t\t\t<input type=\"hidden\" name=\"fast_reply_used\" value=\"1\" />\n\t\t\t\t\t<input type=\"hidden\" name=\"enableemo\" value=\"yes\" />\n\t\t\t\t\t<input type=\"hidden\" name=\"enablesig\" value=\"yes\" />\n\t\t\t\t\t<input type='submit' name=\"submit\" class='input_submit' value='Post' />&nbsp;&nbsp;<input type='submit' name=\"previewReply\" class='input_submit alt' value='Use Full Editor' />\n\t\t\t\t</fieldset>\n\t\t\t</form>\n\t\t</div>\n\t</div>\n\t<script type=\"text/javascript\">\n\t//<![CDATA[\n\t\tif( \$('fast-reply_textarea') ){\n\t\t\t\$('fast-reply_textarea').setStyle('height: 70px');\n\t\t}\n\t\t\n\t\tipb.editor_values.set( 'emoticons', \$H({ " . IPSLib::fetchEmoticonsAsJson() . " }) );\n\t\tipb.vars['emoticon_url'] = \"{$this->settings['emoticons_url']}\";\n\t\t//ipb.editors[ '{$editor_id}' ] = new ipb.editor( '{$editor_id}', parseInt({$rte_mode}), parseInt({$rte_mode}) == 1 ? 0 : 1, 'Hello this is an initial value' );\n\t\tipb.editors[ 'fast-reply' ] = new ipb.editor( 'fast-reply', USE_RTE );\n\t\tin_use = 0;\n\t\t" . ($rte_mode != 1 ? "\n\t\t\tobj = ipb.editors['fast-reply'].editor_document;\n\t\t" : "\n\t\t\tobj = \$( ipb.editors['fast-reply'].items['text_obj'] );\n\t\t") . "\n\t\tEvent.observe( obj, 'click', function(){\n\t\t\tif( in_use != 1 ){\n\t\t\t\t\$( ipb.editors['fast-reply'] ).resize_to( 250 );\n\t\t\t\tin_use = 1;\n\t\t\t}\n\t\t}, true);\n\t//]]>\n\t</script>" : "") . "\n</div>\n" . $this->registry->getClass('output')->getTemplate('global')->include_highlighter() . "";
     return $IPBHTML;
 }
开发者ID:dalandis,项目名称:Visualization-of-Cell-Phone-Locations,代码行数:6,代码来源:skin_messaging.php

示例3: viewReport

 function viewReport($options = array(), $reports = array(), $comments = array())
 {
     $IPBHTML = "";
     $IPBHTML .= "" . $this->registry->getClass('output')->addJSModule("reports", "0") . "\n<script type='text/javascript'>\n\t// Editor JS: Only needs to be done once per page\n\t" . $this->registry->getClass('output')->getTemplate('editors')->editorJS() . "\n</script>\n<div class='message'>{$options['class']}\n\t{$this->lang->words['report_about_intro']} " . ($options['class'] == 'messages' ? "{$this->lang->words['report_about_pm']} {$options['title']}.\n\t\t" . (in_array($this->memberData['member_group_id'], explode(',', $this->registry->getClass('reportLibrary')->plugins['messages']->_extra['plugi_messages_add'])) ? "\n\t\t\t<a href='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("app=core&amp;module=reports&amp;section=reports&amp;do=showMessage&amp;topicID={$options['topicID']}", 'public', ''), "", "") . "'>{$this->lang->words['report_join_pm']}</a>\n\t\t" : "") . "" : "\n\t\t<a href=\"{$options['url']}\" title=\"{$this->lang->words['report_view_reported']}\">{$options['title']}</a>\n\t") . "\n</div>\n<br />\n<div class='topic_controls'>\n\t<ul class='topic_buttons'>\n\t\t" . ($this->memberData['g_access_cp'] ? "<li><a href='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("app=core&amp;module=reports&amp;section=reports&amp;do=process&amp;report_ids[{$options['rid']}]={$options['rid']}&amp;newstatus=d&amp;k={$this->member->form_hash}", 'public', ''), "", "") . "' title='{$this->lang->words['delete_report']}'><img src='{$this->settings['img_url']}/delete.png' alt='{$this->lang->words['icon']}' id='delete_report' /> {$this->lang->words['delete_report']}</a></li>" : "") . "\n\t\t<li><a href='" . $this->registry->getClass('output')->formatUrl($this->registry->getClass('output')->buildUrl("app=core&amp;module=reports&amp;section=reports&amp;do=process&amp;report_ids[{$options['rid']}]={$options['rid']}&amp;newstatus=2&amp;k={$this->member->form_hash}", 'public', ''), "", "") . "' title='{$this->lang->words['change_current_status']}' class='ipbmenu' id='change_status'>{$options['status_icon']} {$this->lang->words['current_status']} <strong>{$options['status_text']}</strong></a></li>\n\t</ul>\n</div>\n" . (is_array($options['statuses']) && count($options['statuses']) ? "\n\t<ul class='ipbmenu_content' id='change_status_menucontent'>\n\t\t" . $this->__f__ac251e769ada4781d829ec7806dc3381($options, $reports, $comments) . "\t</ul>\n" : "") . "\n<br />\n<h2 class='maintitle'>{$this->lang->words['reports_h2']}</h2>\n<div class='generic_bar'></div>\n" . ((is_array($reports) and count($reports)) ? "\n\t" . $this->__f__3df86f01baeea518c61c14a96d4ceab2($options, $reports, $comments) . "" : "") . "\n<br /><hr /><br />\n\n<h2 class='maintitle'>{$this->lang->words['comments_h2']}</h2>\n<div class='generic_bar'></div>\n" . ((is_array($comments) and count($comments)) ? "\n\t" . $this->__f__ee83adbdc57df8047ecea305fa12f7dc($options, $reports, $comments) . "" : "\n\t<p class='no_messages'>\n\t\t{$this->lang->words['no_comments_on_report']}\n\t</p>\n") . "\n<!-- SKINNOTE: Need to use included editor here -->\n" . $this->registry->getClass('output')->addJSModule("editor", "0") . "\n<br />\n<div id='fast_reply' style='display: {$displayData['fast_reply']}'>\n\t<h3 class='maintitle'>{$this->lang->words['add_comment_title']}</h3>\n\t<div class='generic_bar'></div>\n\t<div class='general_box alt'>\n\t\t<form method=\"post\" action=\"{$this->settings['base_url']}\" name=\"report_comment_submit\" id='report_comment_submit'>\n\t\t\t<input type=\"hidden\" id=\"report_rid\" name=\"rid\" value=\"{$options['rid']}\" />\n\t\t\t<input type=\"hidden\" name=\"app\" value=\"core\" />\n\t\t\t<input type=\"hidden\" name=\"module\" value=\"reports\" />\n\t\t\t<input type=\"hidden\" name=\"do\" value=\"save_comment\" />\n\t\t\t<input type='hidden' name='{$editor_id}_wysiwyg_used' value='0' />\n\t\t\t" . $this->registry->getClass('output')->getTemplate('editors')->editorShell('report_comment', 'comment') . " \n\t\t\t<fieldset class='submit'>\n\t\t\t\t<input type='submit' class='input_submit' value='{$this->lang->words['post_button']}' accesskey='s' />\n\t\t\t</fieldset>\n\t\t</form>\n\t</div>\n</div>\n" . (!$this->settings['disable_lightbox'] ? "\n" . $this->registry->getClass('output')->getTemplate('global')->include_lightbox() . "\n" : "") . "\n" . $this->registry->getClass('output')->getTemplate('global')->include_highlighter(1) . "\n<script type=\"text/javascript\">\n//<![CDATA[\n\tif( \$('report_comment_textarea') ){\n\t\t\$('report_comment_textarea').setStyle('height: 70px');\n\t}\n\t\n\tipb.editor_values.set( 'emoticons', \$H({ " . IPSLib::fetchEmoticonsAsJson() . " }) );\n\tipb.editors[ 'report_comment' ] = new ipb.editor( 'report_comment', USE_RTE );\n\tin_use = 0;\n\t" . ($rte_mode != 1 ? "\n\t\tobj = ipb.editors['report_comment'].editor_document;\n\t" : "\n\t\tobj = \$( ipb.editors['report_comment'].items['text_obj'] );\n\t") . "\n\tEvent.observe( obj, 'click', function(){\n\t\tif( in_use != 1 ){\n\t\t\t\$( ipb.editors['report_comment'] ).resize_to( 250 );\n\t\t\tin_use = 1;\n\t\t}\n\t}, true);\n//]]>\n</script>\n</if>";
     return $IPBHTML;
 }
开发者ID:dalandis,项目名称:Visualization-of-Cell-Phone-Locations,代码行数:6,代码来源:skin_reports.php

示例4: showEditor

 /**
  * Show the editor
  *
  * @access	public
  * @param	string		Raw text with bbcode
  * @param	string		Form field name
  * @return	string		Editor HTML
  */
 public function showEditor($text, $form_field = 'post_content')
 {
     //-----------------------------------------
     // INIT
     //-----------------------------------------
     $smilies = IPSLib::fetchEmoticonsAsJson($this->emo_dir);
     $total = 0;
     $count = 0;
     $smilie_id = 0;
     //-----------------------------------------
     // Load skin and language
     //-----------------------------------------
     //if ( IN_ACP )
     //{
     //-----------------------------------------
     // Sort out editor id
     //-----------------------------------------
     $this->editor_id = 'ed-' . $this->acp_editor_id;
     $this->acp_editor_id++;
     //}
     //-----------------------------------------
     // Emoticons
     //-----------------------------------------
     $this->settings['_remove_emoticons'] = $this->remove_emoticons;
     //-----------------------------------------
     // Pre parse...
     //-----------------------------------------
     $text = $this->class_editor->processBeforeForm($text);
     //-----------------------------------------
     // Weird script tag stuff...
     //-----------------------------------------
     if ($this->method == 'rte') {
         $text = preg_replace("#(<|&lt;|&amp;lt;|&\\#60;)script#si", "&amp;lt;script", $text);
     }
     //-----------------------------------------
     // Comment
     //-----------------------------------------
     if (IN_ACP) {
         $return_html = $this->registry->getClass('output')->global_template->ips_editor($form_field, $text, $this->settings['img_url'] . '/folder_editor_images/', $this->rte_on, $this->editor_id, $smilies);
         $return_html = preg_replace("#([^/\\.])js/#is", "\\1" . $this->settings['board_url'] . "/public/js/", $return_html);
         $return_html = str_replace("<#IMG_DIR#>", $this->settings['board_url'] . "/public/style_images/{$this->image_dir}", $return_html);
     } else {
         $return_html = $this->registry->getClass('output')->getTemplate('editors')->ips_editor($form_field, $text, $this->settings['img_url'] . '/folder_editor_images/', $this->rte_on, $this->editor_id, $smilies);
     }
     return $return_html;
 }
开发者ID:dalandis,项目名称:Visualization-of-Cell-Phone-Locations,代码行数:54,代码来源:han_editor.php


注:本文中的IPSLib::fetchEmoticonsAsJson方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。