ThomBedford
Forum Replies Created
-
Issue resolved for me, thanks Roberto!
I have a paid version of this plugin, and have raised a support ticket with the team.
Also having this issue, updated from 8.0.4 to 8.0.5 an hour ago and the form no longer works, it goes to a blank screen and doesn’t add the subscriber.
Forum: Fixing WordPress
In reply to: Unknown Cause of Image RotationHi Steve,
Thanks for your help on this, after health check and testing with no plugins still showed the issue, I dug more in to the images themselves.
The EXIF orientation data in hidden in Windows 10 and Chrome, but is visible when opening the files in MS Edge or when editing the files in GIMP or some other image editing tool.
So the EXIF data strippers I used on the file didn’t strip the EXIF orientation, only all the other info (like location, camera type etc). So what I need to do to resolve this is find a way of removing the EXIF orientation from all my images then re-upload and re-optimise them all through WordPress.
In other words, not a WordPress issue, but a Win10 and Chrome “feature”.
Regards,
ThomForum: Fixing WordPress
In reply to: Unknown Cause of Image RotationHi Steve,
Thanks for the advice, currently taking a backup of my blog, and will then try the health check followed by disabling everything and enabling piece-by-piece.
Everything else on the blog works fine, and I can install plugins etc fine, it’s just these few portrait images that are rotating. Will run the health checks and see if anything comes of it and will update accordingly.
Hi thanks, glad I could inspire you. I wrote an article about it here.
Resolved my latest issue, I needed to change the code in the lightbox php file as well as the search mechanisms were duplicated. So in the BWGModelGalleryBox.php file in the frontend/models directory there’s a similar search string to my previous comment (which is for some reason held for moderation).
Before:
if ($filter_search_name != '') { $where = ' AND (image.alt LIKE "%%' . $filter_search_name . '%%" OR image.description LIKE "%%' . $filter_search_name . '%%")'; }After
if ($filter_search_name != '') { $where = ' AND (('; $filter_search_name_array = explode(' ', $filter_search_name); foreach($filter_search_name_array as $filter_search_name_1){ $where .='image.alt LIKE "%%' . $filter_search_name_1 . '%%" AND '; } $where = substr($where, 0, -4) . ') OR ('; foreach($filter_search_name_array as $filter_search_name_2){ $where .='image.description LIKE "%%' . $filter_search_name_2 . '%%" AND '; } $where = substr($where, 0, -4) . '))'; }I’ve made pretty much the exact same change here that I made in the other file and it fixed the issue, just changed the variable names slightly.
Not sure why my last post has been held for moderation, still looking for help on this issue.
Hi,
I’ve coded the change to the search, however when clicking an image I get the error “The image has been deleted.” in the lightbox even though the links are all correct. Here’s the change I made:
In the framework/WDGLibrary.php file, the function get_image_rows_data, there is a WHERE clause to add search items if they exist:
if ( $bwg_search ) { $where = 'AND (image.alt LIKE "%%' . $bwg_search . '%%" OR image.description LIKE "%%' . $bwg_search . '%%")'; }Change the contents of this if-statement to the following:
if ( $bwg_search ) { $where = 'AND (('; $bwg_search_array = explode(' ', $bwg_search); foreach($bwg_search_array as $bwg_search){ $where .='image.alt LIKE "%%' . $bwg_search . '%%" AND '; } $where = substr($where, 0, -4) . ') OR ('; foreach($bwg_search_array as $bwg_search){ $where .='image.description LIKE "%%' . $bwg_search . '%%" AND '; } $where = substr($where, 0, -4) . '))'; }This will create an array based on a space-separated search string, then loop through that array and add on an extra where clause on to the end of the where string.
Now I need to figure out how to resolve the “The image has been deleted.” issue…
- This reply was modified 8 years, 3 months ago by ThomBedford.
- This reply was modified 8 years, 3 months ago by ThomBedford.
Hi, this change didn’t work, I believe the code is in the WDWLibrary.php file not the js file, and seems more involved than I first thought.
Can I get some help on this please?
Hi,
I think by changing the default.js code from:
jQuery("#search_by_name .search_by_name").on("input keyup", function() { var search_by_name = jQuery(this).val().toLowerCase(); if (search_by_name) { jQuery("#explorer_body .explorer_item").hide(); jQuery("#explorer_body .explorer_item").each(function () { var filename = jQuery(this).attr("filename").toLowerCase(); if (filename.indexOf(search_by_name) != -1) { jQuery(this).show(); } }); } else { jQuery("#explorer_body .explorer_item").show(); } });To something like this:
jQuery("#search_by_name .search_by_name").on("input keyup", function() { var search_by_name = jQuery(this).val().toLowerCase(); if (search_by_name) { jQuery("#explorer_body .explorer_item").hide(); jQuery("#explorer_body .explorer_item").each(function () { var filename = jQuery(this).attr("filename").toLowerCase(); if (filename.match("/("+search_by_name.replace(" ","|")+")/")) { jQuery(this).show(); } }); } else { jQuery("#explorer_body .explorer_item").show(); } });This may fix the problem, it simply changes the indexOf call to a match call and alters the string slightly to fit the method.
Can you confirm if this would work?
Thanks,
ThomForum: Plugins
In reply to: Jetpack E-Mail Share Not WorkingCan anyone help with this please?