Skip to content

ericlbarnes/centerImg

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Center Image

This is a simple jQuery plugin to center an image outside of a container by using negative margin.

Usage

$('img.popout').centerImg({
  container: $(".content"), // The container element. Used in calculating width
  maxWidth: 600 // The max width of the image. Default is $("body").innerWidth()
});

About

Center an image outside of a container

Resources

License

Stars

2 stars

Watchers

2 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors