WordPress.org

Ready to get started?Download WordPress

Forums

Matt's Acronym Script (18 posts)

  1. NuclearMoose
    Member
    Posted 10 years ago #

    Has anyone installed it on WP? If so, would you mind helping me figure out how to use it?
    Thanks!
    Craig.
    BTW, the script can be found here.

  2. OperaManiac
    Member
    Posted 10 years ago #

    I would like it to. Started using it pretty recently. And manually is literally a PITA.

  3. Matt Mullenweg
    Troublemaker
    Posted 10 years ago #

    For 1.0:
    Copy that function into your my-hacks.php
    Below that put add_filter('the_content', 'acronymit');
    Yay!

  4. NuclearMoose
    Member
    Posted 10 years ago #

    Except that today I am brain-dead and it looks as though I fell off the log and missed the ground. LOL!
    Is there some option I need to set to have WP use the my-hacks.php file or some code that needs to be un-commented or something?
    Sigh. Sorry to be a pain...
    Craig.

  5. Cena
    Member
    Posted 10 years ago #

    Craig, there's an option in Options->general blog settings called hack_file. Set it to yes and that should do it.

  6. NuclearMoose
    Member
    Posted 10 years ago #

    DOH!
    I would SWEAR on my goldfish's grave that I looked at EVERY option.
    Really.
    I did.
    Twice.
    No, seriously.
    :)
    Craig.

  7. seraph
    Member
    Posted 10 years ago #

    thanks Matt.

  8. seraph
    Member
    Posted 10 years ago #

    How come I'm the only celeb endorsing it by the way?

  9. Matt Mullenweg
    Troublemaker
    Posted 10 years ago #

    Good question. If you're using it, leave a note on the script page please. :)

  10. OperaManiac
    Member
    Posted 10 years ago #

    I hate my server backend. still not allowing me to take a backup of the database...
    i m yet to become a WP1.0 noobie :(

  11. tcervo
    Member
    Posted 10 years ago #

    Is anyone else having a problem with this script in the my-hacks.php file?
    It works fine...it creates the tags, works like a champ. BUT, when I go to login, I get:
    Warning: Cannot modify header information - headers already sent by (output started at E:\webs\tcervo.com\wwwroot\movies\my-hacks.php:75) in E:\webs\tcervo.com\wwwroot\movies\wp-login.php on line 122
    I've done the fixes (acording to the Alex King post, and one other...basically commenting out a couple of lines) that supposedly gets rid of the Cannot modify header error...but I'm still getting it. If I get rid of the my-hacks.php file, I can log in again. BTW, this hack is the only thing in the my-hacks.php file.
    Thanks,
    Tony

  12. Nothlit
    Member
    Posted 10 years ago #

    Tony, check for stray blank lines within your my-hacks.php file outside of the <?php ?> tags. If any exist, they're causing the server to send headers before WP is ready, hence the errors. Get rid of them!
    I'm not sure if that's exactly the problem you're having, but the same thing happened to me once before in a similar situation and this is what fixed it. :-)

  13. Jaykul
    Member
    Posted 10 years ago #

    Heh. I already had one. In fact, it's almost exactly the same. I don't sort mine, and I put it in an external file "acronyms.php" and included it, it helps keep all my content filters separate.
    /me steals a few extra acronyms

  14. tcervo
    Member
    Posted 10 years ago #

    Well I'll be...
    I had an extra line between the closing ?> of the function, and the line:
    <?php add_filter('the_content', 'abbrit'); ?>
    Got rid of that, and it's fixed....
    Thanks....

  15. tcervo
    Member
    Posted 10 years ago #

    Jaykul,
    What do you mean when you say "...my regular expression...replaces more acronyms"?
    Isn't the number of acronyms only dependent on what you put into the array? (Sorry, I'm not a PHP guru...yet ;-)
    -Tony

  16. NuclearMoose
    Member
    Posted 10 years ago #

    Jaykul,
    Would you mind posting your code for your acronym thing onto the WPHacks page of the Wiki?
    Craig.

  17. OperaManiac
    Member
    Posted 10 years ago #

    Just a small issue. Implementation of the script broke my RSS. Dunno, but since the syndication was done on the non blog pages of the site, the whole site went freaked out. Maybe I posted something nonsense in a post that might have caused that but disabling the hack file fixed the thigns for me. :(

  18. tcervo
    Member
    Posted 10 years ago #

    Just a quick note: last night I began writing a new combo acronym/abbr script. It'll read an external csv file (already built), and markup the page accordingly. Each entry will be flagged in the csv as either an acronym or an abbr. For the abbr's, the script will wrap a span around the text to make IE happy.
    I'll be unavailable the next couple days, but hope to put the finishing touches on it over the weekend.
    -Tony

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.