Ejemplo n.º 1
0
<?php

/**
 * OhYesChat
 * @website Link: https://github.com/lianglee/OhYesChat
 * @Package Ohyes
 * @subpackage Chat
 * @author Liang Lee
 * @copyright All right reserved Liang Lee 2014.
 * @ide The Code is Generated by Liang Lee php IDE.
 */
$latest = OhYesChat::getLatest(4);
$chat = new OhYesChat();
foreach ($latest as $message) {
    $icon = elgg_view("icon/default", array('entity' => get_user($message->sender), 'size' => 'small'));
    ?>
  <div class="messages-item"  style="border-bottom: 1px solid #EEE;padding: 8px;">
      <div class="icon"  style="display:inline-table;">
        <?php 
    echo $icon;
    ?>
      </div>
      <div class="text" style="display:inline-table;position: absolute;padding: 10px;width:200px;">
      <?php 
    echo OhYesChat::replaceIcon($chat->sttl($message->message, 20));
    ?>
      </div>
  </div>
  
  <?php 
}
Ejemplo n.º 2
0
 * Ohyes Theme
 * @website Link: https://github.com/lianglee/OhYesTheme
 * @Package Ohyes
 * @subpackage Theme
 * @author Liang Lee
 * @copyright All right reserved Liang Lee 2014.
 * @ide The Code is Generated by Liang Lee php IDE.
*/
$user = elgg_get_logged_in_user_entity()->guid;
$get = "SELECT DISTINCT sender FROM prefixes_ohyes_chat WHERE(reciever='{$user}' AND view='0')";
$messages = OhYesChat::Data($get, 'get');
foreach ($messages as $friend) {
    $friend = get_user($friend->sender);
    $icon = elgg_view("icon/default", array('entity' => $friend, 'size' => 'tiny'));
    ?>
      <div class="friends-list-item" onClick="OhYesChat.newTab(<?php 
    echo $friend->guid;
    ?>
);"> 
                  <div class="icon" style="display: inline-table;"> <?php 
    echo $icon;
    ?>
</div>
                  <div class="name" style="display: inline-table;margin-top: -8px;margin-left: 5px;"><?php 
    echo OhYesChat::sttl($friend->name, 23);
    ?>
</div>  
                </div>
                
                <?php 
}
Ejemplo n.º 3
0
               <div class="ohyeschat-message-sending"><div class="OhYesChat-Icon-LoadingSmall"></div></div>
               <div class="options OhYesChat-Inline-Table" style="margin-left: 225px;height: 27px;margin-top: 2px;width: 22px;background: #FFF;position: absolute;">
                        <div class="OhYesChat-Inline-Table OhYesChat-Icon-Smilies" onClick="OhYesChat.ShowSmilies(<?php 
echo $vars['friend']['guid'];
?>
);" style="margin-top: 5px;"></div>
                </div>
               <input type="hidden" name="friend" value="<?php 
echo $vars['friend']['guid'];
?>
" />
               </form>
                </div>
                <div class="ohyeschat-new-message">
                              <div class="OhYesChat-Icon-NewMessage" style="display:inline-table;"></div>
                              <div class="text"  style="display:inline-table;"></div>
                        </div>     
            <div class="<?php 
echo OhYesChat::getStatusClass($vars['friend']['guid']);
?>
 ohyeschat-uinfo" id="ohyeschat-ustatus-<?php 
echo $vars['friend']['guid'];
?>
">
                        <div class="OhYesChat-Tab-Text" style="display:inline-table;"><?php 
echo OhYesChat::sttl($vars['friend']['name'], 17);
?>
</div>
            </div> 
          </div>
     </div>