Support Articles

Stay Connected

Using HTML and Custom Code

The editor is flexible in that it allows you to both modify existing code or add your own. Doing this allows you to extend the functionality of the platform and provides you with additional features. For example, you can add a custom calendar widget or even a third-party custom contact form for taking payments on your site.


This article will cover three different methods of adding custom code to your site.



HTML Widget


The HTML widget is the easiest method of adding custom code to your site.

In the left panel, click Widgets, and drag the HTML widget into a column or row into your site and paste in your code.



Edit Custom Code


After adding custom code with the HTML widget,click the widget in your editor to edit your code.


Sometimes, however, due to the nature of the code it is not possible to do this as easily. In this case, you can select the container to see if you can edit the entire container (which will include the code).


Edit Inline Code

To edit the code of anything in your site:


  1. Right-click where you want to edit the code, and then click Edit HTML/CSS to get view the code of anything in your editor.
  2. The code editor displays for the code you are editing. Once there, click Documentation to read the documentation before you start changing code.


Note


While you can edit the CSS in the developer mode, it is not recommended that you add any new selectors in this menu. You can add new rules to selectors here without a problem. For creating new CSS selectors, please do this through developer mode.


Developer Mode

You can view the code of your entire site within the editor. To access the code, click </> at the top right of your editor.


The code for your site is broken into sections to allow fine tuning over your site.


For more information on developer mode, see Developer Mode. 



FAQs and Troubleshooting

If you broke your site with custom code, you can fix it by:


  1. Restoring to a backup
  2. Fixing the code manually
  3. Accessing a different part of the page


For a full guide on troubleshooting custom code, see How Can I Troubleshoot Custom Code? 


What are some good custom coding guidelines?


Some guidelines are:


  • Create a backup
  • Use a test page
  • Create a backup

For more information, see Custom Code Guidelines.


What's

Snappin

Related Articles

By Eddie Cruz 24 Aug, 2021
Expand the capabilities of the website builder with custom HTML. This widget allows you to embed custom code into your site, and can be used to embed third-party widgets such as videos, contact forms, and more. While adding custom code can extend your site's functionality, we recommend you only add code from a trusted source. Only add code if you know exactly what it does and how to troubleshoot it if it does not work. To learn more about using HTML in Developer Mode, see Developer Mode.
By Eddie Cruz 24 Aug, 2021
The editor's interface has three main predefined sections: The top navigation bar, the left panel, and the content area. Each of these predefined sections plays an important role in letting you make your site as awesome as possible.
By Eddie Cruz 24 Aug, 2021
This widget makes it easy for website visitors to send you money using PayPal. You can use the PayPal button both for gathering donations and for selling products.
Share by: