• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

[Bug] Incorrect Navigaton Sequence in Site Builder Image Gallery

ccto

Basic Pleskian
Dear Parallels Support,

We have updated the Site Builder to 4.5 Hotfix 7 (i.e. the latest one).
However for the following item (fixed in hotfix 7) -
[Image Gallery] The issue with navigation in Image Gallery has been resolved: behavior of the Previous Image button has been corrected.
ref.: http://autoinstall.plesk.com/SiteBu.../sitebuilder-4.5.7_build2009060500_linux.html

--

We found that inside Image Gallery, the Next/Previous Image link Images are not in position sequence.

As reported, when we navigate the end-user website http://www.hkperpetual.com/allwatches.php?view=thumbnailList&category=1 , it is inside category=1, choose the first image (image=7), then choose next image (image become 13), then choose next image (image become 58), then choose next image (image become 60).

I tried to browse the sqlite database table module_xxxx_gallery_relations, and spooled the SQL

The following is the sqlite database table screen capture for your reference.
sb45_hotfix7_gallery_image_sequence_sqlite_screen.gif


If we browse the image with id=7 and position=1,
the next image should be the image with id=8 and position=2,
the next next image should be image with id=12 and position=4
am I right? I think so.

Then, I tried to turn on DEBUG flag and spool the SQL to have a look -


---------------- Start select -------------------
Open connection to sqlite database
Result: true
Execute time: 0.000590085983276

Try execute query...
Result: true
Execute time: 0.0001220703125
SELECT
*
FROM modules_3ilp1vgj0dj_category
WHERE
(modules_3ilp1vgj0dj_category.storage_state<3)
ORDER BY
position ASC


---------------- End select -------------------

---------------- Start select -------------------

Open connection to sqlite database
Result: true
Execute time: 2.59876251221E-5

Try execute query...
Result: true
Execute time: 0.000169038772583

SELECT
modules_3ilp1vgj0dj_gallery_images.id as id,
modules_3ilp1vgj0dj_gallery_images.title as title,
modules_3ilp1vgj0dj_gallery_images.image as image,
modules_3ilp1vgj0dj_gallery_images.description as description,
modules_3ilp1vgj0dj_gallery_relations.position as position,
category_id as category
FROM modules_3ilp1vgj0dj_gallery_images
LEFT JOIN modules_3ilp1vgj0dj_gallery_relations ON ( image_id = modules_3ilp1vgj0dj_gallery_images.id AND modules_3ilp1vgj0dj_gallery_relations.storage_state<3)
WHERE
(id = '7'
AND category_id = '1')
AND (modules_3ilp1vgj0dj_gallery_images.storage_state<3)


---------------- End select -------------------

---------------- Start select -------------------

Open connection to sqlite database
Result: true
Execute time: 1.81198120117E-5

Try execute query...
Result: true
Execute time: 0.000128984451294
SELECT
modules_3ilp1vgj0dj_gallery_images.id as id,
category_id as category
FROM modules_3ilp1vgj0dj_gallery_images
LEFT JOIN modules_3ilp1vgj0dj_gallery_relations ON ( image_id = modules_3ilp1vgj0dj_gallery_images.id AND modules_3ilp1vgj0dj_gallery_relations.storage_state<3)
WHERE
(modules_3ilp1vgj0dj_gallery_relations.position > '1'
AND category_id = '1')
AND (modules_3ilp1vgj0dj_gallery_images.storage_state<3)
LIMIT 0, 1

---------------- End select -------------------

---------------- Start select -------------------

Open connection to sqlite database
Result: true
Execute time: 1.81198120117E-5

Try execute query...
Result: true
Execute time: 0.00129580497742

SELECT
modules_3ilp1vgj0dj_gallery_images.id as id,
category_id as category
FROM modules_3ilp1vgj0dj_gallery_images
LEFT JOIN modules_3ilp1vgj0dj_gallery_relations ON ( image_id = modules_3ilp1vgj0dj_gallery_images.id AND modules_3ilp1vgj0dj_gallery_relations.storage_state<3)
WHERE
(modules_3ilp1vgj0dj_gallery_relations.position < '1'
AND category_id = '1')
AND (modules_3ilp1vgj0dj_gallery_images.storage_state<3)
ORDER BY
id DESC
LIMIT 0, 1

---------------- End select -------------------

---------------- Start select -------------------

Open connection to sqlite database
Result: true
Execute time: 2.50339508057E-5

Try execute query...
Result: true
Execute time: 0.000121116638184
SELECT
*
FROM modules_3ilp1vgj0dj_category
WHERE
(modules_3ilp1vgj0dj_category.storage_state<3)
ORDER BY
position ASC

---------------- End select -------------------

I believe the red-highlighted one are the SQL to get the next and previous Image Id.
However the use of "position > '1'" and "position < '1'" may not get the correct position in order.

If I execute the red-highlighted SQL in the SQLite database browser, it return image id 13 (that with position id 48), instead of image id 8 (that with position 2) as below -
SELECT
modules_3ilp1vgj0dj_gallery_images.id as id,
category_id as category
FROM modules_3ilp1vgj0dj_gallery_images
LEFT JOIN modules_3ilp1vgj0dj_gallery_relations ON ( image_id = modules_3ilp1vgj0dj_gallery_images.id AND modules_3ilp1vgj0dj_gallery_relations.storage_state<3)
WHERE
(modules_3ilp1vgj0dj_gallery_relations.position > '1'
AND category_id = '1')
AND (modules_3ilp1vgj0dj_gallery_images.storage_state<3)
LIMIT 0, 1
sb45_hotfix7_gallery_image_sequence_sqlite_screen_pt2.gif



May I suggest, say , add one more SQL to fetch the correct next/previous position id before you get the image id, e.g.
select * from modules_3ilp1vgj0dj_gallery_relations where category_id = '1' AND position > '1' ORDER BY position LIMIT 0,1

Then, the next and previous image are in sequence.

If necessary, we may pass you the sqlite database for you to have a look (if the end-user permits)

Please help and advise.

Thank you very much for your kind attention.

Regards
George
Website Solution Limited
http://www.website-solution.net/
 
Hello, after seven month there are non solutions at this problem?
Too I have the same problem.
Nobody's of Parallels Team's that have a solutions?

Diego.
 
Back
Top