The EmmlProfile Module is used to manage EMML profile pages.
emmlProfile (Module) <META> Syntax |
---|
<META HTTP-Equiv="EMMLProfile" content="parameter:value"> |
EmmlProfile JavaScript Object Syntax: |
---|
By default the JavaScript Object 'emmlProfile' will exist on the current page and can be used to interact directly with the emmlProfile. |
To Set emmlProfile parameters via JavaScript use the following syntax: emmlprofile.parameter = 'value'; remembering to enclose your value in quotes where appropriate. e.g. emmlProfile.name = 'value'; |
To set multiple EMML parameters / events on a single line use the following syntax: emmlprofile.setEMML("[Your EMML Tags]"); e.g. emmlProfile.setEMML("name:value"); |
EmmlProfile Ruby Object Syntax: |
---|
By default the Ruby Object 'EmmlProfile' will exist on the current page and can be used to interact directly with the EmmlProfile. All Methods, Parameters and Events are the same as JavaScript, however, notice 'EmmlProfile' needs to start with an uppercase letter. Another difference in Ruby is that methods do not end in '()' |
To Set EmmlProfile parameters via Ruby use the following syntax: EmmlProfile.parameter = 'value' remembering to enclose your value in quotes where appropriate. e.g. EmmlProfile.name = 'value' |
Items listed in this section indicate parameters, or attributes which can be set.
Name | Possible Values | Description | Default Value |
---|---|---|---|
name:[Value] | [optional name] (see remarks below) | Imports the EMML profile page stored at the local specified by "importProfile". Nb. This parameter should come before the related import profile method. | N/A |
importProfile:[Value] | url('URI') | http or file location of the .emmp file containing the EMML profiles to be imported. | N/A |
clear:[Value] | [optional name] (see remarks below) | Clears the currently loaded EMML profiles. | N/A |
apply:[Value] | [profile class name] | Applies the EMML profile with the class name specified. | N/A |
Normally, when importing a profile page, the imported profiles will be cleared from memory when the page is navigated away from. If you provide a name when importing a profile page, the imported profiles will not be cleared on page navigation and you will be able to reference them until you manually clear the profiles. To reference a named imported profile, prefix the profile class name with the name you supplied when importing the profile page (see example above). Naming profile pages can improve performance. If you include many profiles for your application within the profile page, it will only have to be downloaded, parsed and imported the once. It is often also preferable to maintain a central location for all your EMML.
Importing profiles from a file:// location will cause the profile to be moved from its previous location, not copied.
RhoElements Version | 1.0.0 or above |
---|---|
Supported Devices | All supported devices. |
Minimum Requirements | |
Persistence | Partially Transient - any changes made by changing parameters will be lost when navigating to a new page with the exception of when a named EMML profile set is imported. |
The following example imports an EMML profile page into the temporary, unnamed space. The following example imports an EMML profile page into a page persistent, named space. The following example applies two profile classes from the temporary, unnamed space. The following example applies two profile classes from page persistent, named space. The following is an example of an EMML Profile page. .default_decoders { scanner-all_decoders: disabled; scanner-code128other128: false; scanner-code128maxlength: 10; scanner-code128minlength: 1; scanner-code128: enabled; }
.inventory_decoders { scanner-ean13converttocode128: true; scanner-ean13: enabled; scanner-ean8: enabled; scanner-i2of5: enabled; scanner-code128: enabled; }