Google Sites is a (static) website generator platform by Google.
There are themes and gadgets (the provided ones or custom) we can add to our Google Sites.
New Features #
These are some of features I noticed just now:
Canonical URI setting. I think that's pretty much new.
To access that, go to your Setting > General > scroll down to "Canonical URI".
There's the Mobile setting.
The same page as above, just scroll down to "Mobile".
Security (embedding related) setting.
It's on the same page as two settings above.
Common restrictions #
- Unlike Blogger, we cannot edit the
HTMLpart of the Google Sites directly. The separated settings can be found on your Google Sites setting page.
- On the page, all separated
scripttags will be stripped. Inline
scriptwill also be stripped. Only inline styling will work.
- The gadget
scriptwill work only for the gadget. It can't be used to control the whole page because it's an
iframe. Sort of sandbox-ed application.
- The footer of Google Sites cannot be removed.
- The sidebar or footer cannot contain any of the (custom or predefined) gadgets.
- Google Sites doesn't allow us to put new AdSense to be shown on it now. But your previous AdSense will continue to work. This is the announcement
Creating a custom gadget #
This only works on the main (center) page, not for sidebar nor footer.
It's like creating an
iframefor your page but wrapped in
This can contain any of
HTMLtags and it can pull resources from external sites. Front end only.
- Your application must be wrapped with this:
- After you've done tinkering the
HTML, save the file as
xml. Then upload that to your Google Sites Attachments.
How to access the attachments:
If you're logged in, click the site you wanna manage > click the gear icon (more actions) > Manage site, then scroll to Attachments.
- On your attachment, right click the "Download" link of that recently uploaded
xml, to get the
urlof the file.
- Go to the page where you want the application to appear. Edit the page (click the pencil icon).
- Then hit Insert > ... More gadgets... > Add gadget by URL
- Paste the
xml urlyou copied earlier. Remove the additional parameter at the end of the
url, which is started by a question mark.
- Click "add", and set the
widthand extra settings for the gadget.
- Preview the gadget. If it's good enough, then save it.
One custom gadget tutorial here is about embedding Twitter Timeline, you can read about it right there
On your page, click the pencil icon to show the editor > hit the
<HTML>button. You can see bunch of
HTMLelements of that particular page.
CSScan be declared by adding
styleattribute on the element.
For instance, you wanna put styling on a
Let's assume previously it looks like this
Then to add inline
CSS, put it like so:
It means, the
divelement now has custom
If you close the
HTMLeditor, you'll see it (the
divelement) has the declared styling.
Embedding #We can embed external things (webpage, Google gadgets, forum, etc) on Google Sites.
More info at this support page