Jump to content
TNG Community
lesdelc

What's New - Remove Photos (Solved)

Recommended Posts

lesdelc

How can I remove the Photos from being displayed in What's New? I checked whatsnew.php but could not find the code to remove photos.

Link:

https://my-genealogy.org/genealogy/whatsnew.php

Share this post


Link to post
Share on other sites
manofmull

I'm curious as to why you'd want to remove them.

In Admin / Misc you can try setting to zero 'What's New' Limit:

Maybe tweaking the 'What's New' Days:

 

Michael

Share this post


Link to post
Share on other sites
lesdelc

The Misc changes are applicable to all categories (Photos, Documents, Headstones, Individuals, Families). I need to determine where the code is in whatsnew.php & prevent the photos from being displayed. 

Share this post


Link to post
Share on other sites
tngrlkrz

You realize not only thumbs but previews and links to the media are involved as well?  What would be left that you want displayed in What's New?

UPDATE:  have Private Messaged you after Brett's clarification of what you were looking for.

Ron

Share this post


Link to post
Share on other sites
Brett

It seems he wants to only show What's New Documents, Headstones, Individuals, Families items. Not new photos he has put on his site.

Share this post


Link to post
Share on other sites
tngrlkrz

OK, thanks Brett.  I think you're right, I missed seeing his request like that.  I have PM'd Lesdelc a  solution  if that's what is wanted.

Ron

 

Share this post


Link to post
Share on other sites
lesdelc
7 hours ago, tngrlkrz said:

OK, thanks Brett.  I think you're right, I missed seeing his request like that.  I have PM'd Lesdelc a  solution  if that's what is wanted.

Ron

 

Thanks, Ron for the solution.

Share this post


Link to post
Share on other sites
lesdelc
On 4/15/2019 at 2:05 PM, manofmull said:

I'm curious as to why you'd want to remove them.

In Admin / Misc you can try setting to zero 'What's New' Limit:

Maybe tweaking the 'What's New' Days:

 

Michael

Unfortunately, I do not have many photos of my family. I wanted to be sure that they are sourced before displaying them with What's New.

-Les-

Share this post


Link to post
Share on other sites
lesdelc
On 4/15/2019 at 1:47 PM, lesdelc said:

How can I remove the Photos from being displayed in What's New? I checked whatsnew.php but could not find the code to remove photos.

Link:

https://my-genealogy.org/genealogy/whatsnew.php

Ron,  provided the solution.

Share this post


Link to post
Share on other sites
tngrlkrz

Since lesdelc has indicated it works, here's the code changes to whatsnew.php (TNG 12.1):

At line 133:

change this:

    echo doMedia( $mediatypeID );

to this:

    if ($mediatypeID != "photos")    echo doMedia( $mediatypeID );

(it has been suggested  to me that it's OK to post snippet solutions here, but discouraged from posting cfg or mod files unless also posted on the wiki).

Share this post


Link to post
Share on other sites
theKiwi
3 hours ago, tngrlkrz said:

(it has been suggested  to me that it's OK to post snippet solutions here, but discouraged from posting cfg or mod files unless also posted on the wiki).

Posting code snippets is fine.

Posting .cfg files is fine too if they're not something that is already on the Wiki - eg a new Mod you have created and want people to test.

What I was trying to convey a while ago is that it is best to NOT post entire TNG files here for several reasons, including but not limited to:

  • copyright - Darrin holds the copyright on the code and this is a public facing forum;
  • they're hard to find if they're not in an immediate unread post;
  • when they have been updated by Darrin, the version(s) posted here are no longer current, yet remain available for people to download.

Roger

Share this post


Link to post
Share on other sites
tngrlkrz
38 minutes ago, theKiwi said:

Posting .cfg files is fine too if they're not something that is already on the Wiki

And what if it's a one off request from a user for a specific result from published mod that only takes a code snippet to accomplish?  Had that situation recently, and did a PM.  Is that appropriate, or can it be posted?

Share this post


Link to post
Share on other sites
theKiwi
4 hours ago, tngrlkrz said:

And what if it's a one off request from a user for a specific result from published mod that only takes a code snippet to accomplish?  Had that situation recently, and did a PM.  Is that appropriate, or can it be posted?

A code snippet of a change to a published Mod is fine to post here too - posting it here means everyone sees the answer.

Roger

Share this post


Link to post
Share on other sites
Ken Roy
25 minutes ago, theKiwi said:

A code snippet of a change to a published Mod is fine to post here too - posting it here means everyone sees the answer.

Roger

I will agree to publishing code snippets to published mods, except when the code snippet is to fix a problem (bug) in the publish mod, when the mod developer is not available to fix the problem, such as the recent case to the Public Access Control mod, where the correct action is to publish the updated version of the mod to the TNG WIki,

Share this post


Link to post
Share on other sites
theKiwi
2 hours ago, Ken Roy said:

I will agree to publishing code snippets to published mods, except when the code snippet is to fix a problem (bug) in the publish mod, when the mod developer is not available to fix the problem, such as the recent case to the Public Access Control mod, where the correct action is to publish the updated version of the mod to the TNG WIki,

My answer was assuming the situation that I believe Ron was referencing - a change to a Published Mod to make it have a different behaviour than the Mod's intention - the Relationship thing that was discussed a couple of days ago.

Roger

Share this post


Link to post
Share on other sites
Brett

Yes Roger, that is the Mod Ron was referring to.

As a side, I am looking (with Ron's help) to incorporate some of your Mod into the other one, to perform how I want them to.

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

×