Deleting bad words

  Previous topic Next topic JavaScript is required for the print function Mail us feedback on this topic! Mail us feedback on this topic!  

This sample code explains how a single bad word can be deleted from the system database.

 

[C#]

 

using CMS.SiteProvider;

 

...

 

        // First get the bad word info by its ID

        BadWordInfo bwi = BadWordInfoProvider.GetBadWordInfo(1);

 

        if (bwi != null)

        {

            // Delete the bad word

            BadWordInfoProvider.DeleteBadWordInfo(bwi);

        }

 

Page url: http://devnet.kentico.com/docs/5_5r2/devguide/index.html?api_deleting_bad_words.htm