Support » Plugin: Simple Ajax Chat » Plugin translation

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Jeff Starr

    (@specialk)

    That’s in the JavaScript file (I think..) – will have to investigate if it’s translatable or not..

    Thanks for your help Jeff.
    I found something in “simple-ajax-chat-form.php”

    I edit this way:

    <div id=”sac-latest-message”><span><?php _e(‘Último mensaje:’, ‘sac’); ?></span> <em id=”responseTime”> hace <?php echo sac_time_since($r->time); ?></div>
    <ul id=”sac-messages”>

    So text in now PARTIALLY in spanish before sending a message. But once a message is sent I have the “0 minutes ago” text again.

    I guess I did it editing:
    “simple-ajax-chat-core.php”

    // time since entry
    function sac_time_since($original) {
    $chunks = array( // unix time (segundos)
    array(60 * 60 * 24 * 365 , ‘año’),
    array(60 * 60 * 24 * 30 , ‘mes’),
    array(60 * 60 * 24 * 7, ‘semana’),
    array(60 * 60 * 24 , ‘día’),
    array(60 * 60 , ‘hora’),
    array(60 , ‘minuto’),

    I still need to find how to modify “ago” word showed after message is published.

    Done!

    $loop = $id .”—” . $name . “—” . $text . “—” . sac_time_since($time) . ” atrás—” . $url . “—“;

    Hope this custom solutions helps someone else.

    Plugin Author Jeff Starr

    (@specialk)

    These are all localized in the latest version of the plugin (20131105). Cheers!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Plugin translation’ is closed to new replies.