WordPress Comments Se Auto Linking URLs Ko Disable Kaise Kare

Jab koi user WordPress blog par comment box me plain text URL add karta hai to WordPress use automatically clickable link bana deta hai. Jisse blog admin ko manually comments me se links remove karna hota hai. Aaj main aapko aesi trick bta raha hu jisse aap WordPress comments me se Auto Linking ko disable kar sakte ho or apna valuabl time bachane ke sath blog ko spam links attack se bhi secure kar sakte ho.

Disable auto linking URLs in WordPress comments

WordPress comment section me text link ko clickable link me convert isiliye karta hai taki blgo admin and other person ko comment karne wali ki site ya blog par visit karne me aasani ho. But problem tab hoti hai jab aapke blog par Spam Comments aati hai. Hum sab jante hai ki ek spam links se humari site par kya bad effect padta hai. So agar aapke blogpar bh ispam comments aate hai to aapko auto linking URLS ko disable kar dena chahiye.

Aapke auto linking ko disable karne ke bad jab koi user aapke blog par comment karega or comment me koi link mention karega to wo link automatically remove ho jayega or only uska text version hi comment me show hoga. Iske bad aapke blog ko spam comments se problem nahi hogi.

Isse aapko 2 benefits hai ek wo user jo only promotion ke liye comment karte hai comment nahi karenge or aapke blog par spam comments bhi kam ho jayenge. So main aapko suggestion karunga ki aap bhi is feature ka istemal kare or apne blog ki security me ek point or laga de.

Aap chahe to iske liye No comments links plugin bhi use kar sakte hai. Ye unke liye better hai jo manually auto linking ko off nahi karna chahate.

WordPress Blog Ki Comments Se Spam Links Ko Remove Kaise Kare – Disable Auto Linking URLs

WordPress Comments se auto linking URL ko disable karne ke kei tarike hai but main aapko sabse first me bahut hi short tarika btaunga. Aapko bas ye code apne blog ki functions.php me add karna hai.

1. Simple Plain Text Links:

WordPress Dashboard >> Appearance >> Editor par jaye or ye code copy kar Functions.php folder me paste kare.

//Disable URL Auto-Linking in WordPress Comments
remove_filter( 'comment_text', 'make_clickable', 9 );

Iske bad comments me plain text URL add karne par wo clickable link me change nahi hoga. I mean ab aapke blog par comment me koi user link add karega to wo plain text m hi show hoga or clickable link me convert nahi hoga. By the way agar aap kabhi auto linking ko enable karna chahe to functions.php file se in code ko remove karsakte hai.

Yaad rahe ye code sirf plain text URLs ke liye work karega. Agar user comment me HTML tag se link add karega to ye trick kaam nahi karegi. HMTL tag se link add karne se comment me link show hoga. Ise block karne ke liye aapko other code use karna hoga.

2. HTML Tag Links:

First aap only plain text link ko remove kare to kafi hoga but agar aap completely comments me se ULRs ko remove karna chahate ho to aap ye method follow kare.

How to Disable HTML in WordPress Comments:

WordPress Dashboard >> Appearance >> Editor option par jaye or ye code copy kar Functions.php folder me paste kare.

// This will occur when the comment is posted
 function plc_comment_post( $incoming_comment ) {
// convert everything in a comment to display literally
 $incoming_comment['comment_content'] = htmlspecialchars($incoming_comment['comment_content']);
// the one exception is single quotes, which cannot be #039; because WordPress marks it as spam
 $incoming_comment['comment_content'] = str_replace( "'", ''', $incoming_comment['comment_content'] );
return( $incoming_comment );
 }
// This will occur before a comment is displayed
 function plc_comment_display( $comment_to_display ) {
// Put the single quotes back in
 $comment_to_display = str_replace( ''', "'", $comment_to_display );
return $comment_to_display;
}

Iske bad aapki site par comments me koi bhi html code add karne par work nahi karega. Agar aap is process ko manually nahi karna chahate to aap Peter’s Literal Comments plugin ka istemal kar sakte ho.

Is tarah se aap WordPress blog ki comments me se auto linking URLs ko disable kar spam links ko remove kar sakte ho. Ab koi bhi aapki site par plain text link ya HTML links add anhi kar sakega.

I hope aapko ye article pasand aayega agar haa to ise social media par other blogger ke sath share jarur kare.

Avatar for Jumedeen Khan

by: Jumedeen Khan

मैं इस ब्लॉग का संस्थापक और एक पेशेवर ब्लॉगर हूं। यहाँ पर मैं नियमित रूप से अपने पाठकों के लिए उपयोगी और मददगार जानकारी शेयर करता हूं। ❤️

Comments ( 24 )

  1. Jumedeen Khan Sir Aapka Blog Bahut Hi Badhiya Hai. Blogger Aur Internet Users Ke Liye Bahut Kuch Hai Is Blog Par Aur Aapki Post Bhi Kaafi Informative Hai. Keep It Up Bro.

    Mera Bhi Ek Blog Hai, techtofollow.com Ek Baar Aap Visit Kar Ke Btaye Ki Mere Blog Me Kahi Koi Sudhar Karna Chahiye Ya Nahi? Waiting For Your Response ?

    Reply
    • No suggestion bro aapka blog must hai.

      Reply
  2. कुछ दिनों पहले मैंने अपने blogger blog को WordPress move किया जिसके बाद कोई जानकारी बाकि रहे गयी थी वो आजके इस post से मिल गयी ।।।।

    Reply

Leave a Comment