[pmwiki-users] Galleria

Petko Yotov 5ko at 5ko.fr
Fri Jun 10 19:52:15 CDT 2011


On Saturday 11 June 2011 02:09:47, DaveG wrote :
> On 6/10/2011 4:18 PM, Petko Yotov wrote:
> > Browsers should display the alt text when the image cannot be displayed,
> > and the title text in a tooltip box/bubble when the mouse cursor is
> > positioned over the image. (In the past, Internet Explorer used the alt
> > text for both, but this behavior is not standard.)
> 
> Agreed, but is there no reason why the two *have* to be the same. 

They don't "have" to, but when we convert from simplified wiki-markup to HTML, 
what PmWiki does is simple, quick and probably most convenient for most people 
in most cases.


> Is there a way to provide different text for the ALT and TITLE?

Not with the default PmWiki installation.

Looking at your demo page, the easiest fix for the double caption may be to 
just disable one of the attributes, by adding such a line to config.php:

  $ImgTagFmt = "<img src='\$LinkUrl' title='\$LinkAlt' />"; # no alt


Looking at the Galleria documentation, I see that it is possible to get the 
description from a text element after the image, eg. from the "| caption" part 
generated by PmWiki. The method is shown here:

  http://galleria.aino.se/docs/1.2/references/data/#using-html-with-dataconfig

The example will not work in PmWiki without some tweaking, but it shouldn't be 
hard.

Petko



More information about the pmwiki-users mailing list