coppermine-gallery.com/forum

No Support => Feature requests => Topic started by: Dancefloor on March 19, 2026, 11:42:43 AM

Title: Header PHP with Login Security Check
Post by: Dancefloor on March 19, 2026, 11:42:43 AM
Hyyy...
In my header.php are some things like Database backup and other useful admin tools included.

Unfortunately, it's displayed as a header and visible to EVERYONE who visits the site.

Isn't it possible to display it on a user-specific or admin-specific basis?

So... either EVERYONE sees it, or user groups, or ONLY ADMIN.

Could this query be included in the next version, or is there a simple way to query the admin status directly within the header file?

Regards, Daniel
Title: Re: Header PHP with Login Security Check
Post by: 406man on March 19, 2026, 06:07:10 PM
My gallery doesn't have a file with this name and the forum thread here says the same:
https://coppermine-gallery.com/forum/index.php?topic=80854.0

For a starting point could you clarify what your header.php file is doing and where it lives in your directory structure.

The admin tools are normally in the Admin menu which is displayed only for those users with Administrator privilege.
Title: Re: Header PHP with Login Security Check
Post by: ron4mac on March 20, 2026, 02:55:06 AM
You can use some of these variables and defines in your custom header include file to present different content according to the CPG state (logged in [USER_ID>0], user is an admin, etc.)
https://coppermine-gallery.com/docs/curr/en/dev_vars.htm