forum.coppermine-gallery.net

Support => cpg1.5.x Support => cpg1.5 miscellaneous => Topic started by: philippefx on August 12, 2010, 02:33:53 pm

Title: change the displayed "file informations"
Post by: philippefx on August 12, 2010, 02:33:53 pm
Hi,

When selecting "Hide/show file informations", some informations appears.

I would like to select what appears here, to show only : the full photo link's URL and the file name. And thus don't show anything else.

How can I do that ?


Thank you !

philippe
Title: Re: change the displayed "file informations"
Post by: Leonard Will on August 14, 2010, 10:38:54 pm
There was a plugin for 1.4.x called "display fields" which allowed you to specify which fields were displayed. It does not seem to be available yet for 1.5.x, but I hope that it will be converted.

In the meantime I achieved this by modifying the function at ** Section <<<theme_html_picinfo>>> in my custom theme.php by inserting an "if" clause so that only the fields specified would print. I have custom fields named "Photographer", "Copyright owner" and "Date of picture". In place of

$html .= sprintf($template, $key, $value);

I now have

if (($key == 'Photographer') or ($key == 'Copyright owner') or ($key == 'Date of picture'))
{
$html .= sprintf($template, $key, $value);
}

Title: Re: change the displayed "file informations"
Post by: Me400 on August 15, 2010, 08:49:34 am
Hi

Iīm so stupid that I canīt find how to post a new post so I "reply" to this one which is the most close to the subject.

Iīve made 4 custom fields for image description. Yes, I added also information for each of the 4 fields.
However how to I made the informatino to show up under the thumbnails?
Today it looks like this:
Thumbnail
picture file name
views
stars
votes

Where shall I go, and which box shall I tick or leave open to make all 4 rows of custom fields to be diplayed?
Many thanks, stupid Me400.

 
Title: Re: change the displayed "file informations"
Post by: papukaija on August 15, 2010, 09:48:33 pm
@Me400: Common policies: Don't double-post/cross-post (http://forum.coppermine-gallery.net/index.php/topic,55415.msg270632.html#msg270632)
Title: Re: change the displayed "file informations"
Post by: Me400 on August 16, 2010, 12:20:07 am

Hey there,

I told you all that Iīm a stupid newbie. That wasnīt even a joke.
Your statement didnīt answer my question "how to post a message" but than+s for that info anyway.
I still canīt find a bottom for to make a NEW topic. Like: "Send" "Post" etc???? 
Anyone out there understanding my dilemma and can guard me out from where I am right now
and then I might get an answer for my 2 nd question which was:

How to make "the 4 custom fields for image description visible"?

Iīm so proud of myself that Iīve managed to integrate gallery 1.5.6 into my site
http://oddstamps.com/Free-Stamp-Catalogue.php
where you can see that the 4 fields doesnīt appear but the rest of the file info
and I canīt figure out why depend less reading all info and ticking and un-ticking all boxes.

Iīm a nice guy and do not double-post nor cross-post only keep my topic within the closest posted related topic
but it would be nice to be able to start a new topic and hopefully I will get some response for my second question as well.

Wishing you all nice weekend
Cheers
Title: Re: change the displayed "file informations"
Post by: philippefx on August 16, 2010, 01:26:04 pm
There was a plugin for 1.4.x called "display fields" which allowed you to specify which fields were displayed. It does not seem to be available yet for 1.5.x, but I hope that it will be converted.

In the meantime I achieved this by modifying the function at ** Section <<<theme_html_picinfo>>> in my custom theme.php by inserting an "if" clause so that only the fields specified would print. I have custom fields named "Photographer", "Copyright owner" and "Date of picture". In place of

$html .= sprintf($template, $key, $value);

I now have

if (($key == 'Photographer') or ($key == 'Copyright owner') or ($key == 'Date of picture'))
{
$html .= sprintf($template, $key, $value);
}



There was no "theme_html_picinfo" in my template, but I just copy this function from the "samples" theme directory.

And it works. Formidable. Thank you.


(BTW, could a mod remove the 3 upper off-topic messages ? Thanks !)
Title: Re: change the displayed "file informations"
Post by: papukaija on August 16, 2010, 05:20:57 pm
Your statement didnīt answer my question "how to post a message" but than+s for that info anyway.
My reply wasn't supposed to answer your question.

I still canīt find a bottom for to make a NEW topic. Like: "Send" "Post" etc????
Try this link (http://forum.coppermine-gallery.net/index.php?action=post;board=115.0) for a new topic in cpg 1.5.x miscellaneous sub-board. The "new topic" button should be above "Last post" field, if not wait for a dev/moderator to see your question (but be aware, this isn't SMF's support board).

Anyone out there understanding my dilemma and can guard me out from where I am right now
and then I might get an answer for my 2 nd question which was:

How to make "the 4 custom fields for image description visible"?
Btw, your question is answered at least partly, in the docs (http://documentation.coppermine-gallery.net/en/) (but as you should know, reading the docs is part of board rules).
Title: Re: change the displayed "file informations"
Post by: Me400 on August 17, 2010, 04:57:56 pm

Hi

Many thanks for to guard me to the right places.
Iīll study the docs again before making a new post.
For a newbie ::) it hasnīt been easy, however The Gallery is just so good that I just have to get it right.

Again, thank you very much - Iīm learning.

Cheers