Krs Joseph
Posts: 0
Joined: Wed Jul 24, 2013 6:15 pm

Photoswipe open directly full screen

Trying to make it possible that when I click an component I i taken into full screen gallery immediately and not to the image list here is the code i'm using

html: (i created a page with an html component and added this code to it)

<!-- <div data-role="page" id="index"
<div data-theme="b" data-role="header"
<h1Index page</h1
<

Code: Select all

         <div data-role="content" 
             <ul class="gallery"            
  <li<a href="[url=http://www.photoswipe.com/latest/examples/images/full/001.jpg]http://www.photoswipe.com/latest/exam...[/url]" rel="external"<[img]a href=[/img]</a</li 
                 <li<a href="[url=http://www.photoswipe.com/latest/examples/images/full/002.jpg]http://www.photoswipe.com/latest/exam...[/url]" rel="external"<[img]a href=[/img]</a</li 
                 <li<a href="[url=http://www.photoswipe.com/latest/examples/images/full/003.jpg]http://www.photoswipe.com/latest/exam...[/url]" rel="external"<[img]a href=[/img]</a</li 
                 <li<a href="[url=http://www.photoswipe.com/latest/examples/images/full/004.jpg]http://www.photoswipe.com/latest/exam...[/url]" rel="external"<[img]a href=[/img]</a</li 
                 <li<a href="[url=http://www.photoswipe.com/latest/examples/images/full/005.jpg]http://www.photoswipe.com/latest/exam...[/url]" rel="external"<[img]a href=[/img]</a</li 
                 <li<a href="[url=http://www.photoswipe.com/latest/examples/images/full/006.jpg]http://www.photoswipe.com/latest/exam...[/url]" rel="external"<[img]a href=[/img]</a</li 
                 <li<a href="[url=http://www.photoswipe.com/latest/examples/images/full/007.jpg]http://www.photoswipe.com/latest/exam...[/url]" rel="external"<[img]a href=[/img]</a</li 
                 <li<a href="[url=http://www.photoswipe.com/latest/examples/images/full/008.jpg]http://www.photoswipe.com/latest/exam...[/url]" rel="external"<[img]a href=[/img]</a</li 
                 <li<a href="[url=http://www.photoswipe.com/latest/examples/images/full/009.jpg]http://www.photoswipe.com/latest/exam...[/url]" rel="external"<[img]a href=[/img]</a</li 
             </ul 
         < 
     <    -- 

js: ( I selected the page named dralion_frontline and on load ran this javascript)

$(document).on('pagebeforeshow', '#index', function(){
var myPhotoSwipe = $(".gallery li a").photoSwipe({
jQueryMobile: true,
loop: false,
enableMouseWheel: false,
enableKeyboard: false
});

Code: Select all

 myPhotoSwipe.show(0);       

});

The page loads but doesn't work.... the images show up in a grid format and dont allow me to click on them or do anything... I want it to be able to go directly into fullscreen when I click on a component

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

Photoswipe open directly full screen

Hi,

In your HTML code there is a gallery in comments. The JavaScript code is incorrect.

Please follow our tutorial: http://docs.appery.io/tutorials/addin... It's working properly.

Krs Joseph
Posts: 0
Joined: Wed Jul 24, 2013 6:15 pm

Photoswipe open directly full screen

I put it in comments to stop it from showing up here, the javascript code in the tutorial doesn't allow me to go straight into a full screen image

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

Photoswipe open directly full screen

Could you please share the application with a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a?

Krs Joseph
Posts: 0
Joined: Wed Jul 24, 2013 6:15 pm

Photoswipe open directly full screen

Shared the name of the app is YUMA

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

Photoswipe open directly full screen

Hello! Please try the following code on page Load event:
prevar myPhotoSwipe = Appery("screenName")&#46;find("ul&#46;gallery a")&#46;photoSwipe({
jQueryMobile: true,
loop: false,
enableMouseWheel: false,
enableKeyboard: false
});
myPhotoSwipe&#46;show(0); /pre
also this post might help https://getsatisfaction.com/apperyio/...

Krs Joseph
Posts: 0
Joined: Wed Jul 24, 2013 6:15 pm

Photoswipe open directly full screen

Would I also be able to use local files vs calling a url?

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

Photoswipe open directly full screen

Sure, you can use local files.

Krs Joseph
Posts: 0
Joined: Wed Jul 24, 2013 6:15 pm

Photoswipe open directly full screen

how would I go about doing this?

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

Photoswipe open directly full screen

For example, if a file is on your memory card you can use "file://sdcard/XXXXX.jpg" to access it.

Return to “Issues”