Hello
I really like Boxers and Swipers. But we face some really nasty issues. We face the same issues on a few different pages:
1) The default setting to “apply” isn’t set. It’s disabled. This used to be different a while ago. Default should be enabled.
2) The “Apply”-setting in posts and pages aren’t stored. It’s completely ignored.
3) All pages and posts are set to “boxersandswipers_exclude“=”1” now. We didn’t set this value. Many old pages haven’t been edited since years, but they include this “new” added setting too.
4) If I manually set the “boxersandswipers_exclude“-value to “0” with the “custom fields”-plugin, Boxers and Swipers works as it should. But on next saving of the page/post, the “boxersandswipers_exclude“-value is set to “1” again. Really cumbersome!
What could cause this issues?
Any idea, how to fix this issue?
How to batch set all pages to “boxersandswipers_exclude“=”0” ?
How to set “boxersandswipers_exclude“=”0” as the default for all post-types?
How to make the “Apply”-setting in posts and pages working again?
I am having a strange problem with photoswipe whereby the caption for the first image I click on does not load — the others are all there. If I click on a different image, that caption will not load, but all the others (including the one that didn’t previously) will load. I’m tearing my hair out trying to fix it. Any help appreciated!
]]>I enabled debug.log in my WordPress installation, and I get a lot (about a hundred a day) of these lines in there:
PHP Notice: Undefined index: HTTP_USER_AGENT in /**myserverpath**/public_html/wp-content/plugins/boxers-and-swipers/lib/BoxersAndSwipers.php on line 334
This is wrong right? Shouldn’t you check with ‘isset’?
]]>I have two galleries on the same page. I understand that having more than one gallery in a page to show up in one Photoswipe effect, stepping continuously, is a feature. But I want to disable that. Is that possible?
]]>jquery-migrate.min.js:2 JQMIGRATE: Migrate is installed, version 1.4.1
jquery.photoswipe.js:145 Uncaught TypeError: Cannot read property 'width' of null
at parseThumbnails (jquery.photoswipe.js:145)
at open (jquery.photoswipe.js:42)
at HTMLAnchorElement.<anonymous> (jquery.photoswipe.js:194)
at HTMLAnchorElement.dispatch (jquery.js:3)
at HTMLAnchorElement.r.handle (jquery.js:3)
parseThumbnails @ jquery.photoswipe.js:145
open @ jquery.photoswipe.js:42
(anonymous) @ jquery.photoswipe.js:194
dispatch @ jquery.js:3
r.handle @ jquery.js:3
Resource interpreted as Document but transferred with MIME type image/jpeg: "https://a4jp.com/wp-content/uploads/2011/06/IMGP0436b.jpg".
]]>
Hello.
There is some type of error in Photoswipe.
I can’t get Photoswipe working on a phone (iPhone) on a few websites.
The error is when I click on the photo. The error shows and goes away so fast that I almost can’t read the message.
Any help would be great.
This is a test page I’m trying to get Photoswipe on:
Hey!
This problem has been marked here before but I still do not seem to find a solution.
The title and description of the images do not show with PhotoSwipe. No titles and description for single images, no titles and description for gallery images.
Is there a solution for this problem?
I also tried @maxirider solution (which is now offered 11 months and 4 weeks ago) and it did not solve the problem.
The solution was offered here: https://www.ads-software.com/support/topic/photoswipe-not-showing-image-captions/#post-7029448
Once you activate this plugin, how do you setup a photoswipe gallery?
]]>Hello.
The JS still loads if I turn the page option off and press “Apply”.
ページの設定でOFFすると変わらないです。JSはOFF出来ません。
]]>I tried to combine/minify both the CSS and JS files of Photoswipe in W3 Total Cache plugin, but it caused Photoswipe to stop working.
So are the plugin’s CSS and JS unminifiable for some reason?
Also, if I combine/minify any of the pair of
/wp-includes/js/jquery/jquery.js
and
/wp-includes/js/jquery/jquery-migrate.min.js,
Photoswipe stops working as well.
Is it possible to cure this all?
]]>Please consider adding an option in Photoswipe to turn off image pop-up animation COMPLETELY.
I suspect that changing animation time to zero is not the same as turning animation off.
If I’m right, then an option to turn it off might be of use to improve performance. If i’m wrong in my suspicion then just tell me i’m wrong. =)
I have a phantom bug with Photoswipe. The bug happens rarely and seemingly unsystematically.
Sometimes when I close an image’s pop-up Photoswipe window, I find that all the links that were on the page behind the pop-up window are disabled. The links don’t react to hovering or clicking on them.
But if I scroll to an area of the page that wasn’t under the pop-up window, links work there!
This might be a bug of the theme, not of the plugin. I don’t know.
After recent updates, Photoswipe has started working a bit slower.
When I click on an image, the animation isn’t totally smooth. It has an uncomfortable “freeze” in the first milliseconds. Check the images here:
https://khorn.by/2016/10/05/licviny-1992/
Hey there,
if data-size is defined on a-tag you should not load the image because of performance reasons. It’s enough to use the informations from data-size.
For using data-size if available, just change following file:
/photoswipe/jquery.photoswipe.js
$target.each(function(){
if( $(this).is('a') ){
$(this).attr(uidkey,uid);
var imgSrc = $(this).attr('href');
if( ! ( imgSrc in images ) ){
var img = new Image();
img.src = imgSrc;
images[imgSrc] = null;
img.onload = function(){
images[imgSrc] = img;
};
img.onerror = function(){
images[imgSrc] = img;
}
}
++uid;
}
});
to
$target.each(function(){
if( $(this).is('a') ){
$(this).attr(uidkey,uid);
var imgSrc = $(this).attr('href');
if( ! ( imgSrc in images ) ){
if( $(this).attr('data-size') ) {
var size = $(this).attr('data-size').split('x');
images[imgSrc] = {
src: imgSrc,
width: size[0],
height: size[1]
};
} else {
var img = new Image();
img.src = imgSrc;
images[imgSrc] = null;
img.onload = function(){
images[imgSrc] = img;
};
img.onerror = function(){
images[imgSrc] = img;
}
}
}
++uid;
}
});
Best regards
]]>When i moved my site to https, changing all possible links from http to https, the Boxers & Swipers plugin seems to not have adapted to this change.
I use Photoswipe on images everywhere.
The insecure content analyzer (whynopadlock.com) shows that on pages with images there are “http” links to photoswipe:
https://*******/wp-content/plugins/boxers-and-swipers/photoswipe/photoswipe.css
Accordingly, the browser either disables the plugin and images fall back to default WordPress behaviour, or the reader can disable the SSL to watch images with Photoswipe.
I tried to delete and reinstall the plugin – nothing changed.
]]>Hi there,
I have 2 problem:
1) PhotoSwipe captions/titles not working in the gallery, work only in a single image.
2) In the share, how I can remove the download button?
Thank you
]]>Hi there,
I have installed Boxers and Swipers with PhotoSwipe gallery and I have a problem with “Stay-On-Top” Main Menu of my website because it cover the top of the buttons of PhotoSwipe. How it’s possible to fix this problem without to disable “Stay-On-Top” of my website?
All the best
PhotoSwipe captions/titles not working
The captions and title work on PhotoSwipe website.
Can you please update PhotoSwipe?
大丈夫だったら、PhotoSwipeアップデートしてもいいですか?タイトルが表示しないです。
PhotoSwipeのウェブサイトに表示します。
]]>PhotoSwipe has been working well until recently… photos clicked go to the full size image, rather than open the lightbox.
Swipebox and others work just fine.
Any idea why Photoswipe would be acting up?
]]>Привет.
Плагин создаёт большую нагрузку: делает много запросов в базу данных и съедает ОЗУ.
Для сайта, у которого немного вложений, это не критично. Но если на сайте очень много вложений, как например на моём сайте, то это становится проблемой.
В файле boxersandswipers.php есть запрос:
$boxersandswipers->attachments = $wpdb->get_results(
“
SELECT post_title, ID
FROM $wpdb->posts
WHERE post_type = ‘attachment’
AND post_mime_type = ‘image/jpeg’
OR post_mime_type = ‘image/gif’
OR post_mime_type = ‘image/png’
OR post_mime_type = ‘image/bmp’
OR post_mime_type = ‘image/tiff’
OR post_mime_type = ‘image/x-icon’
“
);
Этот запрос берёт ВСЕ вложения, которые есть в БД.
А, например, у меня их больше 12000 уже.
Далее в файле inc/BoxersAndSwipers.php в функции add_anchor_tag_content
происходит перебор массива, в котором для каждого из вложений поста ищется title, сравнивая ссылки, найденные в посте, и ссылки ВСЕХ вложений в БД.
Кроме того, используется функция get_post_meta, которая также обращается к БД.
Это всё создаёт огромную нагрузку на БД и расходует память.
Я считаю, что такой подход не совсем правильный. В большинстве блогов используются вложения для конкретного поста. И очень редко, если одно вложение используется в нескольких постах.
Поэтому я сделал так.
В функции add_anchor_tag_content сразу после строки с условием:
if(preg_match_all(“/\s+href\s*=\s*([\”\’]?)([^\s\”\’>]+)(\\1)/ims”, $link, $result) !== false){
вставляю код:
global $post;
$attachments = get_children(
array(
‘post_parent’ => $post->ID,
‘post_type’ => ‘attachment’,
‘post_status’ => ‘any’,
‘post_mime_type’ => ‘image’
)
);
а также меняю все “$this->attachments” на “$attachments” в той же функции.
Всё. Теперь запрашиваться будут только вложения конкретного одного поста, причём один раз. И затем буду сравниваться ссылки и записываться title.
После этого количество запросов к БД и расход памяти уменьшаются в разы.
До этого было (загрузка поста):
запросов: > 1500
память: > 60 МБ
время: > 20 с + время вывода на экран
В общей сложности сайт грузился больше 1 минуты.
После оптимизации стало (загрузка поста):
запросов: ~ 45-50
память: ~ 100-400 кБ
время: ~ 0,001-0,04 с + время вывода на экран
В общей сложности сайт грузится примерно 1-3 секунды.
Может быть автор проведёт оптимизацию запросов, и подкорректирует плагин в следующем обновлении.
Версия плагина: 2.33
]]>Is there a shortcode for boxers and swipers to open the gallery from a text link instead of from an image thumbnail?
]]>Image captions do not appear when using PhotoSwipe or Swipebox.
They work fine with all of the other lightboxes.
I’m using B&S ver-2.3.1
How to fix?
]]>Hello, I see the photoswipe code twice in my headers and I also notice that each page is preloading all of the linked images on initial load. I looked briefly at the plugin and it appears set to [1,1] but I’m not sure it is and if it is it’s not working. I’m going to try to insert the preload into the double string of code below, however it would be nice to have it work properly or have an option to set it.
<!-- BEGIN: Boxers and Swipers -->
<script type="text/javascript">
jQuery(function() {
jQuery(".boxersandswipers").photoSwipe({
bgOpacity: 1,captionArea: true,shareButton: true,fullScreenButton: true,zoomButton: true,preloaderButton: true,tapToClose: false,tapToToggleControls: true,animationDuration: 333,maxSpreadZoom: 2,history: true
});
jQuery(".boxersandswipers").live('click', function(e){
e.preventDefault();
jQuery(".boxersandswipers").photoSwipe({
bgOpacity: 1,captionArea: true,shareButton: true,fullScreenButton: true,zoomButton: true,preloaderButton: true,tapToClose: false,tapToToggleControls: true,animationDuration: 333,maxSpreadZoom: 2,history: true
});
});
});
</script>
]]>
Your plugin makes it almost impossible to override gallery shortcode in functions.php.
Can it be make in some similar way as Jetpack Carousel, so it not influence gallery shortcode output so much ?
]]>Hello,
Can it be used to show HTML (images+text) in a box ?
Thank you
]]>Hi,
I cant get this plugin to work together with JetPack Tiled Galleries. Can you confirm that it works?
]]>I set up an opaque white style to the background but it ends up being transparent. I remove the cache. Save options and save slides. Doesn’t take the updates – still transparent buttons. I moved the slider over to the right to achieve 100% opaqueness. test.doctorryan.org home page.
]]>Hey! Cool plugin! Like it very much! But, your version of PHOTOSWIPE is a little old style (((
Please update it. I mean like this style It’s version 4 and it’s looks just soooo cool! I hope you will update your great plugin!
Dear impressive lightbox plugin maker! Is there a chance to add preloading images function (or code update) to Nivo Lightbox. Nivo Lightbox is the best looking plugin five of them but it does not preload next photo so photos loading very slowly. I definitely need this code. Thanks.
]]>Does that plugin also resizes the post image??
I don’t see such option and my images are too big.
I expected to this plugin to put thumbnails on post and show big/better image when you click it.
Regards.
]]>