Friday, April 24, 2015

Fancybox with Cakephp

Hello,

I have been trying to work on fancybox with cakephp. All i need is to display a single image in fancybox when a user clicks a link.

Here is the code that i have been using.
$src3 = 'http://farm7.staticflickr.com/6099/6359411189_0ffbb4719f_b.jpg';    $this->Fancybox->setProperties( array(                        'class' => 'fancybox3',                       'className' => 'fancybox.image',                       'title'=>'Single Image',                       'rel' => 'gallery1'                         )              );  $this->Fancybox->setPreviewContent('Click to View Image');   $this->Fancybox->setMainContent($src3); // the content which will be shown in Fancybox  echo $this->Fancybox->output(); 
Iam using aplugin by github. https://github.com/destinydriven/CakePHP-Fancybox-Plugin

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cake-php+unsubscribe@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.

No comments: