Hi there!
I'm currently trying to embed images on an external page and I'm having troubles getting the authors name.
var authorName;
var imgComment;
authorName = img.author;
imgComment = img.comment;
<img title="'+authorName+'"...
<span class="comment">'+imgComment+...
Displaying the comment works, but the author output is giving me an "undefined".
Piwigo 2.9.3
Operating system: Linux
PHP: 7.0.28-0ubuntu0.16.04.1 (Show info) [2018-04-15 21:51:12]
MySQL: 5.7.20-0ubuntu0.16.04.1 [2018-04-15 21:51:12]
Graphics Library: External ImageMagick 6.8.9-9
Any pointers would be appreciated!
Best regards,
M
Offline
Ok I just realized that author doesn't have its own field, is there a way to grab it from the image infos?
Best regards
Offline
Yes.
see "pwg.images.getInfo" under http://piwigo.org/demo/tools/ws.htm
It returns author (among other things)
Offline
Yes that I have, but I can't figure out how to catch only the title. Doesn't matter though, I'll just use the image name as author and comment as description.
Thanks for you input!
Offline