Back arrow Next arrow

Dirhtml Help - Scripts (Variables)

The following variables can be used in /START, /END, /BETWEEN_FILES_AND_FOLDERS, /BEFORE_ANCHORS and /BEFORE_SUMMARY:

VariableDescription, Use
%%DIR Inserts the fully qualified path (for example: C:\Windows\System)
Note: Works in /PRE_HREF_FILE and /POST_HREF_FILE
%%2SLASHDIR% Inserts the fully qualified path (for example: C:\\Windows\\System\\), with two slashes appended
Note: Works in /PRE_HREF_FILE and /POST_HREF_FILE
%%2FSLASHDIR% Inserts the fully qualified path using two forward slashes (for example: C://Windows//System//), with two forward slashes appended
Note: Works in /PRE_HREF_FILE and /POST_HREF_FILE
%%FOLDER    Inserts the folder (for example: Desktop)
%%RELATIVE_PATH    Inserts the path relative to the root folder (for example: \Desktop\Folder)
%%DATE Inserts the date and time
%%DATE_NO_TIME%   Inserts the date (a trailing % is required)
%%F Inserts the filename
(Note: only works in /FILE_HREF_APPEND, /PRE_HREF_FILE and /POST_HREF_FILE sections)
%%F_PATH Inserts the filename, including the relative path
(Note: only works in /FILE_HREF_APPEND, /PRE_HREF_FILE and /POST_HREF_FILE sections)
%%F_PATH_2SLASH% Inserts the filename, including the relative path, using two forward slashes as folder qualifiers
Note: Works in /PRE_HREF_FILE and /POST_HREF_FILE
%%NO_EXT_FNAME% Inserts the filename with with no extension
This makes it possible to have screenshots point to video or other files with filenames that are identical except the extension.
(Note: only works in /FILE_HREF_APPEND, /PRE_HREF_FILE and /POST_HREF_FILE sections)
%%FILE...% Inserts the contents of a text file.  The filename must be followed by %.
Example:  %%FILEsome_file.txt% inserts the contents of the file named some_file.txt.
Note: Absent a path, dirhtml will look for the file in the folder being searched first, then in the same folder as dirhtml.exe.
%%FILE...% can also be used in an /ANCHOR section or as part of an Anchor Prefix.
%%SUMMARY    Inserts the summary statistics, which can use the /SUMMARY_STYLE script section
%%INCLUDES    Inserts the filenames include string
%%SKIPPED    Inserts the filenames exclude string
%%SPEC Inserts the file specification string
%%VERSION    Inserts the version of dirhtml that created the file
%%FOLDERS_INCLUDE%    Inserts the folders include string

%%FILE, %%DIR, %%FOLDER and %%VERSION can also be used in /HEAD.