Difference between revisions of "Help:Sidebar"

From FamilySearch Wiki
Jump to: navigation, search
m (How to create a sidebar)
m (How to edit a sidebar)
Line 20: Line 20:
 
Type the following: <nowiki>{{Name of sidebar-sidebar}}</nowiki> where you want the sidebar to appear.  It can be placed anywhere on the page.  It will begin where you place it.  So, if you put it at the top, it will appear at the top.  If you place it half way down the page, it appear  somewhere in the middle of the article.
 
Type the following: <nowiki>{{Name of sidebar-sidebar}}</nowiki> where you want the sidebar to appear.  It can be placed anywhere on the page.  It will begin where you place it.  So, if you put it at the top, it will appear at the top.  If you place it half way down the page, it appear  somewhere in the middle of the article.
 
==How to edit a sidebar==
 
==How to edit a sidebar==
To edit a sidebar, you treat it just like a regular article.  Click on the "Edit This Page" button on the sideba page and make whatever changes you want just as you do on any article in the Wiki.
+
To edit a sidebar, you treat it just like a regular article.  Click on the "Edit This Page" button on the sidebar page and make whatever changes you want just as you do on any article in the Wiki.  <br><br>To access the sidebar to edit, you can type in the search box "Template:Example-sidebar."  This will take you right to the sidebar article without having to go through a page where the sidebar appears.
 
</div>
 
</div>
 
[[Category:Help]]
 
[[Category:Help]]

Revision as of 17:35, 18 October 2013

What is a sidebar

Sidebar is a term that refers to various forms of information that is displayed in a box, with or without borders, to the side of an article. You can display text, images, widgets, etc. in them.

What is the purpose of sidebars?

The purpose of the sidebars is to isolate the material in it from any changes in the main article that might affect the location or arrangement of the material in the sidebar.

What are the advantages of sidebars

It has the advantage of being updatable without having to go each of the articles where the sidebar may appear. This very important if you have a particular sidebar on many pages. You simply go to the sidebar article and made whatever changes you want. Then, when someone goes to any of the pages where the sidebar appears, they will see the updated material. Again, this material will appear on all the articles where the sidebar is imbedded.

How to create a sidebar

Probably the easiest way is to create sidebars is to use “div” tags. For example: <div>text</div>. But to control the width and the location of the sidebar you must include the width and its desired location on the page.

This is an example for setting the width and location of the sidebar: <div style=”width:25%; float:left;”>text</div>. In this example, the width is set to 25% of the total page width and the sidebar is to float on the left side of the article and will do so at the location you set it. Click here to see the article for the Template:Example-sidebar on this page

Since you have set a width to your sidebar, you must set a width to the material in the article itself. Otherwise the material in the article into which you imbedded the sidebar in will be pushed down the page below the sidebar.

To control the width of the material to the side of the sidebar, you can use <div> tags. You can enclosed all the material just like was done with the sidebar. Example: <div style="width:75%; float:right;">article material</div>. Notice that you need to put in the float:right so the material will appear at the top of the page instead of remaining below the sidebar.

How to embed a sidebar

Type the following: {{Name of sidebar-sidebar}} where you want the sidebar to appear. It can be placed anywhere on the page. It will begin where you place it. So, if you put it at the top, it will appear at the top. If you place it half way down the page, it appear somewhere in the middle of the article.

How to edit a sidebar

To edit a sidebar, you treat it just like a regular article. Click on the "Edit This Page" button on the sidebar page and make whatever changes you want just as you do on any article in the Wiki.

To access the sidebar to edit, you can type in the search box "Template:Example-sidebar." This will take you right to the sidebar article without having to go through a page where the sidebar appears.