Adding a content block to a page on your site
Submitted
.Ian
, Nov 24 2011 07:47 AM | Last updated Nov 24 2011 09:19 AM
[docwarning]This tutorial involves editing a template. Whilst this is straight forward and should not cause any issues, we recommend testing your community both prior to and after any changes. You may need to revert any changes if seeking support in the future.[/docwarning]
Adding a content block to a page on your site - maybe within your forums or IP.Gallery
If you wish to add some additional content to your community, you could either edit a template directly, adding some html code or you could create a block within IP.Content.
The benefit of adding a block is that in order to display or indeed hide the block you need to add one single line to your template, rather than many lines of code.
This tutorial will explain how to create a banner or announcement at the top of every page on your site.
We will start with the final result and then explain how it was created.
[doctitle]Step One:[/doctitle]
Select the blocks section within IP.Content from within your ACP
[doctitle]Step Two:[/doctitle]
Click on Add Block
[doctitle]Step Three:[/doctitle]
Enter into each step within the block wizard the information required:-
[doctitle]Conclusion:[/doctitle]
It is easy to add blocks to display on any part of your website, not just within IP.Content pages. Have a go to add blocks in various locations and enjoy.
[doctitle]Further Assistance[/doctitle]
Should you require further assistance why not make a new topic and ask in the Technical Support forum for IP.Content.
Adding a content block to a page on your site - maybe within your forums or IP.Gallery
If you wish to add some additional content to your community, you could either edit a template directly, adding some html code or you could create a block within IP.Content.
The benefit of adding a block is that in order to display or indeed hide the block you need to add one single line to your template, rather than many lines of code.
This tutorial will explain how to create a banner or announcement at the top of every page on your site.
We will start with the final result and then explain how it was created.
[doctitle]Step One:[/doctitle]
Select the blocks section within IP.Content from within your ACP
[doctitle]Step Two:[/doctitle]
Click on Add Block
[doctitle]Step Three:[/doctitle]
Enter into each step within the block wizard the information required:-
- For this example we will select a 'Custom' block and click 'Next >>'.
- Because we are going to be adding some HTML to create our message, we will select this under 'Step 1' and click 'Next >>'
- For this example, under 'Step 2', we will enter 'Site Callout' as the title and 'site_callout' as the block key. If you wish to enter a description or place the block in a particular category on the blocks page you can, otherwise just ignore these options for now.
- At 'Step 3', you can add a caching interval - we have set this to 2 minutes as an example.
- At 'Step 4' this is where we would enter our HTML code - for this example we have added the following code.
<style type="text/css">
#callout {
background: #f7f0d2;
padding: 10px 0;
text-align: center;
color: #7d6812;
}
</style>
<div id="callout">
We will be closed Thursday 24th and Friday 25th November for Thanksgiving holiday. Ticket support is available, but non-emergency support response times may be delayed. We reopen as usual on Monday 28th November.
</div>
- Finally at 'Step 5' you will see a line
{parse block="site_callout"}this is the line that that we need to add to our template. You may now click Finish & Save.
- Staying within the ACP, click on 'Look & Feel'. You will see a list of your skins or themes appear.
- Click on IP.Board to edit the default IP.Board skin.
- On the left you will see a list of templates.
- Click on the one called 'GlobalTemplate'. This will then open on the right.
- Find the lines
</head> <body id='ipboard_body'>
- beneath this add the line
{parse block="site_callout"}- Click on 'Save' and then return to your community.
- You should now see the announcement banner at the top.
[doctitle]Conclusion:[/doctitle]
It is easy to add blocks to display on any part of your website, not just within IP.Content pages. Have a go to add blocks in various locations and enjoy.
[doctitle]Further Assistance[/doctitle]
Should you require further assistance why not make a new topic and ask in the Technical Support forum for IP.Content.
- BomAle likes this











2 Comments