开发者

Scale image as background based upon user's machine screensize

开发者 https://www.devze.com 2023-03-05 07:20 出处:网络
I have a image (uploaded by user, cant say about the size of that). It will be used as background image for his page.

I have a image (uploaded by user, cant say about the size of that). It will be used as background image for his page. I just want to scale it to the full size of the screen. Some think like. On load find the screensize using Jquery/javascript and add that style to the background ima开发者_StackOverflow中文版ge.

PS:- There is no Y scroll on the page. And I am not concerned about the quality of the image on scaling if image size of too small.


Check out this jQuery plugin https://github.com/iamjpg/jQuery-Ez-Background-Resize

0

精彩评论

暂无评论...
验证码 换一张
取 消