Jump to content
TNG Community
Clan Maclellan

Mod Wanted or Code

Recommended Posts

jayat1familytree

Merv,

Great job so quickly.

However in the long run I'd prefer to see the links as part of the standard menu bar either as a drop down list or a kink to a new unique page of links for the user.

 

tng_enhacement_user_links_page_link.jpg

 

that way all tng templates could take advantage of this enhancement.

Thanks,

 

Jay

 

 

 

 

User_links_location_in_menu.jpg

Share this post


Link to post
Share on other sites
Merv

Hi Jay,

The links should work on all templates. It just depends on which method is employed. It's just that on some templates, the only easy option is to have them on the homepage. In the long run Darrin may decide to make these as standard on all templates. They don't however integrate well with the current His/Her links, so those may have to be abandoned.

In your case, I would put them in the left side menu as they will be visible on all your website pages. Maybe have them in their own section titled My Pages.

FireShot Screen Capture #118 - '1FAMILYTREE Genealogy' - 1familytree_com_genealogy_index_php.jpg

I am trialing the personalised links in a drop-down menu but I'm not convinced that it is the best place for them because they are hidden most of the time. I think they should be readily visible similar to the home links because they basically point to the users own home pages and charts.

Screen Capture #020.png

Share this post


Link to post
Share on other sites
tngrlkrz

I tend to agree with Jay,  that it would be ideal to have usability in all templates, such as the left icon group. However that doesn't accommodate some templates' homepages. It could alternately be labelled 'Your Pages' (personal preference over 'My Pages') so the user could easily see them by merely hovering over them. I don't necessarily think the user needs see all options on every page.

Just an FYI.  On my site, which doesn't fit this model since I moved the left icons generally to a fixed 'toprow' concept, and is considerably modifed with 22 templates, 15 of them modified originals, a hovered 'Your Pages'  is visible (to registered users with personal ID assigned only) on all pages of all templates, in the 'toprow' arrangement. 

Share this post


Link to post
Share on other sites
Merv

Hi Ron,

Each to their own. I am simply trying to provide the code with options. As per the instructions, users can label the links as they wish. I have used My Page etc because that is what is used in the original Open My Page mod and rather than buck convention, I have decided to stick with it. If I remember correctly, the code you are using came from me anyway, so I'm glad you have worked out how to customise it for your site. Well done.

As I've said earlier,, IMO I don't think they belong hidden in a drop-down menu. Neither should they be mingled among other drop down menus. They are links to a persons personal pages and should be more prominent than that. If however,  someone wants to write the code that puts the links in a drop -down menu (like you have done) and post it in the Wiki for others to use then they are welcome to do that.

Share this post


Link to post
Share on other sites
tngrlkrz

No problem, just sharing my opinion.  Yes I modified Erik Hoppe's Open My Page a bit,  and integrated Jeff Robison's  'Your Bookmarks' mod (hence the 'Your' Pages as well) with Bart DeGryse's 'Persistent Bookmarks'  into a pull down menu as well.   As you can see, I have used various authors' Mods in my design. Not sure which  code of yours I employed, but sorry if forgot some piece, was it a Mod, or some CSS perhaps?  I know you've been helpful to many and good job on the Wiki, BTW.  

Share this post


Link to post
Share on other sites
Merv
35 minutes ago, tngrlkrz said:

Not sure which  code of yours I employed, but sorry if forgot some piece, was it a Mod, or some CSS perhaps?

It was from this post...

 

Share this post


Link to post
Share on other sites
tngrlkrz

Merv,

I checked back in my archives from November 2016 and at that time was in the process of building links into a fixed top row.  The idea in Open My Page mod was pivotal to personalizing some of those links to a logged on user, and I see within that mod you are credited by Erik along with a couple others "Open My Page mod, version 10.0.0.4: Additions and suggestions by M. Pannier, M. Priestley and M. v.d. Heuvel."

The helpful code in particular  from that Mod was this line: 

if ($currentuser && $_SESSION['mypersonID'] != "" && $currentuser && $_SESSION['mygedcom'] != "") .

Thanks again for your contributions and ideas.

Share this post


Link to post
Share on other sites
Merv
5 hours ago, tngrlkrz said:

 The idea in Open My Page mod was pivotal to personalizing some of those links to a logged on user, and I see within that mod you are credited by Erik along with a couple others "Open My Page mod, version 10.0.0.4: Additions and suggestions by M. Pannier, M. Priestley and M. v.d. Heuvel."

The helpful code in particular  from that Mod was this line: 

if ($currentuser && $_SESSION['mypersonID'] != "" && $currentuser && $_SESSION['mygedcom'] != "") .

If you only got the idea from me and decided to refer to the mod  to code the personalised links yourself after I had already coded them, then I owe you an apology.

5 hours ago, tngrlkrz said:

Thanks again for your contributions and ideas.

You are welcome.

Share this post


Link to post
Share on other sites
georgicus

Merv, two thumbs up --- I love what you did with this!  Especially since I use template 13.

The first two visitors to the site I'm setting up were confounded by the "his side/her side" bar.  And on reflection, it didn't make any sense to me, either, plus it occupied precious real estate at the top, so I simply stubbed it out.  But your update is compelling enough for me to pick up.

Share this post


Link to post
Share on other sites
Merv

It has been brought to my attention that the link to the Template 15 coding isn't working in the Wiki so here it is again...

This is the code that goes into the (Template 15 topmenu.php file around about line 15...

<!–Start Personalised Links for Template 15 top menu)–>
<li class="menu-item"><a href="<?php if ( $_SESSION['mypersonID'] != "" && $currentuser && $_SESSION['mygedcom'] != "") {
$xerxxTarget = $cms['tngpath'] . "getperson.php?personID=" . $_SESSION['mypersonID'] ."&amp;tree=" . $_SESSION['mygedcom'];
echo "{$cms['tngpath']}$xerxxTarget";}
else  echo "{$cms['tngpath']}login.php"; ?>
"><span class="l"></span><span class="r"></span><span class="t"><b>&#128100; My Page</b></a></span></a>
</li>

<li class="menu-item"><a href="<?php if ( $_SESSION['mypersonID'] != "" && $currentuser && $_SESSION['mygedcom'] != "") {
$xerxxTarget = $cms['tngpath'] . "family.php?personID=" . $_SESSION['mypersonID'] ."&amp;tree=" . $_SESSION['mygedcom'];
echo "{$cms['tngpath']}$xerxxTarget";}
else  echo "{$cms['tngpath']}login.php"; ?>
"><span class="l"></span><span class="r"></span><span class="t"><b>&#128100; My Family</b></a></span></a>
</li>

<li class="menu-item"><a href="<?php if ( $_SESSION['mypersonID'] != "" && $currentuser && $_SESSION['mygedcom'] != "") {
$xerxxTarget = $cms['tngpath'] . "verticalchart.php?personID=" . $_SESSION['mypersonID'] ."&amp;tree=" . $_SESSION['mygedcom'];
echo "{$cms['tngpath']}$xerxxTarget";}
else  echo "{$cms['tngpath']}login.php"; ?>
"><span class="l"></span><span class="r"></span><span class="t"><b>&#128100; My Ancestry</b></a></span></a>
</li>
<!–End Personalised Links for Template 15 top menu)–>

Below is the topmenu.php file that I tested the code with...

 

topmenu.php

Share this post


Link to post
Share on other sites
jayat1familytree

Merv,

I missed a few days here, jumping back to your reply on Aug 6,

Normally I would agree about putting links into the left menu, but because of trying to get a better MOBILE site in the future I am planning on eliminating that left menu and have everything avail from drop menus , which will translate nicely when needed by MOBILE site visitors.

I need to modify one of the existing tNG templates to my color scheme and remove any left or right side navigation menus.

But CSS is my weakest skill....

 

 

 

Share this post


Link to post
Share on other sites
Merv
49 minutes ago, jayat1familytree said:

 

I need to modify one of the existing tNG templates to my color scheme and remove any left or right side navigation menus.

But CSS is my weakest skill....

Another option would be to migrate to a standard TNG template where all the CSS is done for you as far as mobile/tablet responsiveness.

There are a few blue templates there that would give your website a new fresh look without going too far away from your existing layout.

Share this post


Link to post
Share on other sites
Janos Dibusz

Nice job.
I would like add Branches. Somebody know how?

Share this post


Link to post
Share on other sites
Janos Dibusz
On 2017. 08. 05. at 6:15 PM, tngrlkrz said:

Very nice Merv.  I too have personalized the header of all pages (with a fixed row which doesn't scroll away) for registered users, so they can see immediately their specific TNG pages.  I added a Relatives page as well which permits seeing a linkable list of cousins as well.

 

top.png

How you do this? Can yousend my the code privat?

Share this post


Link to post
Share on other sites
tngrlkrz

Janos,

I only displayed that to show the concept of a fixed row with dropdowns.  That part of my site is highly customized and integrated with my homepage, topmenu, footer, and as well as the 

'color theme' (now called 'skin select') so too personalized and complex to share.  As mentioned though in this thread, TNG's template 15 gave me the idea for this, so you would have to start there.

Ron

Share this post


Link to post
Share on other sites
Janos Dibusz
1 hour ago, tngrlkrz said:

Janos,

I only displayed that to show the concept of a fixed row with dropdowns.  That part of my site is highly customized and integrated with my homepage, topmenu, footer, and as well as the 

'color theme' (now called 'skin select') so too personalized and complex to share.  As mentioned though in this thread, TNG's template 15 gave me the idea for this, so you would have to start there.

Ron

Ok. I understand.
So have you any idea for Branches?

Share this post


Link to post
Share on other sites
tngrlkrz

Sorry, no.  Only have 1 branch and 1 tree.  I know some folks are working on solutions though. Check threads on this forum and subscribe to tngusers2@lythgoes.net.  Many folks exchange ideas there.

Ron

Share this post


Link to post
Share on other sites
tngrlkrz
14 hours ago, jayat1familytree said:

Merv,

I missed a few days here, jumping back to your reply on Aug 6,

Normally I would agree about putting links into the left menu, but because of trying to get a better MOBILE site in the future I am planning on eliminating that left menu and have everything avail from drop menus , which will translate nicely when needed by MOBILE site visitors.

I need to modify one of the existing tNG templates to my color scheme and remove any left or right side navigation menus.

But CSS is my weakest skill....

 

 

 

Also assume you would make use of the  Mobile Site Enhancements mod too.  I actually altered the code a bit so that I could display 'mobile' or 'standard' mode on either laptop or phone.  I also put the switch button at top and bottom of every page.  Sometimes nice to use mobile on laptop screen and standard on phone.

Ron

Share this post


Link to post
Share on other sites
Merv
10 hours ago, Janos Dibusz said:

Nice job.
I would like add Branches. Somebody know how?

Could you elaborate? add branches to what??

Share this post


Link to post
Share on other sites
manofmull
On 06/08/2017 at 10:07 PM, Merv said:

Merv

Good job with this, thank you very much. I'm using template 5 and chose bottom left corner of homepage.

One thing though. When logged out, clicking on any of the three links takes you to the login page (of course), but once logged in it's back to the homepage. I thought I'd jump to whichever link I chose, if you know what I mean. I do understand that from the homepage it gives you the choice again of which link to choose. I'd personally prefer the link to open in a new browser tab, so it's side-by-side with the homepage.

 

Michael

Share this post


Link to post
Share on other sites
Merv
4 hours ago, manofmull said:

When logged out, clicking on any of the three links takes you to the login page (of course), but once logged in it's back to the homepage. I thought I'd jump to whichever link I chose, if you know what I mean. I do understand that from the homepage it gives you the choice again of which link to choose.

Hi Michael, Thanks for picking that up.

The trouble is that the system doesn't know which user you are until after you log in and therefore can't refer back to the link beforehand (because there isn't one) to forward you to your personal page of your choice... if you know what I mean..

A better code to use would probably be the extended code of which I will put up on the Wiki shortly.

EDIT... Try that now

http://tng.lythgoes.net/wiki/index.php?title=My_User_Links_Add-on

Share this post


Link to post
Share on other sites
tngrlkrz

Merv,

Interesting, but different than my experience  on my site, where login is not required but restrictions of course in place for living, media , etc.  If I am a guest user, and proceed to a page permitted, and then click to the login popup or screen, I am returned to the page I was viewing.  I'm likely missing something here.

Ron

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×