zpBase: Images on retina display in low resolution

walterbz Member
edited October 2017 in Themes

Hi
I'm using printDefaultSizedImage to display images on my site.
On desktop the image show correctly, 1200 px resolution width.
On mobile (iPhone 7+) the image displays 400 px resolution width.
Can't find where to change or fix this.
Using theme zpBase.
Can someone help?
Thanks.
Walter

Comments

  • acrylian Administrator, Developer
    edited October 2017

    I added the theme name to your topic so it is more clear that this is theme specifc. I also moved the topic to the themes category.

    I am not familiar with this theme but I am not sure it supports retina images at all. I think it just use a smaller one for smaller screens. (For Zenphoto itself support for this is planned for the future). In any case look in the theme's image.php for changes.

  • walterbz Member
    edited October 2017

    thanks acrylian.
    I thought that the detection of the device, in order to scale the image, was done by the function itself not by the theme.

  • acrylian Administrator, Developer

    it might use the library of the mobileTheme plugin. But providing images for retina or non-retina is not yet implemented in Zenphoto itself. That must be some custom theme functionality.

  • thanks!!! in fact I found it
    if ($isMobile) {
    setOption('image_size',400,false);
    setOption('zpbase_galbigsize',400,false);
    if (getOption('zpbase_mobiletogrid')) {
    setOption('zpbase_defaultalbum','album-grid',false);
    setOption('zpbase_newsstyle','blog-style',false);
    setOption('zpbase_searchlayout','search-grid',false);
    }
    }

  • acrylian Administrator, Developer

    Great!

Sign In or Register to comment.