1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

define the image size as% of js

Discussion in 'Styling and Customization Questions' started by time, Jun 3, 2013.

  1. time

    time Active Member

    Code:
    <script type="text/javascript">
        $(document).ready(function(){
        $('.block_img_1').resizecrop({
          width:372,
          height:200,
          vertical:"top"
        }); 
    $('.block_img_2').resizecrop({
          width:250,
          height:200,
          vertical:"top"
        }); 
    $('.block_img_3').resizecrop({
          width:203,
          height:200,
          vertical:"top"
        }); 
    $('.block_img_4').resizecrop({
          width:203,
          height:200,
          vertical:"top"
        }); 
    $('.block_img_5').resizecrop({
          width:203,
          height:200,
          vertical:"top"
        }); 
      }); 
    </script>
    
    js defines the image size in pixels, how can I define the image size in %

    Thanks
     
  2. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Where is that code from? What image are you trying to resize?
     
    time likes this.
  3. time

    time Active Member

    code from one blog
    I want to change the size to run on the mobile style.
     

    Attached Files:

  4. time

    time Active Member

    help me,
     
  5. Jeremy

    Jeremy XenForo Moderator Staff Member

    It's not supported by the jQuery plugin. If you want to change it, you can attempt to directly modify the source, but I'm not sure that will work 100% correctly.
     
    time likes this.
  6. time

    time Active Member

    Thanks King Kovifor

    You may guide me.
     

Share This Page