solved I Lost my Profile Menu on Update

Ken Rich
Ken Rich
@ken-rich
11 years ago
926 posts
I did the Ningja update to 1.09 and lost my profile menus. To be clear, not just from the Forum (which I want) but from everywhere.

In other words, in a profile all you had was whatever landing page was chosen and you couldn't access anything else because the menu was gone.

The problem appears to be this snippet of code. When I delete it the menu reappears.

Does anyone know why that would be? Is anyone else having this issue?

{if isset($_conf.jrNingja_forum_profile) && $_conf.jrNingja_forum_profile != $current_url} {/if}



--

Ken Rich
indiegospel.net

updated by @ken-rich: 07/09/16 09:21:02AM
brian
@brian
11 years ago
10,148 posts
I've setup a demo site:

http://demo.jamroom.net/jrNingja/groove-digger

and don't see any issues with it there, but I'll see if I can replicate it by manipulating that bit of code.


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net

updated by @brian: 12/29/14 09:23:54AM
brian
@brian
11 years ago
10,148 posts
Make sure your "Forum Profile URL" setting is correct - if it is incorrect the menu ends up being hidden. It must be set to the ENTIRE URL to your main site forum. So on our demo site I have it set to:

http://demo.jamroom.net/jrNingja/demoadmin/forum

Make sure yours is correct and it works.

Hope this helps!


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net

updated by @brian: 12/29/14 09:23:54AM
Ken Rich
Ken Rich
@ken-rich
11 years ago
926 posts
Hi Brian,

That doesn't appear to be the issue. Mine was set correctly (see attached).
Forum3.JPG.jpg
Forum3.JPG.jpg  •  36KB




--

Ken Rich
indiegospel.net

updated by @ken-rich: 12/29/14 09:23:54AM
Ken Rich
Ken Rich
@ken-rich
11 years ago
926 posts
Could it possibly be my unique set-up, where Ningja is only run in profiles?


--

Ken Rich
indiegospel.net

updated by @ken-rich: 12/29/14 09:23:54AM
Ken Rich
Ken Rich
@ken-rich
11 years ago
926 posts
I did an experiment in my "sandbox" site. I can definitely conclude that Ningja also has to be the active skin for this to work.

It doesn't matter which skin you substitute for active, unless it's Ningja it produces a missing profile menu on all profiles.

So I guess the question is, what (if anything) would allow this to work when another active skin is chosen through admin skin?


--

Ken Rich
indiegospel.net

updated by @ken-rich: 12/29/14 09:23:54AM
douglas
@douglas
11 years ago
2,797 posts
It may not work as the active skin needs to have the skin setting for the forum URL.

You might try adding that to your active skins config.php file, other than that, I don't think using Ningja with other skins is going to work.


--

Douglas Hackney
Jamroom Team - Designer/Developer/Support
FAQ-Docs-Help Videos

updated by @douglas: 12/29/14 09:23:54AM
Ken Rich
Ken Rich
@ken-rich
11 years ago
926 posts
I've been screwing around on my sandbox site and this seems to work. Probably because it's not bothering with what the config settings are, but just directly checking for the specific URL. Do you foresee a problem?

{if 'http://sandbox.indiegospel.net/indie-gospel/forum' != $current_url}{else}{/if}



--

Ken Rich
indiegospel.net

updated by @ken-rich: 12/29/14 09:23:54AM
Ken Rich
Ken Rich
@ken-rich
11 years ago
926 posts
I'm running that code (I gave above) on my main site right now and don't seem to be having issues.

Of course I am checking for the exact URL of the Forum on the main site, above is the sandbox URL.


--

Ken Rich
indiegospel.net

updated by @ken-rich: 12/29/14 09:23:54AM
douglas
@douglas
11 years ago
2,797 posts
That should do it, as its basically the same thing. Glad you figured it out. :)


--

Douglas Hackney
Jamroom Team - Designer/Developer/Support
FAQ-Docs-Help Videos

updated by @douglas: 12/29/14 09:23:54AM
Ken Rich
Ken Rich
@ken-rich
10 years ago
926 posts
douglas:
That should do it, as its basically the same thing. Glad you figured it out. :)

Ooops - actually my solution has a flaw. That takes away the profile menu on just the one specific forum page, but all the internal forum pages still have it.

So, I need to add a wildcard to the URL ending. Or else a statement that says when "indiegospel/forum" exists in the URL, take action.

So this code needs a wildcard ending on the URL, where XXXXX represents the wildcard ending.

{if 'http://indiegospel.net/indiegospel/forumXXXXX' == $current_url}
{else}{/if}

One would think that would be simple. However, after many hours researching and testing, I've seen all kinds of wildcard values like * $ ^ ? and various combinations like ?* but none of them seem to work.

Does anyone have a solution?


--

Ken Rich
indiegospel.net
paul
@paul
10 years ago
4,335 posts
I'd try the php command 'strstr'. This returns true if one string is found anywhere inside another, so

{if strstr($current_url, 'http://indiegospel.net/indiegospel/forum')}
{else}
{/if}


--
Paul Asher - JR Developer and System Import Specialist
Ken Rich
Ken Rich
@ken-rich
10 years ago
926 posts
Paul you are a genius - that worked like a charm. Problem solved - thanks so much!!!


--

Ken Rich
indiegospel.net