[This local archive copy mirrored from the canonical site: http://www.4thworldtele.com/public/design/rsdesign.html, text only; links may not have complete integrity, so use the canonical document at this URL if possible.]

REAL ESTATE DTD DESIGN CONSIDERATIONS

4/16/98
4thWORLD Telecom
 
 

OVERVIEW

The real estate DTD(s) needs to work with several different user types; those making MLS entries using custom software (such as OpenMLS), those making MLS entries with standard XML editors, and those who are simply making a web site (separate from MLS entry).  With these scenarios, the DTD must balance the detail needed in the MLS with the simplicity that web developers desire. In addition, there are no MLS form guidelines given by the NAR (although they may currently be working on some). Therefore a very general purpose MLS form must be distilled from the customized documents that the various Board of Realtors will produce with this DTD. [Please see "MLS Handbook" published by the NAR]
 

RESIDENTIAL LISTING DTD

<!--   Parameter Entities  --> 
<!ENTITY % OTHER "OTHER"> 
<!ENTITY % NAME "NAME"> 
<!ENTITY % ACZ "ADDRESS?,CITY?,ZIP?"> 
<!ENTITY % PFW "PHONE?,FAX?,WEB?"> 

<!--   Notation Declarations   --> 
<!NOTATION gif SYSTEM "gview.exe"> 
<!NOTATION jpeg SYSTEM "http://www.viewers.org/jview.exe"> 
<!NOTATION mov SYSTEM "http://www.viewers.org/mview.exe"> 

<!ELEMENT RESIDENTIAL-LISTING (GENERAL,FEATURES,FINANCIAL,REMARKS,CONTACTS) > 
 

<!-- -------------------------------------------------------------------------  --> 
<!ELEMENT GENERAL (IMAGE*,MLS-CODE?,TYPE,PRICE,AGE,LOCATION,STRUCTURE,DATE,LAND-AREA,STATUS,(%OTHER;)?,TERMS*)* > 
<!--The IMAGE element does not include X and Y positions for the placement will more than--> 
<!--likely be handled by XSL or CSS.--> 
<!ELEMENT IMAGE EMPTY > 
<!ATTLIST IMAGE 
FORMAT NOTATION (GIF|JPEG|MOV) #REQUIRED 
WIDTH    CDATA    #REQUIRED  
HEIGHT    CDATA    #REQUIRED 
SRC    CDATA    #REQUIRED > 

<!ELEMENT MLS-CODE (#PCDATA) > 
<!ATTLIST MLS-CODE  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 

<!ELEMENT TYPE (#PCDATA) > 

<!ELEMENT PRICE (#PCDATA) > 

<!ELEMENT AGE (#PCDATA) > 
<!ATTLIST AGE 
UNITS    (YEARS|MONTHS) "YEARS"> 

<!ELEMENT LOCATION (%ACZ;,ROUGH?) > 
<!ATTLIST LOCATION  
COUNTRY    CDATA    #REQUIRED 
STATE    CDATA    #REQUIRED  
COUNTY    CDATA    #REQUIRED  
SECURITY  (MLS-Only|Restricted|Public) "Public" > 

<!ELEMENT ROUGH (#PCDATA) > 

<!ELEMENT STRUCTURE ((NUM-BEDS|NUM-BATHS|BUILDING-AREA|ADD-INFO)*) > 

<!ELEMENT NUM-BEDS (#PCDATA) > 

<!ELEMENT NUM-BATHS (#PCDATA) > 

<!ELEMENT BUILDING-AREA (#PCDATA) > 
<!ATTLIST BUILDING-AREA 
UNITS    (SQ-METRES|SQ-FEET) "SQ-FEET" > 

<!ELEMENT ADD-INFO (#PCDATA) > 

<!ELEMENT DATE (#PCDATA) > 

<!ELEMENT LAND-AREA (#PCDATA) > 
<!ATTLIST LAND-AREA 
UNITS    (HECTARES|ACRES) "ACRES" > 

<!ELEMENT STATUS (#PCDATA) > 

<!ELEMENT TERMS (#PCDATA) > 
<!ATTLIST TERMS  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 
 
 

<!-- -------------------------------------------------------------------------  --> 
<!ELEMENT FEATURES (DISCLOSURES,UTILITIES,EXTRAS,CONSTRUCTION,ACCESS,(%OTHER;)?) > 
  
<!ELEMENT DISCLOSURES (#PCDATA) > 

<!ELEMENT UTILITIES (#PCDATA) > 

<!ELEMENT EXTRAS (#PCDATA) > 

<!ELEMENT CONSTRUCTION (#PCDATA) > 

<!ELEMENT ACCESS (#PCDATA) > 
 
 
 
 

<!-- -------------------------------------------------------------------------  --> 
<!ELEMENT FINANCIAL (ASSUMABLE,OWNER-CARRY,ASSESMENTS,DUES,TAXES,LENDER,EARNEST,DIRECTIONS,(%OTHER;)?) > 

<!ELEMENT ASSUMABLE (#PCDATA) > 
<!ATTLIST ASSUMABLE  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 

<!ELEMENT OWNER-CARRY (#PCDATA) > 
<!ATTLIST OWNER-CARRY  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 

<!ELEMENT ASSESMENTS (#PCDATA) > 
<!ATTLIST ASSESMENTS  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 

<!ELEMENT DUES (#PCDATA) > 
<!ATTLIST DUES  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 

<!ELEMENT TAXES (#PCDATA) > 
<!ATTLIST TAXES  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 

<!ELEMENT LENDER (#PCDATA) > 
<!ATTLIST LENDER  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 

<!ELEMENT EARNEST (#PCDATA) > 
<!ATTLIST EARNEST  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 

<!ELEMENT DIRECTIONS (#PCDATA) > 
<!ATTLIST DIRECTIONS  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 
 
 
 

<!-- -------------------------------------------------------------------------  --> 
<!--This is the freeform desciption section, the general impressions of the property--> 
<!--The aspects of the property that make it special--> 
<!ELEMENT REMARKS (#PCDATA) > 
 
 

<!-- -------------------------------------------------------------------------  --> 
<!ELEMENT CONTACTS (COMPANY?,AGENT+,OWNER?,TENANT?,COMMISSION+) > 

<!ELEMENT COMPANY (%NAME;,%ACZ;,%PFW;) > 

<!ELEMENT AGENT (%NAME;,%ACZ;,%PFW;) > 

<!ELEMENT OWNER (%NAME;,%ACZ;,%PFW;) > 
<!ATTLIST OWNER  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 

<!ELEMENT TENANT (%NAME;,%ACZ;,%PFW;) > 
<!ATTLIST TENANT  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 

<!ELEMENT COMMISSION (#PCDATA) > 
<!ATTLIST COMMISSION  
SECURITY  (MLS-Only|Restricted|Public) "MLS-Only" > 
 

<!ELEMENT OTHER (#PCDATA) > 

<!ELEMENT NAME (#PCDATA) > 

<!ELEMENT ADDRESS (#PCDATA) > 

<!ELEMENT CITY (#PCDATA) > 

<!ELEMENT ZIP (#PCDATA) > 

<!ELEMENT PHONE (#PCDATA) > 

<!ELEMENT FAX (#PCDATA) > 

<!ELEMENT WEB (#PCDATA) > 
 

<!ENTITY lt "<"> 
<!ENTITY gt ">"> 
<!ENTITY apos "'"> 
<!ENTITY amp "&"> 
 

 

GENERAL STRUCTURE

There will be a separate DTD for each of the major property categories; commercial, residential, vacant-land, working-land. Each of these DTDs will be divided into four or five major sections. For example, the commercial DTD has GENERAL, FEATURES, FINANCIAL, REMARKS, CONTACTS as the major sections. In this case, GENERAL is used for the general information such as location, price and size. Security is a big issue and is describe in greater detail below. Essentially, the agent can give security attributes to any tag, thereby defining what can be used in a public web site. The REMARKS section is where an agent can write a free form description of the property and should appear in every DTD category. In a typical web site application of the document, the REMARKS contents could by displayed next to any images of the property followed by any public MLS information.
 

INTENDED CONTENT FOR TAGS

It is very important that the given tags be used for their intended content. For many of the tags, it is clear what sort of information the should contain. the PRICE element clearly contains the price for the property. What might not be clear is that it should only contain the price number and not even the monetary sign ($).  Some of the tags may be open to confusion due to their brevity. The following should help.

The following should contain numbers and nothing else. Strong typing (integer, float, etc.) is not in the current XML specification, but workarounds via namespaces and XML-Data should help to type certain elements. The following are out of the RESIDENTIAL DTD. Other DTDs have slightly different element names, but the idea is the same. Although other elements may contain only numbers, such as DUES, the following are critical for they will be searched on as a major criteria for properties.

HANDLING CUSTOM TITLES

Users should be able to change the title and this would appear as an attribute in the element tag. Most of the tag names are very short and generic. Many Boards of Realtors will want to modify them in their MLS entry. This information should appear in the resulting MLS document. There may be multiple items in a tag. Each item should be separated by a character that clearly indicates that these are separate items. As an example I have used a semi-colon as this seems more effective than a comma.
 

<FEATURES> 

 <DISCLOSURES  TITLE="Special Disclosures"> 
  Private Road; Probate 
 </DISCLOSURES> 

 <ACCESS  TITLE="Security"> 
  Perimeter Sensors;Dogs;Armed Guards 
 </ACCESS> 

</FEATURES> 

Notice the ACCESS tag has been re-titled to "Security." Although ACCESS was intended for vehicle access, the user can modify the title to change the intent of the tag. They should be aware that putting in information that is greatly different from the intent of the tag only obfuscates their document when it is indexed against standard tag elements.

HANDLING CUSTOM FIELDS

Since there is no standardized MLS, each Board of Realtors develops their own to fit the needs of their geographical area. It is therefore necessary to provide these boards with the ability to customize their input. This is OpenMLS's plan and it makes sense that other MLS software programs that use this DTD will do the same. We cannot allow the creation of custom XML tags as this will create invalid documents (that do not match the DTD).  It seems that the solution is to allow the users to create custom database "fields" that are contained within a particular tag. These are not fields in a strict DB sense, but simply general headings and their contents. These entries should have a standard way of separating a custom field from its contents as well as a standard way of separating multiple custom fields contained within a tag.  The separators should make sense so that in their rawest format, an unfamiliar human reader could make sense of the information. In the example below, the fields and their contents are separated by an ellipsis. Multiple fields are separated by semicolons and carriage returns. At first glance you may feel that field and contents should be separated by a colon. However, Namespaces may use colons in a very similar manner and it may be confusing to the human reader.

NOTE: the OTHER tag is the catch-all tag. It appears in all major sections and in all DTDs. Also, in the interest of clarity, not all of the attributes that might be used with these tags are given in the examples below. Also note that tags can have a null content value or none. Thus tags can appear as necessary in the DTD but as an option be filled with "n/a" or "none."

 
  <FEATURES> 
 <OTHER TITLE="Special Features"> 
  Shipping Doors...3 ;  
  Energy Rating...5 Star ;  
  Substructure...Below Grade Basement; 
  Substructure...Slab; 
 </OTHER>  
 <CONSTRUCTION TITLE="Construction Materials"> 
  Roof...Metal ;  
  Walls...Rock ;                                                   Floors...Wood ;  
  </CONSTRUCTION>  
</FEATURES>
As the sample output below shows, documents can be formatted to suit the needs of the end user.
 
         
    Special Features  
      Shipping Doors...3  
      Energy Rating....5 Star  
      Substructure.....Below Grade Basement 
                       Slab   

    Construction Materials  
      Roof.............Metal  
      Walls............Rock  
      Floors...........Wood  

SECURITY

Security is a critical issue. Because of the multiple use nature of the real estate DTDs, some information will be restricted MLS information for Realtors only, while everything else can be used in public listings. So, certain elements have security levels (MLS-Only, Restricted, and Public). The "Restricted" attribute is reserved for additional differentiation if necessary. Larger companies may have two internal levels of security. Either way "Restricted" is reserved, but not for public consumption. Although there are default settings for the security levels, they can all be set by the inputting agent.
<FINANCIAL> 
 <ASSESMENTS SECURITY="MLS-Only"> 
  Yes 
 </ASSESMENTS>  

 <DUES SECURITY-LEVEL="Public" TITLE="Monthly Home Owner Dues"> 
  125 
 </DUES>  
  
</FINANCIAL>
The completed document can then be spidered and indexed for MLS Realtor only and public consumption on the Internet. I do not know if a single document can offer the proper security or if two documents and two indexed databases will have to be made, one for Realtors and one for the public. Using the security level attributes, a public version of the original document could be easily derived by a variety of methods such as using a simple XSL script. Both documents would then be spidered and indexed. A Realtor would have to enter their code to gain access to the restricted information. This means that commercial search service would have to have a security control and the NAR Realtor codes. The NAR web site has this sort of security now.

Yet to be determined is whether the MLS information will be indexed by a third party commercial search service (I hope this is the case as it is best for those involved). Local boards may get touchy and paranoid and keep the information all to themselves, which would create dual and uncoordinated databases, one MLS for Realtors and one public index for general listings.
 
 
The following sections describe the worst case scenario in which two separate documents are made and indexed, the full MLS version and the public version derived from it.

USING MLS SOFTWARE AND PUBLISHING PROFESSIONALLY ON THE WEB

Following figure 1, the inputting real estate agent would first bring up the MLS software on their office computer system. The software would guide their input and the finished document would be saved locally. A copy of the document would be given to web site developers. Two identical web sites would be created with the difference that one would be for Realtors with full MLS information. The other would be for public consumption. Both of these documents would be put onto the ISP web server. Both documents would then be spidered and indexed by a commercial search engine.

Figure1: Real Estate Agent has XML Document Published with External Service


 
 

MLS ONLY SCENARIO

Following figure 2, the inputting real estate agent would first bring up the MLS software on their office computer system. The software would guide their input and the finished document would be saved locally. A copy of the document would then be placed in a server outside the firewall for spidering and indexing by a commercial service. The resulting indexed file would only produce a very basic looking form of information, but sufficient for MLS purposes.

Figure2: Real Estate Agent has XML Document Spidered on Internal Server

PUBLISHING PROFESSIONALLY ON THE WEB AND USING STANDARD XML EDITORS

A web developer would be able to use standard XML editors (and XSL or CSS) to create a web site. Although there is a great deal of information that may not be needed in a simple site, any XML editor would guide the user according to the document context in which they were writing and editing. The remarks section would be where the free from "flowery" description of the property would be written. In my opinion, the remarks section would be the lead-in for the property followed by the general description, features, and contacts.
 

FUTURE MODIFICATIONS

Certain aspects such as automated search attributes, strong typing, namespaces etc. have been left out of the example DTD given. They will be included in future versions.