i have embedded Gallery2 within a simple php authentication page of my own.
In general everything seems to be working.
I have set the system to allow the users to upload their own watermarks, but then they can't find any way to delete some that they don't like.
The User administration of watermarks seems to be within the "Your Account/User Options", which doesn't show up within my embedding. I don't want the users to be able to change password, name, or email address, but letting them set Language might be useful, and i definetly want them to be able to get at the Watermarks admin screen.
Could this be done by building a different template?
Posts: 8601
try putting
<a href="{g->url arg1="view=core.UserAdmin" arg2="subView=watermark.UserWatermarks"}">link</a>
somewhere in your theme's tpl files and see how the direct link works. the sidebar there may then show too many links, not sure.. you could also try just {g->url arg="view=watermark.UserWatermarks"} but I don't know if that even works.Posts: 6
i created a themes/matrix/templates/local directory and copied,modded the sidebar.tpl to have the "<a href" inside the "gsSidebar" div, as the last thing in the div
the "<a href..." method shows up on the bottom of every sidebar and seemed to work the first time i tried it. i got the watermark management screen and it showed me the one watermark that i had uploaded, and gave me the option to upload another...
but then i went into someone elses gallery and clicked on the link at the bottom of the sidebar, and i get the watermark "upload" page, but it doesn't show any of the watermarks that i or the other user have. I also clicked on view as "guest" and i get the option to go into the watermark control screen.
Is there a way to limit the inclusion of the option to an "authenticated" user?
What controls the user that the "watermark" screen is working on?
the "{g->url..." method caused the text "index.php" to be included in the page. Just that text, by itself on a line. Not as a link <a> or anything else. So no go on that one...
Posts: 8601
See http://codex.gallery2.org/Gallery2:Themes:Reference:Variables
{if $user.isRegisteredUser} ..stuff here.. {/if}
The UserWatermarks screen shows watermarks for the current user. In Site Admin / Watermarks an admin can add watermarks usable by all users. When users add images in UserWatermarks then they are usable only by that user.
Posts: 6
that if query worked great for keeping it off of the guest displays! thanks
is there a query to determine that the album being shown belongs to the $user?
i would like the watermark management link to show up only in the sidebar if i am working on my own albums.
Posts: 8601
{if $user.id == $theme.item.ownerId} ... {/if}
Posts: 6
that did it! great. thanks