Skip to content

porcelanosa/yii2-magnific-popup

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

yii2-magnific-popup

Widget is under development

This widget is wrapper for awesome jQuery plugin Magnific Popup By Dmitry Semenov http://dimsemenov.com/plugins/magnific-popup/

Magnific Popup is a responsive lightbox & dialog script with focus on performance and providing best experience for user with any device (for jQuery or Zepto.js).

Installing

composer require porcelanosa/yii2-magnific-popup "master-dev"

Simple usage

in view file

	<a href="original.jpg" title="Caption text"><img  src="/thumb_img.jpg" alt="Alt"></a>
use porcelanosa\magnificPopup\MagnificPopup;

echo MagnificPopup::widget(
	[
		'target' => '#mpup',
		'options' => [
			'delegate'=> 'a',
		]
	]
);

for gallery

<div class="col-md-6" id="mpup">
	<a href="original.jpg" title="Caption for first"><img  src="/thumb_img.jpg" alt="Alt"></a>
	<a href="original2.jpg" title="Caption for second"><img  src="/thumb_img2.jpg" alt="Alt"></a>
</div>
echo MagnificPopup::widget(
	[
		'target' => '#mpup',
		'options' => [
			'delegate'=> 'a',
		],
		'effect' => 'with-zoom' //for zoom effect
	]
);

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 81.0%
  • CSS 13.5%
  • PHP 5.5%