[Koha-devel] opac logo image resize

Nicole Engard nicole.engard at liblime.com
Tue Aug 5 16:25:19 CEST 2008


In PHP there was a script that I could run to resize images on upload -
isn't there something similar for Perl that you could run on the image
you're using so that when you set it to the background it fits in the space
allotted?


---

Nicole C. Engard
Open Source Evangelist, LibLime
(888) Koha ILS (564-2457) ext. 714
nce at liblime.com
AIM/Y!/Skype: nengard

http://liblime.com
http://blogs.liblime.com/open-sesame/


On Tue, Aug 5, 2008 at 10:10 AM, Owen Leonard <oleonard at myacpl.org> wrote:

> > (owen) is there some style property to resize automatically the image ?
> > I've tried :
> >    <h1 id="libraryname" style="background-image: url('<!-- TMPL_VAR
> > NAME="opacsmallimage" -->');height:50px;">
>
> The logo is displayed using a CSS image replacement technique, so that
> the markup can be simply:
>
> <h1 id="libraryname">Koha</h1>
>
> ...and the image display can be controlled entirely by the stylesheet.
> I agree that this method has proved to be problematic: If you have
> access to the stylesheet, you can exert full control over the display,
> but if you rely on the opacsmallimage system pref, you must specify a
> logo with basically the same dimensions as the default.
>
> However, I can't see a simple solution. In the CSS for the whole blue
> search bar, the width of the logo corresponds to the offset of the
> search form next to it. If you change the width of the logo, you have
> to change the pixel offset. That means that unless you have a system
> pref with the logo dimensions, you can't embed the right size in the
> template.
>
> If you simply change the markup to:
>
> <h1 id="libraryname"><img src="library logo" /></h1>
>
> ...you get a layout that breaks unless your browser width is pretty wide.
>
> I realize that this limits the flexibility of the template with regard
> to custom logos, but the alternative is a design which is much less
> "stable" for users. And of course I'm willing to change the design if
> we can come up with a solution that meets all our requirements. This
> is what I came up with, and I'd love to hear suggestions.
>
>  -- Owen
>
> --
> Web Developer
> Athens County Public Libraries
> http://www.myacpl.org
> _______________________________________________
> Koha-devel mailing list
> Koha-devel at lists.koha.org
> http://lists.koha.org/mailman/listinfo/koha-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/koha-devel/attachments/20080805/b6e64e09/attachment-0003.htm>


More information about the Koha-devel mailing list