Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Comments, trackbacks & pings (http://forum.bytesforall.com/forumdisplay.php?f=19)
-   -   [SOLVED] Trying to insert a link into the comment form... (http://forum.bytesforall.com/showthread.php?t=18131)

deepskyblue Aug 7, 2012 11:20 AM

[SOLVED] Trying to insert a link into the comment form...
 
Hi All,

I've been browsing around here for quite some time since starting my website and this forum has been increadibly helpful. I've run into something though that is a bit above my skill level, as I no nothing about php coding.

I'm trying to add a small amount of text with a link to the comment form. My site is www.diyallday.com

From reading another post where someone was trying to do something similar it looks like the way to do it is by editing the comments.php file in this code:

PHP Code:

if ($bfa_ata['show_xhtml_tags'] == "Yes") {    
    
$comment_notes_after '
        <p class="thesetags clearfix">' 

        
sprintf(__('You can use %1$sthese HTML tags</a>','atahualpa'),
        
'<a class="xhtmltags" href="#" onclick="return false;">') . '</p>
        <div class="xhtml-tags"><p><code>' 
allowed_tags() . '
        </code></p></div>'
;
} else {
    
$comment_notes_after '';



I'm trying to add the text "Please review our Comment Rules" with "comment rules" linked to my comment rules page.

I want that sentence to appear immediatly before the sentence "you can use these html tags."

Also is it wise to update the code in the editor in wordpress or is there a better way to do it?

Any help is much appreciated.

-deepskyblue

juggledad Aug 7, 2012 12:35 PM

Change it to
HTML Code:

if ($bfa_ata['show_xhtml_tags'] == "Yes") {       
        $comment_notes_after = 'Please review our <a href="http://yourdomain.com/page-your-want-to-link-to2/">Comment Rules</a><br />
                <p class="thesetags clearfix">' .
                sprintf(__('You can use %1$sthese HTML tags</a>','atahualpa'),
                '<a class="xhtmltags" href="#" onclick="return false;">') . '</p>
                <div class="xhtml-tags"><p><code>' . allowed_tags() . '
                </code></p></div>';
} else {
        $comment_notes_after = '';
}


deepskyblue Aug 7, 2012 01:07 PM

It works perfectly. Thank you so much!

-deepskyblue


All times are GMT -6. The time now is 03:48 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.