Komentar Threaded Brian: Dioptimalkeun

Salah sahiji plugins anu kuring resep ngajalankeun dina blog abdi nyaéta Komentar Threaded Brian. Éta ngamungkinkeun komunikasi pikeun saré, teratur sareng gampang pisan dibaca sareng diréspon. Kuring henteu yakin naha logika na teu acan ditarik kana inti WordPress, Sanajan.

Nalika kuring ningali sumber halaman kuring, sanaos, plugin na nambihan rada kacau. Pluginna nyisipkeun Javascript sareng tag gaya supados tiasa dianggo. Masalahna nyaéta gaya inline sareng javascript tiasa ningkatkeun waktos beban kusabab styleheets anu numbu sareng file javascript tiasa di-cache sakali ku browser.

Kusabab bot pamilarian ngindeks jumlah 'x' luhur halaman, kode sapertos ieu ngadorong eusi nyata turun. Kuring henteu kantos nguping éta kabuktosan, tapi kuring yakin ieu tiasa mangaruhan Search Engine Optimization situs anjeun. Cara anu leres pikeun tuang Search Engine nyaéta ngaliwat topping sareng nyayogikeun langkung seueur daging. Kuring ngan ukur éta sareng mindahkeun Javascript boh CSS kana file anu numbu. Kuring ngajalankeun plugin anu dioptimalkeun di dieu.

Kuring parantos nyerat Brian dina plugin anu dioptimalkeun, tapi emailna mantul. Kuring ogé miceun anjeunna tip tina blog kuring pikeun ningali naha anjeunna bakal mampir. Upami anjeun resep, anjeun tiasa unduh plugin anu dioptimalkeun Ieuh.

8 Komentar

  1. 1

    Thank you very much for posting this file!
    I briefly (less than ten minutes) dipped my toe into Intense Debate because easily installed threaded comments appealed.. Much as I love tooling out my site, their system was too much to put up with for this luxury alone.

  2. 2

    I was looking at your files in the zip and it looks really good, however someone beat you to the punch back in April. Check out pos ieu.

    Something else to improve upon would be having the images local verses having them called from an external location with some sort of encrypted code, at least that’s what it looks like around the lines where it calls the png images.

    Pikiran?

  3. 4

    Hi Doug,
    Thanks for this?I was about to endeavor to do the exact same thing, you saved me the time.

    I had to add a few functions from Brians Threaded Comments 1.5 that were breaking your iteration.
    Di luhur btc_add_reply_id($id):

    function btc_has_avatars() {
    if( function_exists('get_avatar'))
    return true;
    else if(function_exists('MyAvatars'))
    return true;
    return false;
    }

    function btc_avatar() {
    if( function_exists('get_avatar')) {
    echo get_avatar(get_comment_author_email(), '64');
    return;
    }
    else if(function_exists('MyAvatars')) {
    MyAvatars();
    return;
    }
    }

    I also added a little CSS from BTC 1.5 to the .css file:

    .btc_gravatar {
    float: right;
    margin: 3px 3px 4px 4px;
    }
    .collapsed .btc_gravatar { display:none; } /* I added this, since the gravatars weren't collapsing nicely */

  4. 5

    This is great, Doug! One issue: It seems that the plugin now wants to be in the briansthreadedcomments subfolder of plugins, but a few of the images are rendered by accessing the PHP file in the plugins directory (when a user has subscribed to email alerts, for example). I worked around this by having the PHP file in both places. Probably just needs to have a URL adjusted somewhere in the code.

  5. 8

Naon anu anjeun pikirkeun?

Situs migunakeun Akismet pikeun ngurangan spam. Diajar kumaha komentar data anjeun diolah.