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.


Banners - what am I overlooking

Login / Search

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

Well-settled

Ok…can't seem to figure out how to get a banner to display. I have set all relevant options I can think of

Setup > Configuration > Feature Options > Enable Banners = check

Content > Banners > Add Banner Type = Banner is defined and uploaded to the server in the banner folder. Banner is validated and "ready to be linked into the site" checked.

Checked Permission Tree editor and Global Permission to make sure nothing is interfering. The test banner will not display. In "deployment agreement" have tested all available options, none seem to have an effect. The test banner category is "General" and banner is visible when editing that category. Have viewed under user and guest permissions since it appears by default, admins are to "avoid banners"

Under the banner edit field is the text - "A banner will only be shown if the banner.php script is calledup asking to display banners of it's type (the 'General' type is thedefault). An example banner type might be 'skyscraper', and those wouldbe shown if {$BANNER,skyscraper} was placed in an appropriate place in the templates."

Not sure what I am supposed to do in that case…copy this file to the current template? Any pointers appreciated.
Back to the top
 
Posted
Rating:
#48609
Avatar

Is the banner set as a default banner, or does it have at least a positive number of hits assigned to it?

You haven't set it so the chance of a community banner is zero have you? (in the configuration).

If you haven't edited the HEADER to remove the banner code the default banner rotation should display there.


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:
#48622
Avatar

Well-settled

In Config I have "chance of community banner" set to 50.

No alterations to HEADER, and the following code is in the file:

{+START,IF,{$NOT,{$OR,{$EQ,{$ZONE},adminzone},{$AND,{$HAS_ZO
NE_ACCESS,adminzone},{$EQ,{$ZONE},cms}}}}}
{$SET,BANNER,{$BANNER}}
{+START,IF_NON_EMPTY,{$GET,BANNER}}
<div class="global_banner" style="text-align: {!en_right}">{$GET,BANNER}</div>
{+END}

Is this correct? Not sure what else I could be overlooking. I supplied the full path to the banner (and it displays in the 'edit banner' page). Not showing under either admin log in or a test user log in.
Back to the top
 
Posted
Rating:
#48624
Avatar

Well-settled

Add on note…

If I use the 'point to existing URL' instead of using upload, I receive the error message, "The specified URL to a local file doesn't point to an existing file.", even though I can point to the same address in browser and see the banner (?)
Back to the top
 
Posted
Rating:
#48691
Avatar

Can you take a screenshot of the edit screen for the banner. It's probably related to it's settings.

If I use the 'point to existing URL' instead of using upload, I receive the error message, "The specified URL to a local file doesn't point to an existing file.", even though I can point to the same address in browser and see the banner (?)

I'm no sure how this could happen, as the error should only be able to happen with a relative URL. But you can't put a relative URL into the address bar unless you change it.
If you changed it it might be that in ocPortal relative URLs are almost always treated as being relative to the base URL, which might no be what you're expecting.


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:
#48776
Avatar

Well-settled

In the Edit Banner screen, the banner is displayed in Current banner block

Destination url - with destination address

Banner type - name(dimensions) / dimensions match dimensions of Current banner

Validated - checked

In source media and text - url path to Current banner is displayed (uploads/banners/current_banner.gif) - Gif is a valid file type in Portal

Deployment -

Deployment agreement - I have tested each one of these - Permanent, Campaign and Default

Importance module - I have adjusted this number from 1 to 50 to 100, and used it with different combinations of the Deployment agreement

Expiry date - have used with no value, and have set a value (well into the future) with no effect.

After selecting 'Save', all looks to be well (no error messages) but banner does not appear.

If I change the url from 'uploads/banners/current_banner.gif' to 'http://site-name/uploads/banners/current_banner.gif', that is when I get the 'existing file does not exist' error.

Hope this helps.
Back to the top
 
Posted
Rating:
#48778
Avatar

I think I have just realised the problem. You added a new banner type? (sorry didn't notice this before).

In HEADER.tpl, change:

Code

{$SET,BANNER,{$BANNER}}
to:

Code

{$SET,BANNER,{$BANNER,<name-of-your-banner-type>}}


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:
#48780
Avatar

Well-settled

Perfect fix Chris...thanks!
Back to the top
 
Posted
Rating:
#48782
Avatar

We're making some changes, as this is an easy area to get confused about.
  1. In the next patch release a hint will be given when you add/edit a banner type.
  2. The tutorial will have a new 'troubleshooting section' that says all the reasons banners won't show.


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:
#48785
Avatar

Well-settled

Chris that's great.

If you could answer one last question on the banner subject…

I would like to disable the exemption admin's have to view banners ('avoid banners'), so that they are visible in an admin logon. So far I've been unable to locate a permission setting for this. Where would I look for that?

Thanks
Back to the top
 
Posted
Rating:
#48787
Avatar

There's a workaround, via running this ocCLE command:

Code

:set_value('always_banners','1');


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:
#48788
Avatar

Well-settled

Awesome…

I really appreciate the help.
Back to the top
 
Posted
Rating:
#48795
Avatar

For future reference, the reason that you need that ocCLE workaround is because ocPortal automatically grants administrators every "permission" available in the system. One of these permissions hides the banner – intended for "paid subscribers", for instance.

This ocCLE command effectively disables that permission for all usergroups.

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

Quick reply   Contract

Your name:
Your message: