A HTML template works in Chrome like this:
- The background color is gray.
- Normally there are some invisible small icons.
- When I click the icon 3, the navbar slide left and small icons turn to visible, like this:
But the same HTML code in a TMS WEB CORE project works in an abnormal state, e.t. the background is white, the icon 3 does not work(no response when click), and the small icon is always shown like this:
It seems like some script and CSS does not work, but there is no error message in console. It works fine when I put the same code into the project.html, also works fine in a local HTML file, this problem is only in a HTML assigned to a form.
The problem remains nochanged.
if this script in HTML code, the applcaiton does not work, it shows a number of year only, other code does not work, like this:
There is no any errors in console too.
Here is the source code:
The first problem is resovled, add "class="g-sidenav-show bg-gray-100" to in project.html
Ignore it please.
Now I am trying to resovle the issue about script code "document.write(new Date.getFullYear())" , any suggest will be very appreciated.
What exactly is the problem you have with:
For example: A HTML with code below:
should output this in normal:
but in a TMS WEB CORE project, if I put these code into HTML assigned to a form like below:
it only output like this:
It seems like the script code "document.write(new Date().getFullYear())" interrupt the code running.
This will not work this way.
The reason is that it is the form instance that is responsible for loading the HTML file into the body of the DOM and thereby, it needs to activate script blocks in the loaded HTML (otherwise the browser will simply treat the script blocks as text. This loading process as such causes that this is rendered out of order compared to the browser directly loading the HTML itself.