Add a calculator to a hand-written page
The code is two lines of HTML. Where it goes: anywhere in the body of the page. The calculator is free, with no account, no script and no ads.
The steps
- Open the HTML file for the page.
- Paste the code where the calculator should appear, inside the body.
- Save the file and upload it as you normally do.
The frame is a standard part of HTML and needs nothing installed. Reference: MDN: the iframe element.
What stops it working
If your own site sends a Content-Security-Policy header with a frame-src or child-src directive, add the address the frame points at to it, or the browser will refuse to show the frame.
- Nothing appears. The plan or the editor has removed the frame. That is the first thing to check, above.
- It is cut off. The code asks for 820 pixels of height. Raise the number, or accept that the calculator scrolls inside its box.
- The credit is missing. The second line of the code is the credit link. Paste both lines.
The code, for the mortgage calculator
<iframe src="https://plainnumber.com/embed/finance/mortgage" title="Mortgage payment calculator" width="100%" height="820" loading="lazy" style="border:0;max-width:100%"></iframe>
<p>Calculator by <a href="https://plainnumber.com/finance/mortgage" target="_blank" rel="noopener">Plain Number</a></p>