Created
January 18, 2015 18:53
-
-
Save shahadat014/c5239a6b9ec3d0c25e6e to your computer and use it in GitHub Desktop.
Enable masonry in WordPress
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| add_action( 'wp_enqueue_scripts', 'jk_masonry' ); | |
| function jk_masonry() { | |
| wp_enqueue_script( 'jquery-masonry', array( 'jquery' ) ); | |
| } | |
| How to use? | |
| $('#container').masonry({ singleMode: true }); | |
| or | |
| $('#container').masonry({ columnWidth: 200 }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment