M1.Menu module

The system Xitex WebContent M1 has an opportunity to create automated menu on web-site pages. That menu is remarkable for the binding of menu elements to the sections of web-site. You need a creation of the module M1.Menu to have such a component in your web-site.

Chose in the list of modules type "M1.Menu.

Attributes entry

  • Name — name, which module will own in the system.
  • Data — information regarding menu structure.
  • Menu handler script — code of the script for menu displaying on the web-site page.

Menu structure building

Entry in the Data field is realized as follows.
  1. Click Change. The window for menu structure building is to be displayed.
  2. Please highlight at the left column Site tree required section, where is an object for connection with menu element.
  3. In the right column Selected elements the list of elements is made.
  4. Mark the corresponding object in the middle column and push the button . The Address of the object will be placed in the right column of menu elements.
  5. If necessary you can remove any element out of the list, you only have to mark it and click .
  6. After having created the list of elements, click OK.

Script building for menu displaying

Format of Data, which are placed by the system in HTML code of the page during module activation: <menu element>::= <menu name>="["{<link>,<alternative link>, <text of an element>, <summary>,<link for a display>[,]}"]" <link>::=(show-menu=<submenu name>)|(<link for a page>)


  1. Menu functions as follows: upon module activating the system insert data for menu displaying in marked by user space of the page, and after that the script, is to be inserted, which displays these data.
  2. Should the menu element implies the appearance of a submenu on its activation, parameter "reference" is to be considered virtual as for "show-menu=<submenu name>", and parameter "alternative reference" functions as the parameter "reference" of ordinal menu item. Parameter "submenu name" - is the name of another menu element, it will be determined further within the text in accordance with the same method. The data tree is realized in such a way.
  3. The task of further being brought script out is to display these data. Essentially, the precise look of the menu (and is it to be considered menu) it depends of web-master, which will write script - handler, the system will just give required data.
  4. Automation of the module means that having made the menu and pointed sections, from those you have to generate them, web - master can pay no attention to modification of a web-site structure in the future. On each turning to the page, the data are generated on the basis of current content of these sections, thus they will always remain up-to-date.
  5. Within the script you have to use tag <menuname> in order to turn to menu element of the upper level.
  6. When all fields are entered, click OK.

Insertion of pictures and other resources in script.

  1. In order to insert in script the attributes of resource from the section of a web-site, click Resource.
  2. On the left in the «site tree» please highlight the resource.
  3. You can see its image on the right.
  4. In order to enlarge the image please point the mark at Fit image.
  5. Having chosen it, click OK

See also: Modules in Xitex WebContent M1, M1.Newsline