Define your own HTML style
The concept The concept
CD2HTML allows the user to chnage the outfit of the generated html pages to their own
desire. The program allows to manage many different html styles, so you are able to switch
from one to another with one mouseclick. If you don't want to design yout own styles, simply use
the presets, but if you are a power user, you have many opportuniries to make your own style. The sectionsThere are five sections of an html frame: the head, the headlines, the values, the footlines and the FOOTER. The HEAD specifies the normal html HEAD from <html> to <body> and it's used once. The FOOTER is the end of the html file with </body> and </html>. Here you can insert some further information like the 'mailto:'-tag. The headlines is used for each directory, which is marked by a red dot in the main window. In this section are the headline entries and/or tables HEADs located. The values section is used for each normal entry (file or directory with no HEAD info, greed dot in CD2HTML's list view). See the examples how to use the tags. Don't hesitate to e-mail me, if you like me to implement a new tag (string) not currently supported. Example
Please note that the section names (HEAD, HEADLINES, VALUES, FOOTLINES and FOOTER) are seperated by an '<$---' and '---$>' (e.g. '<$---FOOTER---$>'). How does CD2HTML work?CD2HTML works in two different search modes. The first is the directory mode. In this mode CD2HTML searches only for directories. It recursively searches one directory level after another until it reaches the searching depth from the options dialog or the end of the directory hierarchy. The last level will be marked as text and will be output in a table row (in html output). The upper hierarchies will be created in their own tables and headlines. If you use the file mode, CD2HTML searches for files and directories. Files are always marked as text and directories are marked as headlines. The tagsIt doesn't matter anything if you write the tags in capital or small letters. But don't forget the '<$' and '$>' at the begin and end of a tag. If you make mistakes CD2HTML will show you a message in the html output.
The anchor tag creates an anchor for a link in the index (see index tag). It makes no sense to use the anchor tag without the index tag. The output looks like <a name="xxx">, where xxx is a value CD2HTML derives from the number of the entry in the list-view.
The author tag writes a message with links about CD2HTML and the author. You should always provide the author tag, because I want as many people as possible use my program. I don't want any money, I wish only that my program is used and not written in vain. If you don't want to use it, leave it out.
The date tag prints the date of an entry (what else?).
The description tag writes the description CD2HTML has found for an entry. CD2HTML notes the order you have defined in the options dialog (normally the file_id.diz at first ant then the info.txt) and uses the first of the files it found. If no description is found, CD2HTML writes only a ' '. In packed archives CD2HTML is only looking for the file_id.diz. Each line will be finished by a hard line-break (<BR>) because it looks mostly much better. Maybe I will later add an option to switch this off.
The directory-name tag specifies the next upper directory name of an entry which is marked as text. So this tag is only for these entries available or for the directory itself.
The directory-size tag specifies the size of the parent directory of an entry which is marked as text. So this tag is only for these entries available or for the directory itself. The value is rounded (if the size is greater than 1048576 bytes the value is rounded to MB, if the size is between 1024 and 1048576 bytes value is rounded to KB and in all other cases the value isn't rounded and written in Bytes).
The <$dltime14.4k$>, <$dltime28.8k$>, <$dltime64k$> tags: On Internet servers it is very useful to show the time which is used for the download of the actual file. I found the idea on the www.windows95.com server. The values can be seen as the minimal download-time for modems with 14400 bps and 28800 bps or ISDN adapters with 64000 bps (bps = bits per second). The tags are calculated with the file-size and 1750 bytes/s, 3500 bytes/s and 8000 bytes/s. I don't know if I should use other values to make the results more realistic (because this results are more idealistic). These tags only make sense in the file-mode, but they can be also used for a directory.
Links picture entries direct into the HTML file. This is useful, if you want to make an index for small gif animations.
With this tag you are able to include any text (e.g. HTML files) into your HTML output. So you can include the same HEAD/FOOTER file into each HTML output. The included text will not be parsed for CD2HTML's own tags. The usage is <$INCLUDE file$> where file is a file in the dir where the output HTML files will be saved in or a absolute path.
This tag does what it says: it creates an index of all entries which are marked as directory. So you can insert links to all headlines or tables if you want. But it only makes sense if you use the index tag together with the anchor tag. So see the anchor tag too.
The <$indexli$> tag is nearly the same as the the <$index$> tag, but it writes a <LI> after each link. So you can use it together with the <OL> or <UL> tag (e.g. <UL> <$indexli$> </UL> creates an index with a dot before each indexlink). See also the <$index$> and <$indexbr$> tag
The <$indexli$> tag is nearly the same as the the <$index$> tag, but it writes a <BR> after each link. So you have a more cheerful outfit. See also the <$index$> and <$indexlt$> tag
The ldate tag gets the local date from the internal clock of your computer. You can use this tag to show the date of the last changes of the index file.
The ltime tag gets the local time from the internal clock of your computer. You can use this tag to show the time of the last changes of the index file.
The link tag creates a link to the actual file/directory. The link text which is shown in the html browser is the file- or directory name. If you save the html file on the same drive the index is created from CD2HTML creates relative links. It means that the links doesn't use a drive letter. This is absolutely necessary if you generate the index for an Internet/Intranet server. In all other cases CD2HTML creates absolute links which including a drive letter and the full path (because there is no other way).
The links tag creates links to all the files CD2HTML has found for the actual directory. What CD2HTML should link is specified in the options dialog (by extension). You can edit the files which should be linked before writing the html file. If you double click in the list view in CD2HTML's main-window and in the window which opens, you go 'links'. See the comments I made about absolute and relative links in the description of the <$link$> tag.
The <$mp3title$>, <$mp3artist$>, <$mp3album$>, <$mp3year$>, <$mp3comment$>, <$mp3genre$> tags: These tags provides you with all the information of the ID3 tag of MPEG Layer 3 files. You can get these informations only if your MP3 files including the ID3 tag. You can also edit these informations if you doubleclick on an MP3 file in the CD2HTML list view.
<$mp3original$>, <$mp3copyright$>, <$mp3samplerate$>, <$mp3durationmin$>, <$mp3durationsec$>, <$mp3mode$>, <$mp3layer$>, <$mp3version$>, <$mp3bitrate$> These tags gives you the full support for MP3 files informations. These tags corresponds to MP3 informations like song duration (min, sec), encoding, bitrate, original flag (yes|no), copyright (yes|no), layer ('Unknown', 'I', 'II', 'III'), mode (Stereo, Joint-Stereo, Dual-channel, Single-Channel) and version ('Unknown', '1.0', '2.0', '2.5').
The name tag contains the name of the actual file/directory.
This tag is similar to the <$description$>-tag but it gives only the first line of a description-file.
The path tag contains the path of the actual file/directory relative to the root path (the path you have started the scanning process).
This tag is very interesting, because it creates a GIF picture of the icon belonging to the actual file/directory (the associated icon under windows) or a thumbnail of the file (for GIF- and JPEG-images) and inserts it on the tags position in the html code. The picture will be saved in a directory 'pictures' relative to the html file. So if you save the html file in the directory 'c:\index\' the pictures will be saved in 'c:\index\pictures\'. If some files/directories have the same icon, the picture will be created only once and used together. The pictures have the name 'img???.gif' or 'thumb_filename.gif/jpg', where ??? is the index in imagelist of the OS.
Is nearly the same than the <$picture$> tag. The only difference is, that this icon is a link to the program/directory it belongs to. For further information see the description of the <$picture$> tag.
The <$picxres$>, <$picyres$>, <$picdepth$>, <$pictype$>, <$piccomment$> tags: These tags writing information about pictures.
The <$REPEAT=x$> ... <$ENDREPEAT$> tags: If something should change after all xxx entries, then you need these tags. For example you want to write 5 table columns including some informations about your pictures and then start a new row you have to write:
The root tag gives the name of the uppermost directory of the search. It's a good replacement of the title tag.
The size tag gives the size of the actual file/directory. The output is in the same format as the <$dirsize$> tag. So see the description of the <$dirsize$> tag too.
The title tag gives the title of the document. It's fixed in the options dialog.
This tag gives the total size of the search. It's the size of the directory you have started the search from. The output is in the same format as the <$dirsize$> tag. So see the description of the <$dirsize$> tag too.
|