The HTML/JavaScript plugin allows administrators more control over the content of their workspace. This manual section will show you how to use the plugin, what the different error messages mean, and how to resolve them.
Can I paste my own HTML and Javascript code into the PBworks editor?
Yes. HTML and Javascript can be pasted into your workspace page, but it should only be inserted via the "HTML/Javascript" plugin. The Source editor of PBworks is fine for making small changes and tweaks to the HTML code, but for security reasons, it is heavily filtered. So, the code you put into the Source editor may be stripped out when you save the page.
However, code that Administrators of workspaces insert into the HTML/Javascript plugin has no filter. Only Administrators of the workspace can insert both HTML and Javascript code, while Writers, Editors, and Page-Level Only users with Writer or Editor privileges can insert only HTML. For more information on the limitations that Writers and Editors have in regards to inserting Javascript click here.
Follow these steps to insert your own HTML:
- Click on “Insert Plugin” button in the editor Toolbar:

- In the HTML & Gadgets Category, select the "HTML/Javascript" plugin:

- In the field provided, paste in the HTML or Javascript you wish to use. Depending on the role you have, the window may look slightly different. Here's how the windows are different for the different kinds of user:
| Administrators |
All Other Users |
 |
 |
For Administrators, there's an option that must be checked in order to allow Javascript within the box to be run. If the script is not running properly, please make sure that the "Allow Javascript and other potentially unsafe code" checkbox is checked on the plugin. This is not required if there is no Javascript in the code.
If you're not an Administrator, you will not see the option to allow Javascript, because you don't have sufficient permission to add it. If you try to insert Javascript when you don't have permission, you'll see a message in the bottom of the window which looks like this:

This indicates that if you save the plugin as-is, the Javascript code will be stripped out and not function properly.
- Once you've put in your code, click "Preview" and the window will illustrate how the HTML plugin will look in the editing window (not as it will appear on the published workspace page). Click "OK" to insert the HTML:

- Save the page and your plugin should be displayed properly in the View mode.
What does the Source button do?
This button is for the tech-savvy editors who want to see the HTML code showing what’s going on “behind the scenes” on the workspace page being edited. The average editor probably won’t need to use this button. If you accidentally click it, simply click it again to return to the editor.

Note: Although this does give you the opportunity to change some of the options in the HTML code in your PBworks Page, it is not recommended to use the source editing mode to embed anything into your PBworks page. Use the plugin described above to embed widgets, customized HTML, and Javascript.
Getting past the character limit
There is a limit of 1030 characters in this plugin - if your Javascript or CSS is longer then that please look into putting them into external .js or .css files.
How to create an external .js file?
How to create an external .css file?
Alternatively, you can also get past this limit by placing the code in successive plugins, right next to one another. This is a good idea if you don't want to create external files.
Adding HTML Anchor Links into a page
Please visit the Links page for information on this topic.