Jump to content
TNG Community
Sign in to follow this  
Patrick Goosen

Change the search output

Recommended Posts

Patrick Goosen

Hi everybody,

Can I change the deault search output (name, id, birth, place, tree)? I want to add died as well. Any place I can change that?

 

Thanks,

Patrick

Share this post


Link to post
Share on other sites
tngrlkrz

One keystroke avoided if $showdeath is set in search.php. Otherwise see Bhemph.

Share this post


Link to post
Share on other sites
bhemph

On the Advanced Search page there is a checkbox right below how many results per page and a couple lines up from the search and reset buttons that says "Show death/burial information".  Check that and you will have the information added to your search.

Share this post


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

On the Advanced Search page there is a checkbox right below how many results per page and a couple lines up from the search and reset buttons that says "Show death/burial information".  Check that and you will have the information added to your search.

Only downside, one has to make sure ticked for each search or after 'reset', nice to have as default.

Share this post


Link to post
Share on other sites
bhemph

Ron, the session variable 'tng_search_showdeath' is set so that after the checkbox is checked the default is to be checked until you log out or hit the reset button.  If you want that to be the default, a mod to set that session variable on creation of the session would be needed and a change to the resetValues() javascript function in searchform.php to say document.search.showdeath.checked = true; would change the default behavior.

Share this post


Link to post
Share on other sites
tngrlkrz

bhemph,

Rather than default, I decided to always display death information.  Before seeing your response, what I have done is added to my private mod these statements, and all appears to work as I wished. I wanted spouse to appear always as well.

%target:search.php%

%location:%
$_SESSION['tng_search_showdeath'] = $showdeath;
%end:%

%insert:before%
$showdeath = "yes";
$showspouse = "yes";
%end:%

Further, in the mod I commented out  display of the tick boxes for both showing death and spouse from searchform.php.  In the Broad Search mod , added and set to always display the death date and location in  its results as well. I haven't been able to get spouse to display on the Broad Search yet.

Since the tables are responsive, I  think having this information always on the search results is more helpful than hindrance.

All the other search form parameters remain as before.

Ron

From Advanced Search:

2017-10-12_17-19-55.jpg

From Broad Search:

2017-10-12_17-24-51.jpg

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
Sign in to follow this  

×