Jump to content
TNG Community
Paul Barrett

Default Living Flag to Unchecked

Recommended Posts

Paul Barrett

99.9% of the people my users enter are dead, yet the Living Flag defaults to on, which causes issues if a user forgets to uncheck it.  I'd like to change the default setting.

On the TNG Facebook page Ned Abell gave me a fix for the Add Person Page in TNG Admin but I use the version in admin_editfamily.php where line 363 says:

<input type="checkbox" name="living" value="1"<?php if( $row['living'] ) echo " checked=\"checked\""; ?>> <?php echo $admtext['living']; ?>&nbsp;&nbsp;

This code differs from the TNG Admin Add Person so i don't know how to change it.

I'd appreciate some help please.

It may be irrelevant but when I did a search for "living" in the admin_editfamily.php it came up with loads of results beside line 363.  As far as I can tell they are testing a value and line 363 is where that value gets assigned in the data entry screen?

Regards

 

 

Share this post


Link to post
Share on other sites
JRobison

You don't want to change that Paul. It indicates that the family has already been set to living.

The line you want is in admin_newfamily.php.

In line 258 remove checked="checked". Also line 213 in admin_newperson.php

Share this post


Link to post
Share on other sites
JRobison

The Reset Living Flag mod by Ulli Heist will unset the living flag on save if any death or burial info is entered.

Very handy. I couldn't find it in TNG mods so I attached it here.

Reset_living_flag_v9.2.2a.zip

Share this post


Link to post
Share on other sites
Paul Barrett

Thanks Jeff

Did that but it had no effect.  So I also edited the preceding value field from 1 to 0.  Also no effect.

Si I had a rethink.

Are you sure I don't need to edit admin_editfamily.php?  Because when I select the option to add a child to a family, that's the screen that is listed in the address bar.

2017-09-20_23-28-35.png

The syntax of what looks like the relevant line (see OP) is very different from the others and seems to have an if statement wrapped around it.

 

Regards

 

Paul

Share this post


Link to post
Share on other sites
JRobison

No, that is a popup with admin_newperson.php running.

 

Share this post


Link to post
Share on other sites
Paul Barrett

OK, thanks Jeff

Then I don't know how to proceed next as I have completed all suggested tasks to no effect.

One for Darrin, I think.

 

Paul

Share this post


Link to post
Share on other sites
JRobison

Not sure what you are doing but if you ..........

Remove checked="checked" from line 258 in admin_newfamily.php.

Remove checked="checked" from line 213 in admin_newperson.php.

The living check box WILL NOT be checked by default.

 

Share this post


Link to post
Share on other sites
manofmull

Jeff

I was pointed to this thread as I find "living" for new people/families very annoying too.

Tried what you suggested but boxes are still checked as living, same as Paul

 

Share this post


Link to post
Share on other sites
JRobison

I forgot the checked="checked" in line 112 in admin_newperson2.php must also be removed.

Share this post


Link to post
Share on other sites
manofmull

Jeff

Do I delete "checked" or just checked i.e. do I leave the quotes blank  " " ?

Share this post


Link to post
Share on other sites
Paul Barrett

Make it

<input type="checkbox" name="living" value="1"> <?php echo $admtext['living']; ?>&nbsp;&nbsp;

 

Share this post


Link to post
Share on other sites
JRobison

Paul is correct but either way will work.

Share this post


Link to post
Share on other sites
Paul Barrett
1 minute ago, JRobison said:

Paul is correct but either way will work.

I wish I could claim the credit Jeff, but that line is from the man himself - Mr Darrin Lythgoe. :-D

Share this post


Link to post
Share on other sites
manofmull

I did what Paul suggested to all three files and now it works as required. Thanks to you both

 

M

Share this post


Link to post
Share on other sites
Paul Barrett

During my conversation with Darrin I did pose the question "Why don't we make the default = unchecked, since most of us are researching dead not living people?"

We do need to protect living people's data those because of Data Privacy laws.

 

Paul

Share this post


Link to post
Share on other sites
manofmull
2 minutes ago, Paul Barrett said:

During my conversation with Darrin I did pose the question "Why don't we make the default = unchecked, since most of us are researching dead not living people?"

We do need to protect living people's data those because of Data Privacy laws though.

 

Paul

Paul

Couldn't agree with you more !!

Privacy laws though are way out of date (last century) due to social media. Most people nowadays don't care and display their life for the world to see

Share this post


Link to post
Share on other sites
JRobison
1 hour ago, Paul Barrett said:

I wish I could claim the credit Jeff, but that line is from the man himself - Mr Darrin Lythgoe. :-D

Yes, I'm glad Darrin posted to remind me. I just forgot.

Share this post


Link to post
Share on other sites
Paul Barrett
2 hours ago, manofmull said:

Paul

Couldn't agree with you more !!

Privacy laws though are way out of date (last century) due to social media. Most people nowadays don't care and display their life for the world to see

Not so in the EU.  Even tougher laws being introduced next year.

I think the answer might be that some rules are devised to check for  a potential living person (DOB <100 years and no DOD) and prompt "This appears to be a living person.  Please confirm.  Yes / No Cancel"

 

Paul

Share this post


Link to post
Share on other sites
Chris Lloyd

Thanks Jeff - will be useful

Share this post


Link to post
Share on other sites
Chadhex

Hi,

I bought TNG 8 days ago and upload import my database on the website. The database contains 236000 persons and 189000 are mark as living. I'm trying to get ride of the check mark in the Living check box for 6 days now. Trying everything, even try export the database from the site to my computer, change the LIVING Y to NO, Import again.  The NO disappear and the box is check. Is your mod would remove the checked living box on every persons dead?

Claude

Share this post


Link to post
Share on other sites
Paul Barrett

Hi Claude

Welcome to the forum!

Unfortunately this mod does not do what you want.  It changes the setting of the Living flag when entering new records, from living to dead,

I've had a look through the mods and reports and I haven't found anything that will do what you want.  There is a report that will select those that are marked as living but that won't update the field. 

The GEDCOM file is a plain text file.  What you could do is examine the entries and find the Living flag in there, then use a global search and replace to reset it.  Then nuke your TNG data and re import it.  That's a clumsy approach and I'm not sure how you'd distinguish the genuine living people from the dead.

This sounds like one for the real experts on here.

 

Paul

 

Share this post


Link to post
Share on other sites
Ken Roy

The Living Flag Backup / Restore mod will backup Living flags and allow you to uncheck the flag before doing the restore.  However, that would require a considerable effort.

As recommended in your other post, you should contact Darrin and refer him to the post as well as describe you problem.  It is possible thre is a bug in the software that is causing the Living flag to get set.

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

×