How to embed processing sketch onto GoDaddy Website

Hi there,
I’m trying to copy the HTML code of a Processing Sketch onto my website (made via GoDaddy) but I’m not getting a result (i.e. the only thing that is coming up is the written code rather than the embedded sketch). I’ve found some tutorials on this online but they appear to be either conflicting or outdated. Would someone be able to help with this?

Cheers

Welcome @squirtlekid1000

I’m not familiar with GoDaddy’s website building tools. I’m guessing you have to add custom code like this: https://godaddy.com/help/add-html-or-custom-code-to-my-site-27252

Using the CDN-hosted version of p5.js is probably easiest approach here (https://p5js.org/get-started/#hosted). Of course, you’ll have to use p5/JavaScript code (not Processing Java code) for this approach.

The code you insert will look something like this:

<script src="https://cdn.jsdelivr.net/npm/p5@1.1.9/lib/p5.min.js"></script>

<script>
function setup() {
  createCanvas(400, 400);
}
function draw() {
  background('#FF0000');
}
</script>

However, there are other ways if that doesn’t work …