Forum moderator: bigblog |
uCoz Community For Webmasters Design Customization Global Blocks (tutorial and FAQ) |
Global Blocks |
Global blocks are blocks available in all templates of your website. By means of global blocks you can optimize the design of your website, having splitted it into common parts. With the help of common blocks you can update the design on the whole website by means of editing only one block template. Where to create a global block in the Control Panel: Go to Customize Design -> Global blocks. Click New block. Enter a block name (let it be LINKS in our case) and click Add. A block name must contain only uppercase Latin letters, max length is 10 characters. This name will serve as the $code$ of the given global block in templates. A new block will be added to the list. In our case it is $GLOBAL_LINKS$. Go to Control Panel -> Customize Design and find the block template on the list of templates under Global blocks. Add any code you need to the template, save it, and paste its $code$ (e.g. $GLOBAL_LINKS$) into the templates where you want it to be displayed. Max number of global blocks is 10, including the 4 default blocks ($GLOBAL_AHEADER$, $GLOBAL_BFOOTER$, $GLOBAL_CLEFTER$, $GLOBAL_DRIGHTER$). The number of default blocks differs in different designs, some templates have only 3. Note: If you are going to edit templates you must have basic knowledge of HTML and CSS. Question-Answer How can I add a global block in a global block? You can't... we don't support global blocks nesting. I've noticed the global block $GLOBAL_SOANDSO$ will not run inside the $CONTENT$ area. Correct me if am wrong! You are right. Global blocks work in templates only Just 10 global blocks? 10 is the limit, you can't create more global blocks. Attachments:
1514136.png
(26.8 Kb)
·
8639095.png
(22.1 Kb)
·
7644645.png
(25.3 Kb)
·
4539422.png
(26.7 Kb)
·
3073300.png
(25.9 Kb)
I'm not active on the forum anymore. Please contact other forum staff.
|
How can i make a global block on viewable to members who have logged in?
|
PurpleBisch, use conditional operators - http://forum.ucoz.com/forum/37-471-1
I'm not active on the forum anymore. Please contact other forum staff.
|
I can make it so the block says different things for if they are logged in or not, but i can't seem to make the box disappear if they aren't logged in
|
yea. I want the global block to appear only when a user is logged in.
|
PurpleBisch, as Sunny said, use Conditional Operators - http://forum.ucoz.com/forum/37-471-1
|
It only tells me how i can change the text, i need to change the global block so its viewable only by members logged in >.<
|
>.< somehow i skipped over that part. Thankyou
|
ive noticed the global block $GLOBAL_SOANDSO$ will not run inside $CONTENT$ area.
correct me if am wrong!!! |
hi, i redesign the logo for my site and i put the code in a global block, but when i tried to import the global block into my template nothing happened, it works only with the code, with global block nothing :(.
Code <!-- <header> --> $LOGOBIG$ <!-- </header> --> Could be this because i use also in the gb this kind of code:
Code $WDAY$, $DATE$, $TIME$<br> <?if($USERS_ON$)?><?if($USER_LOGGED_IN$)?> Esti <a href="$PERSONAL_PAGE_LINK$" title="Profilul tau"><b>$USERNAME$</b></a> | Grup: <u>$USER_GROUP$</u> | <a href="$LOGOUT_LINK$"><b>Logout</b></a> <?else?> Buna <b>$USERNAME$</b><br> $LOGIN_FORM$ <?endif?><?endif?> Site-ul meu: http://eworld.ucoz.com
Post edited by donmarius - Sunday, 2009-07-26, 2:21 AM
|
donmarius, where are you trying to put the global block code? Most probably your logo is in "Top part of the website" which is a global block also. And you can't put one block inside another block, therefore use the full code.
I'm not active on the forum anymore. Please contact other forum staff.
|
| |||