test
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • barre2011 Friend
    #172323

    I am using the JA_Purity II template, version 1.2.1 on Joomla 1.5.25
    My site http://www.bblopers.nl looks fine on a desktop computer, but on Iphone or other cell phone browser the images in articles are displayed too small, all images are cropped to a width of 199 or so pixels. Image height remains untouched.
    I disabled the iphone -special layout for Iphone by choosing the default template for Iphone but you can see the effect in every other cell phone browser.
    Disabling plugins, cache and changing img styles dit not make things better..
    Help would be greatly appreciated.
    Thank you very much and a good new year!

    barre2011 Friend
    #432080

    Yes. I did check that page. Please see the images on my site with a mobile browser to view the problem. The width of the images is always cropped to below 200px regardless of the height.

    barre2011 Friend
    #432375

    The problem lies in the javascript in /templates/ja_purity_ii/layouts/blocks/handheld/head.php
    This javascript seems to be the culprit:

    <blockquote><script type=”text/javascript”>
    //update image size
    function updateOrientation() {
    var maxwidth = 200;
    var orient = window.orientation
    if (orient == 90 || orient == -90) {
    bdcls = ‘landscape’;
    maxwidth = Math.round(480*40/100); //IPhone
    } else {
    bdcls = ‘portrait’;
    maxwidth = Math.round(screen.width*40/100);
    }
    document.body.className = bdcls;
    //update images width
    images = document.getElementsByTagName (‘img’);
    for(i=0;i<images.length;i++) {
    image = images;
    if (!image._orgwidth) {
    image._orgwidth = image.offsetWidth;
    }
    if (image._orgwidth > maxwidth) {
    image.width = maxwidth;
    } else if (image._orgwidth > image.offsetWidth) {
    image.width = image._orgwidth;
    }
    }
    }
    window.addEvent(‘domready’, function() {
    $(‘mod_search_searchword’).addEvents({
    ‘focus’:function(){
    $(‘handheld-nav’).setStyle (‘display’, ‘none’);
    $(‘ja-search’).setStyle (‘width’, ‘100%’);
    },
    ‘blur’:function() {
    $(‘handheld-nav’).setStyle (‘display’, ‘block’);
    $(‘ja-search’).setStyle (‘width’, ‘30%’);
    }
    });
    });
    </script></blockquote>

    Byj deleting this script, at least the part I indented (see above ) my images are OK now.
    I think it is a bug in the template.

    Anonymous Moderator
    #433366

    Barre2011 ,

    We checked and would like to confirm that this is one of our template features (Auto resize images for iphone layout), not bug. You can remove that script if you don’t want this feature.

    Thanks.

    barre2011 Friend
    #433450

    The problem is that onl;y the width of the pictures is adjusted, not the height, therefore the pictures look squeezed.

    regards
    barre2011

    Anonymous Moderator
    #433514

    <em>@barre2011 294151 wrote:</em><blockquote>The problem is that onl;y the width of the pictures is adjusted, not the height, therefore the pictures look squeezed.

    regards
    barre2011</blockquote>

    Barre2011,

    As our technical support service is only available for paid members only.

    Please go ahead to join us at http://www.joomlart.com/member/signup.php for getting help on this.

    Thanks.

Viewing 6 posts - 1 through 6 (of 6 total)

This topic contains 6 replies, has 2 voices, and was last updated by Anonymous 12 years, 10 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum