I would like to adjust a portolio behaviour that instead of it directing the user to a new page when clicked it should pop up an image using the Pretty photo Lightbox libraries https://www.no-margin-for-errors.com/projects/prettyphoto-jquery-lightbox-clone/documentation/..
After analysing the code i realised it does the page rendering by calling a set of array parameters. I then checked another page on another website here: https://ambient.elated-themes.com/portfolio-item/inspiration-2/
and this was the behaviour i wanted.
Here is a code snippet of the arrays from my website
if ($query_results->have_posts()):
while ($query_results->have_posts()) : $query_results->the_post();
$params[‘current_id’] = get_the_ID();
$params[‘article_classes’] = $this->getArticleClasses($params);
$params[‘thumb_size’] = $this->getImageSize($params);
$params[‘text_holder_styles’] = $this->getTextHolderStyles($params);
$params[‘shader_styles’] = $this->getShaderStyles($params);
$params[‘text_inner_styles’] = $this->getTextInnerStyles($params);
$params[‘title_styles’] = $this->getTitleStyles($params);
$params[‘excerpt_styles’] = $this->getExcerptStyles($params);
$params[‘categories’] = $this->getItemCategories($params);
$params[‘switch_featured_image’] = $this->getSwitchFeaturedImage($params);
$params[‘category_html’] = $this->getItemCategoriesHtml($params);
/* $params[‘item_link’] = $this->getItemLink($params);*/
NB: The commented out code is where the click in the gallery redirects you to another site, since after commenting out it stopped working.
Below is the code snippet of the image class from the working website above i want to use. How do i integrate this functionality?
<?php if(!empty($lightbox)) : ?>
” data-rel=”prettyPhoto[single_pretty_photo]” href=”<?php echo esc_url($media[‘image_url’]); ?>”>
<?php endif; ?>
” alt=”<?php echo esc_attr($media[‘description’]); ?>” />
<?php if(!empty($lightbox)) : ?>
<?php endif; ?>
Some ideas will do.
]]>warnings from this plugin using a paid version. Status on Wordfence is concerning as it has not been updated in over 2 years. Is this plug-in abandoned?
]]>On https secured WP site, the following two links that throw http non-secure warning.
@import url(https://fonts.googleapis.com/css?family=Autour+One|Meie+Script|Armata|Rum+Raisin|Sonsie+One|Kavoon|Denk+One|Gravitas+One|Racing+Sans+One|Nosifer|Ropa+Sans|Offside|Titan+One|Paytone+One|Audiowide|Righteous|Faster+One|Russo+One|Germania+One|Krona+One|Emblema+One|Creepster|Delius+Unicase|Wallpoet|Sansita+One|Monoton|Kenia|Monofett);
<link rel=’stylesheet’ id=’rt-wpp-plugin-style-css’ href=’https://example.com/wp-content/plugins/rt-prettyphoto/css/prettyPhoto.css’ type=’text/css’ media=’all’ />
[Moderator note: code fixed. Please wrap code in the backtick character or use the code button.]
]]>I’m having two issues actually, the first is what whenever I try to use <div id=”complexgallery”> and create a gallery with a youtube video and images, if I have the video as the first item in the gallery, the rest of the images don’t show, and if I have it anywhere other than the first item, the video just won’t appear in the gallery.
The second issue I’m having is the gallery is all 1, even if I name separate galleries differently in the rel tag.
]]>Does this work with WooCommerce?
If so, how can I get WooCommerce to use this product instead of it’s own PrettyPhoto?
Currently Woo’s PrettyPhoto does not post the Meta ‘Title’ tag. Only the ‘Alt text’ and ‘Caption’.
]]>I like this plugin because of things keeping it so simple. Only concern I have is the way lightbox is displayed in mobile. I came with small thumbnail, can I change this to show as full screen instead of lightbox and also swipe enabled, that will help for the touch screens.
]]>Works great except the YouTube controls say the “Full Screen” mode is unavailable. How can I enable full screen when using this plugin? Thanks!
]]>Hello,
I’m looking to be able to share images via social share from the lightbox if possible, instead of the ability for someone to share a whole page.
Plus the like facebook button don’t show in the facebook timeline.
Any help would be really appreciated.
]]>Hello,
I’m using ACF plugin to display a gallery.
The PrettyPhoto does not work with ACF field.
Any idea how to make it work?
Cheers.
I have been working on a new install using Royal Pretty Photo to display videos in an overlay. I have used the same combination of plugins and theme components, but today I noticed that this install does not behave correctly, and I have one other recently updated site that is also now broken after the updates. I am using the DIVI theme.
this site has both divi and royal pretty photo and it has not been updated recently. it still works. click the “watch trailer” link: https://america1979.com/
this site also still works correctly: https://offlinersmovie.com/
but this site has been recently updated and it does not work, when you click the watch trailer link you will see what I mean, it loads below the footer.
https://saturnsavedme.com/
I am working on a new site, and have barely gotten started, and have this same problem, where the video is loading below the footer…
Anyone else having the same issue? How to fix?
]]>I have debug enabled via FUNCTIONS.PHP.
Your plug-in enabled I get this error:
Notice: wp_enqueue_script was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks.
Your plug-in disabled I get no errors.
]]>Hi
I would like to disable completely the Expand Button
It looks like a button to “close” the lightbox image, but intuitively, folks click it, hoping to go back to normal view, but instead, go another level deeper
And, in the Settings, it says you can control the Expand Button, but there is no checkbox
I love the plugin overall, just hoping to find a way to disable the expand button
https://www.ignitionmetalartdesign.com
Thanks
Marty
]]>Dear support team of Royal Pretty Photo. Recently I have discovered that, when you click on a post image for the first time it opens Royal Pretty Photo normal. BUT, if you exit with the X and then open it again, the layout from the Royal Pretty Photo is completely destroyed.
Some technical details:
– Problem occurs on any page, or post type
– When clicking on any image, I see the URL of that page, changes to eg. #prettyPhoto[856]/2/
– When exiting the prettyphoto show, the URL changed back to #prettyPhoto and not to the original post URL.
– After that, it’s completely ruined.
when i change the PIC,the pre and next button does’t work.
]]>Hi,
I have used and enjoy your plugin’s clean, dependable functionality in many sites built for my clients. In a recent site it’s just not working for WP galleries is it normally would:
https://instant-snow.com/our-products/
So far, I am at a loss to discern why.
The only unique thing I do see, is this:
When I do a normal view-source on a gallery page, I can clearly see the rel=”prettyPhoto[xxx]” added to each gallery item.
BUT — when I inspect the gallery line items in FireBug — they are not there.
I’ve never seen this happen before.
The site is pretty basic — built as a child of ElegantThemes.com Evolution Theme.
Any idea what could be causing this oddity in behavior, and ultimate failure of gallery images to load in prettyPhoto as expected?
Thank You,
XIMMBALO
]]>I inserted a gallery like this
[gallery ids="1468,1469,1470"]
when I click on the thumbnails, it opens the media page, not prettyPhoto
]]>Hello,
I use your plugin but have got a very strong urge for using this feature (my users ask for that).
Could you explain me how to enable “Save image/picture as” menu option?
Thanks in advance!
Piotr
]]>Notice: wp_enqueue_script was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. Please see Debugging in WordPress for more information. (This message was added in version 3.3.) in /wp-includes/functions.php on line 3245
Notice: wp_enqueue_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. Please see Debugging in WordPress for more information. (This message was added in version 3.3.) in /wp-includes/functions.php on line 3245
]]>Hello. I really enyoing that plugin- enought options which I need. But there is a bag, which cross all that advantages
here it is
one more example
Is it possible to fix it?
]]>How to you keep from the plugin automatically adding the Page ID to rel=”prettyPhoto”?
I have several images on a page with the rel=”prettyPhoto” tag which are independent of each other. Yet, when clicked, the enlarged image will allow you to view every photo on the page in the slide show — I do not wish this to be.
I have attempted to add [gallery-1], [gallery-2]… and so on to each individual photo, but prettyPhoto removes those efforts and replaces it with the page ID instead.
Please note that these images are being linked to files in a folder on the drive, not to images uploaded via the Media Importer. — I have done it this way b/c there is no good solution for managing photo groups (as in folders) in the WP Media Manager.
Any thoughts?
Thanks
]]>How do you change the theme from default to dark_square, dark_rounded or any other themes?
]]>It works on any image in a post, but cannot get it to work with the Featured image in a post
]]>Hello
I’m not able to close a iframe window using
parent.eval('$.prettyPhoto.close()');
any help will be welcomed
regards
curdaneta
Hello – Your plugin works great. However, it does now show social icons.
In setting panel the wording says “Hide social icons” and box is not checked. any advice?
Hello
I use a theme called Zwin. I have tried several lightbox plugins, but none of them works. It is as if the themes lighbox overrules. Can you helt me to get your plugin to work.
Watch the standard on the portfolio site at mikkeljuhl.dk
]]>Hi.
Thanks for the great plugin.
A small annoying bug.
When trying it with WP_DEBUG enable the plugin throws an Notice: wp_enqueue_script was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or init hooks
in order to fix this juct move the ~47-55 lines of rt-prettyphoto.php
/* Adding plugin javascript active file */
wp_enqueue_script('rt-wpp-plugin-active', RT_WPP_PLUGIN_PATH . 'js/jquery.prettyPhoto.js', array('jquery'));
/* Adding plugin javascript active file */
wp_enqueue_script('rt-wpp-plugin-script-active', RT_WPP_PLUGIN_PATH . 'js/wpp-active.js', array('jquery'));
/* Adding Plugin custm CSS file */
wp_enqueue_style('rt-wpp-plugin-style', RT_WPP_PLUGIN_PATH . 'css/prettyPhoto.css');
inside the function rt_wpp_latest_jquery().
Actually from this function you should delete the
wp_enqueue_script('jquery');
, cause you don’t need to do this.
Bests Lena
]]>Hello,
my theme is using already TWO Google Fonts and they are not in the listing of the options. Could you add an option “default font” ?
Hi.
I noticed that in prettyPhoto.css something is using as background the url(../images/prettyPhoto/light_rounded/btnNext.png), which doesn’t exists and throwns an error on log files.
There are about 5 elements with this image as background. Can you please locate which should I change?
Thanks in advance
Lena
Thanks for the great plugin.
You can also use it for Buddypress activity by simply adding the following in your custom.php file
add_filter('bp_get_activity_content_body', 'royal_prettyphoto_replaceBuddypress');
function royal_prettyphoto_replaceBuddypress($content) {
$pattern = "/<a(.*?)href=('|\")([^>]*).(bmp|gif|jpeg|jpg|png)('|\")(.*?)>(.*?)<\/a>/i";
$replacement = '<a$1href=$2$3.$4$5 rel="prettyPhoto[' . bp_get_activity_id() . ']"$6>$7</a>';
$content = preg_replace($pattern, $replacement, $content);
return $content;
}
Bests Lena
]]>For this plugin, has no content for this plugin.
]]>