HTML Logo by World Wide Web Consortium (www.w3.org). Click to learn more about our commitment to accessibility and standards.

Moving forward with Composr

ocPortal has been relaunched as Composr CMS, which is now in beta. ocPortal 9 will be superseded by Composr 10.

Head over to compo.sr for our new site, and to our migration roadmap. Existing ocPortal member accounts have been mirrored.


Changing TITLE of blocks

Login / Search

 [ Join | More ]
 Add topic 
Posted
Rating:
#69702 (In Topic #14774)
Avatar

Community saint

Some blocks allow you to change the TITLE param while others do not. It seems to me that we should be able to designate the title for pretty much any block.

Perhaps I am using ocPortal in a funny way where I want to provide equal standing to forum posts and blogs on the front page. I can get all that working but I would like to be able to change the title of side_news_categories and side_news_archives to "Blog categories" and "Blog archives", respectively. From my personal experience, you can't be too explicit about what a page element is if you want to avoid future user questions.

Just my thoughts.

Bob
Back to the top
 
Posted
Rating:
#69704
Avatar

Community saint

Here's a workaround for you:
  1. Adminzone -> Style -> Themes -> Edit Template (from your theme, not the default)
  2. Select BLOCK_SIDE_NEWS_ARCHIVE.tpl
  3. Change the first line:

Original:

Code

{+START,BOX,{!ARCHIVES},,{$?,{$GET,in_panel},panel,classic}}
Modification:

Code

{+START,BOX,Blog archives,,{$?,{$GET,in_panel},panel,classic}}
4) Repeat with BLOCK_SIDE_NEWS_CATEGORIES.tpl

Original:

Code

{+START,BOX,{!CATEGORIES},,{$?,{$GET,in_panel},panel,classic}}
Modification:

Code

{+START,BOX,Blog categories,,{$?,{$GET,in_panel},panel,classic}}

One of the beautiful things about ocPortal is there is always more than one way to remove the skin from the proverbial cat. ;)

"no violence, no hate, no pain, no enemies
just peace, unity, tolerance and love" - The Beloved

OCP V7 | Advocating monetary reform - FreeOurMoney

Need OCP friendly hosting? Look no further:
Web Hosting, Reseller Hosting, and Dedicated Servers w/cPanel - Elief! - Official hosting partner for ocPortal.
Back to the top
 
Posted
Rating:
#69706
Avatar

Community saint

Thanks SoccerDad-

Yeah, I thought of making the template changes but then I would potentially need to reconcile them at each upgrade.

What I have decided to try instead is replacing the language variable. That should make my changes resistant to future upgrades since the variables will be stored in the database rather than some template.

I have not found them so far but at least I am getting a better knowledge of ocPortal.

Thanks again-

Bob

EDIT: Made the changes in the language file and they appear as I want in the front-end. Hopefully, it will not mess anything else up in the front-end. I don't care about the admin area since I can deal with such oddities.


Last edit: by BobS
Back to the top
 
Posted
Rating:
#69716
Avatar

Community saint

Hey Bob! The language file change is also a good angle; I keep forgetting about that lol. As for template changes, they are stored in templates_custom in your theme directory and as such are not overwritten upon upgrade.

"no violence, no hate, no pain, no enemies
just peace, unity, tolerance and love" - The Beloved

OCP V7 | Advocating monetary reform - FreeOurMoney

Need OCP friendly hosting? Look no further:
Web Hosting, Reseller Hosting, and Dedicated Servers w/cPanel - Elief! - Official hosting partner for ocPortal.
Back to the top
 
Posted
Rating:
#69720
Avatar

We'll give this block and also side_tag_cloud the option for a title parameter in the next patch.


Become a fan of ocPortal on Facebook or add me as a friend. Add me on on Twitter.
Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about ocPortal whenever you see the opportunity.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying ocPortal on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Back to the top
 
Posted
Rating:
#69722
Avatar

Community saint

:thumbs:

"no violence, no hate, no pain, no enemies
just peace, unity, tolerance and love" - The Beloved

OCP V7 | Advocating monetary reform - FreeOurMoney

Need OCP friendly hosting? Look no further:
Web Hosting, Reseller Hosting, and Dedicated Servers w/cPanel - Elief! - Official hosting partner for ocPortal.
Back to the top
 
Posted
Rating:
#69730
Avatar

Community saint

Thanks SoccerDad and Chris.

Great software. Great community. What;s not to like about ocPortal.
Back to the top
 
Posted
Rating:
#70115
Avatar

Community saint

Chris-

Any chance of also adding the ability to title the IOTD block. Some people will have "Image of the Week" or "Image of the Month". I'll be titling mine
"Editor's Pick".

I know I can change this in language variables but it would be good to be able to provide the appropriate title when creating the block.

Bob
Back to the top
 
Posted
Rating:
#70120
Avatar

Well, only one IOTD can be set, so it's not a case where you can have two blocks with different uses. If you change the block title but leave the language strings alone, the add screen will still say 'Image of the day' which personally I think would be confusing.


Become a fan of ocPortal on Facebook or add me as a friend. Add me on on Twitter.
Was I helpful?
  • If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
  • If so, please let others know about ocPortal whenever you see the opportunity.
  • If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying ocPortal on fun personal projects.
  • If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.
Back to the top
 
Posted
Rating:
#70124
Avatar

Community saint

Good point. I'll just change the language variable.

Bob
Back to the top
 
1 guests and 0 members have just viewed this: None
Control functions:

Quick reply   Contract

Your name:
Your message: