Image Gallery Pluign
Image Gallery is plugin to display images based on prettyPhoto javascript library.
How to Use
Create a Region, choose Type "Image Gallery[Plug-In]" and in Region source enter following code:
select 'f?p=&APP_ID.:0:&APP_SESSION.:APPLICATION_PROCESS=GETFILE:::FILE_ID:'||
your_image_id SHOW_IMAGE,
your_image_name FILENAME,
your_image_id IMAGE_ID,
APEX_UTIL.PREPARE_URL(
p_url => 'f?p=' ||:APP_ID || ':4:'||:APP_SESSION||'::NO::P4_ID:'||your_image_id,
p_checksum_type => 'SESSION') IMAGE_URL
from your_table
Create Application Process onDemand GETFILE with following code:
begin
for c1 in (select *
from your_table
where id = :FILE_ID) loop
--
sys.htp.init;
sys.owa_util.mime_header( c1.mime_type, FALSE );
sys.htp.p('Content-length: ' || sys.dbms_lob.getlength( c1.content));
sys.htp.p('Content-Disposition: attachment; filename="' || c1.filename || '"' );
sys.htp.p('Cache-Control: max-age=3600'); -- tell the browser to cache for one hour, adjust as necessary
sys.owa_util.http_header_close;
sys.wpg_docload.download_file( c1.content );
apex_application.stop_apex_engine;
end loop;
end;
Create Application Item FILE_ID where we store ID of image
Options
1. Style
you can choose different style of prettyPhoto image Gallery
2. Autoplay slideshow
with or without auto slideshow
3. Animation speed
4. Slideshow
Duration of slideshow in miliseconds
5.Link icon Icon for random link
How to get it
Visit apex.world plug-in page
hi,
ReplyDeleteApplication Process onDemand which option Process Point:
on demand,on submit, ajax callback ?
ajax callback
DeleteHello,
ReplyDeleteI'm using Apex 5.1.4, but when I import the plugin it returns an error: "NOT COMPATIBLE (Your export may contain calls not supported by your application version.)".
meanwhile; in the read me file it tells this plugin compatible from '5.0' to '18.1'
So, please help what is the problem here?
Hello
DeleteI have exported this plugin from apex 18.1
I will update plugin on github in next release
Hello,
ReplyDeleteI'm using Apex 5.1.4, but when I import the plugin it returns an error: "NOT COMPATIBLE (Your export may contain calls not supported by your application version.)".
meanwhile; in the read me file it tells this plugin compatible from '5.0' to '18.1'
So, please help what is the problem here?
Hello
DeleteI have exported this plugin from apex 18.1
I will update plugin on github in next release
Thank you very much for your input. I liked your gallery of images.
ReplyDeleteWhen importing your plugging gives me an error of: NOT COMPATIBLE.
Version of the database: 12.1.0.2
APEX version: 5.1.1
Hello
DeleteI have exported this plugin from apex 18.1
I will update plugin on github in next release
Hai Thank you so much. Like your gallery of images.
ReplyDeleteFound that you demo pages, first click on image able to select edit or view. Is it the features not in plug-in? Wish to know how to do it.
Hi,
ReplyDeletethank you for useing it. That is plugin feature. To have this feature you need in your select statment add column with link to your edit page like this:
APEX_UTIL.PREPARE_URL(
p_url => 'f?p=' ||:APP_ID || ':4:'||:APP_SESSION||'::NO::P4_ID:'||your_image_id,
p_checksum_type => 'SESSION') IMAGE_URL
The column alias must be IMAGE_URL.
I hope it will help you.
Nihad
This comment has been removed by the author.
ReplyDeleteDear thank you,
ReplyDeletecan you please explain
your_image_id,
what do you mean by image_id
i need carousel region that fetch images from database ... can you help me with that please
ReplyDeleteWhen i get free time i will look into this..
DeleteHello! i love this plugin, it works perfectly in non-public pages, but when I change the page to publish it stops showing the images, I already change the application process to Public and it does not work, do you know why it could be?
ReplyDeleteHello! I solved it alone, but if it's useful to someone, the page 10 is the page of the gallery and it have to be public, the link should point to the page 10, not 0, like this example
Deleteselect 'f?p=&APP_ID.:10:&APP_SESSION.:APPLICATION_PROCESS=GETFILE:::FILE_ID:'||id SHOW_IMAGE,
name FILENAME,
id IMAGE_ID,
null IMAGE_URL
from sbinfo.images
This comment has been removed by the author.
ReplyDeletehow do i get the image_URL
ReplyDeleteHello,
DeleteYou need at first to create application Process 'GETFILE' with following code
begin
for c1 in (select *
from your_table
where id = :FILE_ID) loop
--
sys.htp.init;
sys.owa_util.mime_header( c1.mime_type, FALSE );
sys.htp.p('Content-length: ' || sys.dbms_lob.getlength( c1.content));
sys.htp.p('Content-Disposition: attachment; filename="' || c1.filename || '"' );
sys.htp.p('Cache-Control: max-age=3600'); -- tell the browser to cache for one hour, adjust as necessary
sys.owa_util.http_header_close;
sys.wpg_docload.download_file( c1.content );
apex_application.stop_apex_engine;
end loop;
end;
and then in select list you put for image_URL folowing code
'f?p=&APP_ID.:0:&APP_SESSION.:APPLICATION_PROCESS=GETFILE:::FILE_ID:'||image_id
image id is id of your image in table
if you have more question feel free to ask.
Regards,
Nihad
Hi Nihad! You did a great job with this plugin! Awesome! I've a question. Is possible implement a refresh for the gallery? I've a button that open a form to add a new image. This works fine, the image is stored in DB, but after this I can't refresh the gallery. I tried with a dynamic action
ReplyDeleteHi Nihad! you did a great job, but the image is not displaying for me the empty page is displying for me, there is a error in console. So please help me
ReplyDeleteApplication Process
begin
for c1 in (select *
from tst
where IDNUMBER = :FILE_ID) loop
sys.htp.init;
sys.owa_util.mime_header( c1.MIMETYPE, FALSE );
sys.htp.p('Content-length: ' || sys.dbms_lob.getlength( c1.PRGIMAGE));
sys.htp.p('Content-Disposition: attachment; filename="' || c1.PROGNAME || '"' );
sys.htp.p('Cache-Control: no-cache');
sys.owa_util.http_header_close;
sys.wpg_docload.download_file( c1.PRGIMAGE );
apex_application.stop_apex_engine;
end loop;
end;
----------------------------------
Select Query
select 'f?p=&APP_ID.:0:&APP_SESSION.:APPLICATION_PROCESS=GETFILE:::FILE_ID:'||IDNUMBER SHOW_IMAGE,
PROGNAME FILENAME,
IDNUMBER IMAGE_ID,
null IMAGE_URL
from test
-------------------
I created FILE_ID in application items
--------------------
Please tell me what's my mistake
---------------------
The table name is also tst in select query, I mistakenly typed test, SO the table name is tst only
ReplyDeletePls anybody help me, I need this plugin urgently
ReplyDeleteHi Edward,
Deletecan you pleas contact me on nhasko@gmail.com, i will try to help you.
Kind Regards,
Nihad
Hi nhasko,
ReplyDeleteI mailed you. please help me, I need this plugin urgenly.
Hi Edward, please check your email.
DeleteThanks for your Swift reply. I mailed you the table structure. Please check it.
ReplyDeleteHey Nihad,
ReplyDeleteThanks for your timely help! Your blog has been a great help to me always. Its so humble of you, how you respond immediately to those in need of your help.
Will definetly contact you in the future in case of any help.
Way to go buddy!
Thanks & Regards,
Edward Log.