Support Team
posted this
03 February 2022
Hi Robert,
If there are no additional instructions from the code developers, you can add HTML, CSS and js code to the HTML element. Or you can add HTML to the HTML element and js to the Page Settings >> additional HEAD HTML. But Nicepage does not execute third-party scripts directly in the editor. It will be executed in the browser preview only.
I've checked your code on my side.
The problem is that when you insert custom code in Nicepage, it generates the page and makes all page code readable including custom HTML. In other words, it adds line breaks.
before:
<div id="invoiceidDiv" style="text-align: center; display: none;"><label for="invoiceid"> </label>
after:
<div id="invoiceidDiv" style="text-align: center; display: none;">
<label for="invoiceid"> </label>
The script that works with this HTML is hardcoded to the structure without line breaks. This causes an issue with the code on the Nicepage page. But if you replace the block of HTML code with line breaks with the original code after the exporting, the button will appear ok. But you can do it with the exported HTML website only.
Please let us know if you have any further questions.
...................................................
Sincerely,
Olivia
Nicepage Support Team
Please subscribe to our YouTube channel: http://youtube.com/nicepage?sub_confirmation=1
Follow us on Facebook: http://facebook.com/nicepageapp
Hi Robert,
If there are no additional instructions from the code developers, you can add HTML, CSS and js code to the HTML element. Or you can add HTML to the HTML element and js to the Page Settings >> additional HEAD HTML. But Nicepage does not execute third-party scripts directly in the editor. It will be executed in the browser preview only.
I've checked your code on my side.
The problem is that when you insert custom code in Nicepage, it generates the page and makes all page code readable including custom HTML. In other words, it adds line breaks.
before:
<div id="invoiceidDiv" style="text-align: center; display: none;"><label for="invoiceid"> </label>
after:
<div id="invoiceidDiv" style="text-align: center; display: none;">
<label for="invoiceid"> </label>
The script that works with this HTML is hardcoded to the structure without line breaks. This causes an issue with the code on the Nicepage page. But if you replace the block of HTML code with line breaks with the original code after the exporting, the button will appear ok. But you can do it with the exported HTML website only.
Please let us know if you have any further questions.
...................................................
Sincerely,
Olivia
Nicepage Support Team
Please subscribe to our YouTube channel: http://youtube.com/nicepage?sub_confirmation=1
Follow us on Facebook: http://facebook.com/nicepageapp