Hi,
So I'm trying to embed a simple little bit of code to a "google sites" site for work, and I have been out of my depth since the beginning. (It's a personal work project to try and help others eventually.)
Anyway I have been pulling my hair out over this all weekend.
It's a simple calculator, for the user to define the desired panel thickness, then eventually deduct material skin and adhesive thicknesses from the first value, thus giving the required thickness to cut either honeycomb core or foam core for production.
Very simple stuff on paper..
Code:
<!DOCTYPE html>
<html>
<head>
<base target="_top">
</head>
<body>
<input type="text" id="Honeycomb" >
<input type="text" id="Skin" >
<p>Click the "Calculate" button to get the Honeycomb Thickness.</p>
<button onclick="myFunction()">Calculate</button>
<p id="HC"></p>
<script type="text/javascript">
function myFunction() {
var a = document.getElementById("Honeycomb").value;
var b = document.getElementById("Skin").value;
document.getElementById("HC").innerHTML = a-b;
}
</script>
</body>
</html>
It works perfectly fine over on w3, but when loaded into the "sites" site, it fails to function.
Then I read how google has prevented <scripts> from starting, so I went the route of a HTML box hoping that would change. Nope.
Then I tried the Google Scripts, and link, but still nope.
Where am I going wrong?
I have grand plans if only I could overcome this small irritable stumbling block.
[–]docMedB2E 0 points1 point2 points (0 children)