gridContainer and anchors

7 replies · opened Apr 4, 2020

NnmitApr 4, 2020

I have a problem using html anchor (index.php#item1234).

It looks like the "gridContainer" in functions that's the problem. After the page is loaded it forces the page back to the top and overwrite my anchor.
If I turn this feature off, my grid won't work.

Any suggestions?

SSemicolon WebSTAFFApr 5, 2020

Hello,

The GridContainer Functionality does not interfere with the Hash Position of the Window in any way. Can you please provide us with a Live URL so that we can check out the exact issue and provide you with more assistance on this. Thanks for your Patience.

Meanwhile, do let us know if we can help you with anything else or if you find any further issues with Canvas.

NnmitApr 6, 2020

Sending link private because the site is not public yet

NnmitApr 6, 2020

The site is stil in beta and on local server - but here's a link I just uploaded to my webhost: https://mmbr.dk/_canvas_support/produkter.php?id=rom#rom04513

It's a shop, where when ordered you should return to same place on site.

In Chrome it jumps to top with url+enter and F5
In Firefox it jumps to top with F5 - but jumps to product with url+enter

With gridContainer disabled it jumps to product - but grid messes up

NnmitApr 6, 2020

Update: Just tried to test with your demo-data. Added the following to the shop-3.html at at product:


 

https://mmbr.dk/_canvas_support/canvas/shop-3.html#test

Same problem - it returns to top! Except in firefox with url+enter. So maybe it's at cache/gridContainer-issue

But it's at puzzle to me

SSemicolon WebSTAFFApr 7, 2020

Hello,

Thanks for more info on this. After carefully studying all your replies and checking the Codes in our development environment, it appears that this is something that is definitely caused due to the Grid Containers. If you check the Inspect Element functionality on your Browser, you will notice that the Grid Items are absolutely Positioned which is generated automatically by the IsoTope jQuery Plugin according to their initial position offset. And due to being absolutely positioned, the correct offset of the Item is not retrieved which is why the hash does not work as expected. Unfortunately, currently there is no solution for your issue as this is something that is not controlled by our codes but the Plugin itself. We are planning to make the Grid Independent for the Shop Items in an upcoming update and we will try finding a solution for this. Thanks for your Patience.

Meanwhile, do let us know if we can help you with anything else or if you find any further issues with Canvas.

NnmitApr 8, 2020

OK. I have made a workaround with a small script until then


window.onload = setTimeout(function(){
  var elmnt = document.getElementById("test");
  elmnt.scrollIntoView();
}, 500);
SSemicolon WebSTAFFApr 8, 2020

Hello,

Let us know if we can help you with anything else or if you find any further issues.

Have the same question, or something new?

Sign in to the Canvas dashboard to reply or open your own topic. Canvas owners get direct help from the SemiColonWeb team.

Reply on the dashboard