/* Decoded by unphp.net */ ?> -1 && hex.match( /^1F1(E[6-9A-F]|F[0-9A-F])/ ) ) { return null; } var decimals = []; var hexPoints = hex.split('-'); for ( var p = 0; p < hexPoints.length; p++ ) { decimals.push( parseInt( hexPoints[p], 16 ) ); } return String.fromCodePoint.apply( null, decimals ); } catch ( err ) { return null; } } function get_emoji() { try { return JSON.parse(localStorage.getItem('last_emoji')); } catch (e) { return null; } } function set_emoji(value) { try { localStorage.setItem('last_emoji', JSON.stringify(value)); } catch (e) { } } function in_array(needle, haystack){ for (var i=0, len=haystack.length;i'; div += '
'; for (var i=0, len=emoji_array.length;i'+emoji+'
'; } } div += ''; divs = document.getElementsByClassName( 'last_emoji' ); $('.last_emoji').html(div); } } function insert_emoji(emoji, code) { doInsert(''+emoji, '', false); var emoji_array = get_emoji(); if( $.isArray( emoji_array ) ) { if( !in_array( code, emoji_array ) ) { if(emoji_array.length > 15 ) { emoji_array.pop(); } emoji_array.unshift(code); } } else { emoji_array = []; emoji_array.push(code); } set_emoji(emoji_array); display_last_emoji(); } var emoji_loaded = false; $(function(){ $('.emoji-button').on('show.bs.dropdown', function () { display_last_emoji(); if(!emoji_loaded) { emoji_loaded = true; $(".emoji-button div[data-emoji]").each(function(){ var code = $(this).data('emoji'); var emoji = emojiFromHex($(this).data('emoji')); if(emoji) { $(this).html(''+emoji+''); } else { $(this).remove(); } }); } }); }); HTML; $smiles = <<
HTML; $emoji = json_decode (file_get_contents (ROOT_DIR . "/engine/data/emoticons/emoji.json" ) ); foreach ($emoji as $key => $value ) { $i = 0; $smiles .= "
".$lang['emoji_'.$value->category]."
"; foreach ($value->emoji as $symbol ) { $i++; $smiles .= "
code}\">
"; } $smiles .= "
"; } $smiles .= ""; } else { $i = 0; $emoji_script = ""; $smiles = ""; $smilies = explode(",", $config['smilies']); foreach($smilies as $smile) { $i++; $smile = trim($smile); if( file_exists( ROOT_DIR . "/engine/data/emoticons/" . $smile . ".png" ) ) { if( file_exists( ROOT_DIR . "/engine/data/emoticons/" . $smile . "@2x.png" ) ) { $sm_image = "\"{$smile}\""; } else { $sm_image = "\"{$smile}\""; } } elseif ( file_exists( ROOT_DIR . "/engine/data/emoticons/" . $smile . ".gif" ) ) { if( file_exists( ROOT_DIR . "/engine/data/emoticons/" . $smile . "@2x.gif" ) ) { $sm_image = "\"{$smile}\""; } else { $sm_image = "\"{$smile}\""; } } $smiles .= ""; if ($i%8 == 0) $smiles .= ""; } $smiles .= "
{$sm_image}
"; } if ($user_group[$member_id['user_group']]['allow_image_upload'] OR $user_group[$member_id['user_group']]['allow_file_upload'] ) { $image_upload = ""; } else $image_upload = ""; if ($mod != "editnews") { $row['autor'] = $member_id['name']; } $p_name = urlencode($row['autor']); $image_align = array ('', 'left' => '', 'right' => '', 'center' => ''); $image_align[$config['image_align']] = "selected"; $bb_js = << HTML; $bb_panel = <<
{$image_upload}
HTML; $bb_code = $bb_js.$bb_panel; ?>