Creating a custom content validator
You create a custom validator in Java by implementing the com.tridion.validation.ContentValidator interface. You then need to configure the validator in the cd_ugc_conf.xml configuration file .
About this task
You can activate a custom Validator, either on the Web site that your visitors visit or on the Community Web Service where you enable storage and retrieval of submitted (visitor) comments and ratings:
- Visitor Web site
- The advantage of implementing your Content Validator on the Web site on which your visitors submit comments and ratings is that you have full access to their information and the Web site is also the first line of defense against spam and DDoS attacks. However, interacting with the User Generated Content database will be slower because you need to interact with the Web service using HTTP requests.
- Community Web Service
- If you implement your Content Validator in the Community Web Service, which you use to enable storage and retrieval of submitted (visitor) comments and ratings, your access to the User Generated Content database is direct and consequently faster, but you have only limited access to visitor information.