Porkue Posted January 21 Share Posted January 21 There's a bug in my template where if you go back from a password protected gallery to the index, none of the links work. To avoid this I'd like to open only this gallery in a new window. Any suggestions? Link to comment
tuanphan Posted January 22 Share Posted January 22 Hi, Can you share link to gallery? We can check easier Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
Porkue Posted January 22 Author Share Posted January 22 Oh for sure, thank you. The index is here: https://www.therealsamkirk.com And the gallery that breaks links when you try to go BACK from it is here: https://www.therealsamkirk.com/project-quicksilver/ To reproduce: - access the "work" page - click on the 3rd tile (project quicksilver) - use the browser functions to navigate back to the index - try to click on any project, doesn't work. NOTE: If you reload the page it will load the project you clicked on Pretty weird, but that's why I want to just force that project to open in a new tab. Link to comment
tuanphan Posted January 23 Share Posted January 23 Try adding this code to Website Tools (under Not Linked) > Code Injection > Footer <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script> <script> $(document).ready(function() { $('.item a').attr('target','_blank'); }); </script> Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
Porkue Posted January 23 Author Share Posted January 23 Thank you for the response! Does this specifically address the buggy navigation? Unfortunately I would need to upgrade to a more expensive plan to allow for code injection in the footer. Is there any alternative route that would only require custom CSS? I am still interested in a solution that just forces the password protected project to open in a new window as that would solve the issue as well. Link to comment
Solution tuanphan Posted January 28 Solution Share Posted January 28 (edited) On 1/24/2024 at 12:45 AM, Porkue said: Thank you for the response! Does this specifically address the buggy navigation? Unfortunately I would need to upgrade to a more expensive plan to allow for code injection in the footer. Is there any alternative route that would only require custom CSS? I am still interested in a solution that just forces the password protected project to open in a new window as that would solve the issue as well. You try edit Site Footer > Add a block > Choose Markdown > Then paste the code or try disable Ajax Loading in Design Edited January 28 by tuanphan Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
Porkue Posted February 10 Author Share Posted February 10 This is fantastic. I tried adding the markup block to the footer and it worked perfectly. @tuanphan coming through again! THANK YOU tuanphan 1 Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment