Support » Fixing WordPress » Greg’s Comment Length Limiter – how to insert PHP function in textarea tag?

  • I’ve read that you’re supposed to insert a PHP function, called gcll_tweak_textarea();, inside of the textarea tag in comments.php. Not between the tags, but inside. Problem is, I have no idea how to run a PHP function from within an HTML tag, and can’t find mention of doing so anywhere.

    Any ideas?

Viewing 4 replies - 1 through 4 (of 4 total)
  • This is actually pretty easy, since all the theme files you have are PHP files, all you have to do is paste this into the code as you were instructed: <?php gcll_tweak_textarea(); ?>

    So, according to the instructions I would find the textarea and make it look like this:

    <textarea><?php gcll_tweak_textarea(); ?>

    That should do the trick

    That’s what I had thought initially, but that puts the following text into the comment box:

    onkeydown="gcllCounter(this)" onkeyup="gcllCounter(this)"

    Any ideas? The developer doesn’t seem to be available for assistance, which is a shame.

    Ahh, I see what is going on. Instead of what I said before:
    <textarea><?php gcll_tweak_textarea(); ?>
    do this:
    <textarea <?php gcll_tweak_textarea();?>>

    Where the closing “>” for textarea is after the php function.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Greg’s Comment Length Limiter – how to insert PHP function in textarea tag?’ is closed to new replies.