If you want to encourage discussion on your website, you can add a forum to any webpage you own using Google Groups.
Here's how to embed a forum:
- Go to the HTML source of your website.
- Copy and paste the HTML (written below in green). Make sure you paste it where you would like your forum to show on your site. Important: In the HTML, make sure to change "forum-name" to the name of your group. The text you need to replace is written in red below.
<iframe id="forum_embed"
src="javascript:void(0)"
scrolling="no"
frameborder="0"
width="900"
height="700">
</iframe>
<script type="text/javascript">
document.getElementById("forum_embed").src =
"https://groups.google.com/forum/embed/?place=forum/forum-name" +
"&showsearch=true&showpopout=true&parenturl=" +
encodeURIComponent(window.location.href);
</script>
Using Google Groups for work or school?: If you're embedding a forum from a site that's owned by an organization or company, you'll need to add a parameter to the end of the URL. The URL in your HTML should look like this instead:"https://groups.google.com/forum/embed/?place=forum/forum-name&domain"
- Customize how the forum looks on your site by adding parameters to the end of the URL in the code. The table below includes the changes you can make and how to add each parameter, and you can string together these parameters by separating them with an ampersand (&). For example, if you want your embedded forum to include a search box and the Google Discussions Forum theme, your URL might be:
https://groups.google.com/forum/embed/?place=forum/forum-name&domain=yourdomain.com&showsearch:true&theme=default
What you can do | Parameter at the end of the URL |
---|---|
Hide or show a search box in your forum |
|
Hide or show selector tabs in the top right corner that let users see your member list, the "About" information for your group, and be able to see all topics |
|
Change the theme of your forum to the default Google Discussions Forum theme (It will replace the monochrome theme that's used automatically when you embed a forum) | To change the theme, add: &theme |
Hide or show the forum's title and description |
|
Hide or show the subject of the post |
|
Set the default language of the forum (if you don't include this, Google will try to guess the user's chosen language) | To set the default language, add a parameter and the two letter language code: &hl |
Choose the format of links to your posts http://parenturl.com/path#forum instead of http://parenturl.com/path?place=forum) |
|
Choose if links to your topics and messages go to the forum embedded on your website, or to the Google Groups site | To link users to embedded forum, add:&parenturl |
0 comments:
Post a Comment