2

I'm trying to customize the comment reply link to direct the user to the comment submission form on the same page. I've tried:

<?php 
$content['links']['#links']['comment-reply']['href'] = '#edit-comment-body-und-0-value';
?> 

in my comment.tpl.php, but no luck. Also I need to add a JavaScript onclick to make the comment body in focus and add the user name of the user being replied to.

What should I do?

4

Have a look at the code of the AJAX comments module. It does simmilar things. There's a good chance that you can learn from theire code.

  • 1
    Thanks, I just ended up using the ajax comments module, its exactly what I needed. – oobie11 Jan 27 '12 at 23:03

Not the answer you're looking for? Browse other questions tagged or ask your own question.