Registration page full width, need menu modules

16 years 10 months ago #40157 by johnelaw
I can't figure out how to have my menu modules (which are published in the LEFT module position) appear during the registration phase of CB.

Of particular importance would be their appearance after a user updates their profile which I currently force on first-time visits.

Can anyone help?

Please Log in to join the conversation.

16 years 10 months ago #40261 by ffaabbss
publish the module for "all" and then in your template index.php u can limit the displ of that module again by following this post:
forum.joomla.org/index.php?topic=144174.msg719462#msg719462

I guess you could just add a bit of logic to a specific module position in the template to make it only show on CB pages. You can then set the module to show at this position on ALL pages (the template logic then takes care of only showing it on CB pages)

e.g. here we only load the position user5 on CB pages
Code:

<?php
if ( $_REQUEST == "com_comprofiler" ) {
mosLoadModules( 'user5' );
}
?>

Please Log in to join the conversation.

16 years 10 months ago #40360 by johnelaw
That sounds like what I want, but it's mostly over my head. I tried it in many places of my template (Joomlashack Aqualine Reloaded) but can't get it to work. What's annoying me is that I did get the template to only display the login module to guests using the same sort of process - I added it the guestonly position, added the guestonly position to the module templates and published it there. Works fine. So I thought I could add the above code to the same area of the template and have it work, but I've had no luck.

Here's the area of my template I think it should go:
[code:1]<div class="clear"></div>

<div id="wrapper">

<?php if (mosCountModules('left')) { ?>

<div id="leftcol">

<?php mosLoadModules ( 'left',-2 ); ?>

<?php if ($my->id == '0') mosLoadModules ( 'guestonly', -2 ); ?>

</div> <!-- END leftcol -->

<?php } ?>

<?php if (mosCountModules('banner')) { ?>

<div align ="center" style="padding:8px 0px 0px 0px; margin:0px -14px 0px 0px;">

<?php mosLoadModules ( 'banner',-1 ); ?>

</div>

<?php } ?>
[/code:1]


I think it should go right above or below the guestonly line. If it does go there, is the for the option call correct?

Any suggestions?

Please Log in to join the conversation.

16 years 10 months ago #40364 by ffaabbss
don't get your problem sorry. the solution i mentioned is straigth forward and should be problematic in any way.. please explain yourself some more...

Please Log in to join the conversation.

16 years 10 months ago #40430 by johnelaw
ffaabbss wrote:

don't get your problem sorry. the solution i mentioned is straigth forward and should be problematic in any way.. please explain yourself some more...


Well, I've created a menu called cb_menu. It has two items on it. One is a Link-Component Item back to the home page, and the other is a Link-Contact Item to the webmaster email. I'd like these to appear on every CB page so that users can either get home or help from the where they are. Currently, the CB pages are full width and the only way to navigate anywhere is with the browser buttons or by clicking the header to return to the home page.

What I gather is that I should set the menu to appear on All Pages, but then add some code to the template so that it only appears on the designated pages by publishing it to a module that only appears when called by the CB comprofiler page. So I've published this menu to All Pages in the user5 position.

I've changed my template code in the area where I think it should go (based on my adding the guestonly module position which is not included in my template) to this:

[code:1]<div class="clear"></div>

<div id="wrapper">

<?php if (mosCountModules('left')) { ?>

<div id="leftcol">

<?php mosLoadModules ( 'left',-2 ); ?>

<?php if ($my->id == '0') mosLoadModules ( 'guestonly', -2 ); ?>

<?php if ( $_REQUEST == "com_comprofiler" ) { mosLoadModules( 'user5' ); } ?>

</div> <!-- END leftcol -->

<?php } ?>[/code:1]

When I navigate to the CB Register page, by choosing "Register" from my CB login module, I don't see the menu.

Here's my site: www.motorcops.org

If you click the Register link in the login module, you'll see the CB Registration page that I'm speaking of, but no menu.

Please Log in to join the conversation.

16 years 10 months ago #40440 by ffaabbss
If u have published the module to user5 position you need to restrict the user5 position. No idea what your guestonly module is for if you have published the module to user5???
You need to add the javascript snippet around the user5 module position and publish user5 to all pages...
with the option in javascript "==com_comprofiler" you will only get the module on all pages that have "com_comprofiler" in the url...

If you want a module only for registered you can set that directly in the backend module page for each module. no need for javascript in template...

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.317 seconds

Facebook Twitter LinkedIn