Appearance
Manage HTML Project Files
HTML project files are used in dynamic content templates to generate web-based output such as banners, emails, or interactive content. An HTML project is a ZIP file containing HTML, CSS, JavaScript, and image files that Relayter processes to identify dynamic content placeholders.
Upload an HTML project file
- Go to Templating → Dynamic content → HTML.
- Click Add an HTML project file.
- Enter a name for the project.
- Upload a ZIP file containing your HTML project.
- Relayter extracts and validates the project.
- Click Save.
Relayter will scan your ZIP file for all .html and .htm files and treat each as a potential entry point (called an "index file"). You can later select which entry point to use when creating templates.
Project file structure and requirements
Your HTML project must be packaged as a single ZIP file. Inside the ZIP:
- Include one or more
.htmlor.htmfiles as entry points - Mark dynamic content areas using the
relayter:tagattribute - Include all supporting files (CSS, JavaScript, images)
- Use relative paths for file references within the project
- Ensure all dependencies are included in the ZIP
Marking dynamic content with relayter:tag
To mark an element for dynamic content injection, add a relayter:tag attribute with a unique identifier:
html
<h1 relayter:tag="title">Placeholder text</h1>
<img relayter:tag="hero" src="placeholder.png" />
<div relayter:tag="description">Description text</div>Within each HTML file, all relayter:tag values must be unique. Duplicate tags in the same file will cause the upload to fail.
Supported content
Your HTML project can include:
- HTML and CSS (any valid HTML5/CSS3)
- JavaScript (any code supported by standard browsers)
- Images, fonts, and other media files
- External CSS and JavaScript files (referenced by relative paths)
Relayter does not restrict HTML, CSS, or JavaScript patterns. All standard web technologies are supported.
Use a project file in a template
- Open or create a dynamic content template.
- Set the Engine to HTML.
- In the Project file section, select the HTML project you want to use.
- Choose an Index file (one of the HTML files from your project).
- Save the template.
Update a project file
To update an HTML project with a new or modified ZIP file:
- Go to Templating → Dynamic content → HTML.
- Find the project and click the edit icon.
- Click Update an HTML project file.
- Upload a new ZIP file containing your updated project.
- Relayter re-extracts and re-validates the new files.
- Click Save.
When you upload a new ZIP file, Relayter replaces all project files and regenerates the list of index files by scanning the new ZIP. If the new ZIP has a different structure (different HTML files or different relayter:tag values), templates using this project may need adjustment.
Templates and rulesets that reference the old project will continue to work if the index file structure remains compatible. If you significantly change the HTML structure or rename entry point files, you may need to update templates that use this project.
Edit project metadata
To change only the project name:
- Go to Templating → Dynamic content → HTML.
- Find the project and click the edit icon.
- Update the name field without uploading a new ZIP file.
- Click Save.
This will update the name without reprocessing the HTML files.
Delete an HTML project
- Go to Templating → Dynamic content → HTML.
- Find the project and click the delete icon.
- Confirm the deletion.
You cannot delete a project that is currently in use by templates or rulesets. If you need to delete it, first remove all references to it from your templates and rulesets.