CREATING A NEW CONTENT TYPE
1. Create a folder named CustomRating in the FEATURES directory.
2. Create a xml file named feature.xml that contains the following information:
Create a xml file named comments.xml that contains the following information:
4. Here we are defining basic attributes for our content type and the site columns that we will be using. One important piece of information is the ID attribute. This tells us that our content type is based on the content type with ID 0×01, the ‘Item’ content type. The FEATURES\ctypes folder can be used to find the ID’s of system content types we might want to use as a base. You should also check that the ID of your new content type is unique.
Another important point to note is that the FieldRef ID‘s must match ID’s for existing site columns
5. Install the Feature using the Following stsadm command
stsadm -o installfeature -filename CustomRating\feature.xml -force
6. Activate the Feature for a Sitecollection using the following command a xml file named
stsadm -o activatefeature -filename CustomRating\feature.xml -url http://localhost





No comments:
Post a Comment