TQS Home
Trivia Quiz Shell Version 2.8 Now Available!Bot Productions Home
TQS 2.1

Back to Reference

DATAROOT Dynamic Value

Specifies the data root path.

Syntax
DATAROOT
Remarks

The data root path defaults to the folder that contains this TQS application file, including an ending backslash. It can be changed to, for example, a web site directory through the use of the DATAROOT attribute of the TQS element.

Examples

If the currently located TQS application is:
C:\TQS Applications\My App.tqs
and no DATAROOT attribute exists in the TQS element, then DATAROOT will be equal to:
C:\TQS Applications\

<LOC TYPE="HTML">
  <HTML SUBST="%DATA%,DATAROOT">
    <IMG SRC="%DATA%img.jpg"/>
  </HTML>
</LOC>

TQS will change the HTML code into:

<IMG SRC="C:\TQS Applications\img.jpg"/>

Here, DATAROOT will be equal to:
http://www.example.com/tqsdata/

<TQS
  VERSION="2.1"
  DATAROOT="http://www.example.com/tqsdata/">
  ...
  <LOCATIONS ...>
    <LOC TYPE="HTML">
    <HTML SUBST="%DATA%,DATAROOT">
      <IMG SRC="%DATA%img.jpg"/>
    </HTML>
  </LOC>
  ...
  </LOCATIONS>
</TQS>

TQS will change the HTML code into:

<IMG SRC="http://www.example.com/tqsdata/img.jpg"/>

©2020 Bot Productions. All rights reserved.Last Updated: January 5, 2006