Yes!

In particular, JavaScript programs that students write on CodeHS can be directly embedded on a blog or website that the student is making.

Follow these steps to take your CodeHS JavaScript code and embed it on your own HTML page:

1. Open up your program on CodeHS.

2. Go to More > Embed in the right side bar

3. The code for a simple HTML page that runs your JavaScript program is provided in the Embed tab, as well as instructions for what to do with that code, the instructions are provided here for your convenience:

Version 1: On Your Computer

1. Create a file called codehs.html on your desktop.

2. Copy and paste the HTML code provided into that file.

3. Double click the file to open it in your browser. You now have a full webpage running outside of CodeHS, locally on your computer!

Version 2: Online

1. Create a file called codehs.html on your desktop.

2. Copy and paste the HTML code provided into that file.

3. Upload this file to the Internet

4. Visit your webpage.

So where exactly do you upload this HTML file so that it is live on the Internet? Well there are several website hosting services that you could use, but one simple option is to make your own homepage hosted on codehs.me!

To do this, go to your Sandbox (https://codehs.com/editor/sand...) and click on the "Edit My codehs.me Homepage" button

You can simply copy and paste your HTML code from the Embed tab, into your Sandbox Homepage, and you'll be able to view the resulting website at <your username>.codehs.me

You can read more about the codehs.me homepage here: http://help.codehs.com/article/TmTxN6XLbz-can-students-create-their-own-websites-to-show-off-their-work

By the way, if you're interested in the technical details of how embedding your JavaScript code works, check out this blog post from the awesome intern that made this feature: https://medium.com/@codehs/wri...

Did this answer your question?