Creating The XML File

For the example we're going to create a new attribute called hogtied for extreme bondage with suspension or similar scenarios. Of course this is not an attribute you'd expect to need in a conventional site which is why it is not part of the normal WACS attributes system. It is therefore perfect to illustrate the flexibility and customisability of the WACS system.

As a general guideline we suggest that custom added attributes be given entry numbers of 500 or higher. If working on multiple sites, only some of which use these attributes, it's worth keeping the entry numbers unique. Let's start with the basic bones of our XML extra attributes file - we'll call the file oursite-attrib.xml:

<?xml version="1.0" standalone='yes'?>
<attrib>
 <coreschema>attrib</coreschema>
 <version>WACS_POPULATE_VERSION_2</version>
 <revisiondate>22-APR-2016</revsiondate>
 <entry501>
  <atkeyword>hogtied</atkeyword>
  <atsource>C</atsource>
  <atshortdesc>rope bondage and suspension<atshortdesc>
  <atlongdesc>extreme rope bondage and suspension<atlongdesc>
  <aticon>icon3-501.png<aticon>
  <atgroup>objects<atgroup>
 </entry501>
</attrib>

Aside from the various bits of XML preamble which are just standard and what wacspop uses to determine which table this belongs to and the entry number to assign to it, we have six main fields here. The atkeyword defines the keyword for this attribute, atsource defines this as a custom extension ( C, and the atshortdesc and atlongdesc provide a definition of this attribute. The aticon defines the name of the associated icon for this attribute which by convention begins with "icon3-" and is in the PNG format. You will obviously need to create your own artwork for your new attribute. The atgroup parameter just helps group the attribute - in this case object because a thing (the hogtying ropes) really define the set. Other attributes within the object group are strapon, weapon, transport, bondage and fetish.

The above entry is highly simplified, and while it could be added to the database would have no effect as it stands because WACS would not know what to do with it. So we need to add some extra lines that start providing that information:

  <atsource>C</atsource>
  <atrecognise>Y</atrecognise>
  <atallowadd>Y</atallowadd>
  <atdisplay>Y</atdisplay>
  <atshortdesc>rope bondage and suspension<atshortdesc>

This little group copes with how the attribute marking tools will deal with this new attribute. atrecognise basically says whether it should be allowed to remain as an attribute or throw an error when it's encountered. This could be set to N to force the removal of an old attribute the next time the set is edited. atallowadd controls whether you are allowed to add this attribute to a set through wacssetmgr or through keyword scoring. It is possible to add something that is not displayed, and this is where the final one comes in - if atdisplay is set to N you can add attributes without them being visible to users on the live system. This can be very useful when marking content up prior to launching a new feature.

This is still not the complete story because although we've dealt with the rules of how WACS handles the attribute, we have not told it when it can use it and how.