PDA

View Full Version : help with open window


rjwortmann
11-19-2017, 01:26 PM
I'm trying to open an image in the existing window.
I've downloaded all files (http://www.jquerycode.com/lightboxes/shadowbox-js/)
and copied this to the website i like to use it in (www.goreyhc.com/History2.html. click on newspaper articles)). however the images do not appear the original size... and that is exactly what i wanted to achieve: To open the image in original size... not very good at JS im afraid...

edbr
11-21-2017, 12:40 AM
cant see the link to newspaper articles. i fo you give me link ill check for you

rjwortmann
11-21-2017, 08:04 AM
http://www.goreyhc.com/images/history/ghc004-1.jpg is the link the articles are linked to.

But if you go to: http://www.goreyhc.com/images/history2 you will see the two newspaper articles on the right hand side.

many thanks

edbr
11-22-2017, 03:34 AM
i looked at your history page and you are not using a lightbox at all so dont see what you want to be honest

edbr
11-22-2017, 03:41 AM
i would sugest using lightbox plug in far simpler to use. old but still works

https://github.com/lokesh/lightbox2

i will put an example below

edbr
11-22-2017, 03:46 AM
to use link to the sources in the head
<link rel="stylesheet" type="text/css" href="lightbox/css/jquery.lightbox-0.5.css" media="screen" />
<script type="text/javascript" src="lightbox/js/jquery.js"></script>
<script type="text/javascript" src="lightbox/js/jquery.lightbox-0.5.js"></script>
ad a script nominating a div in this case gallery

<script">
$(function() {
$('#gallery a').lightBox();
});
</script>

then html where ypo want it to appear (in your case sidebar but i have nominated gallery


<div id="gallery">
<ul>
<li>
<a href="photos/image2.jpg" title="Company Snapshot - see your business current situation at a glance "> <img src="photos/thumb_image2.jpg" height="120" alt="Company Snapshot - Quickbooks" /> </a>
</li>
<li>
<a href="photos/image3.jpg" title="Customers and jobs list."> <img src="photos/thumb_image3.jpg" height="120" alt="Customers and jobs list - Quickbooks" /> </a>
</li> </ul> </div>


this is a copy paste from a old site bu should be easy to followi think

rjwortmann
11-22-2017, 09:39 AM
to use link to the sources in the head
<link rel="stylesheet" type="text/css" href="lightbox/css/jquery.lightbox-0.5.css" media="screen" />
<script type="text/javascript" src="lightbox/js/jquery.js"></script>
<script type="text/javascript" src="lightbox/js/jquery.lightbox-0.5.js"></script>
ad a script nominating a div in this case gallery

<script">
$(function() {
$('#gallery a').lightBox();
});
</script>

then html where ypo want it to appear (in your case sidebar but i have nominated gallery


<div id="gallery">
<ul>
<li>
<a href="photos/image2.jpg" title="Company Snapshot - see your business current situation at a glance "> <img src="photos/thumb_image2.jpg" height="120" alt="Company Snapshot - Quickbooks" /> </a>
</li>
<li>
<a href="photos/image3.jpg" title="Customers and jobs list."> <img src="photos/thumb_image3.jpg" height="120" alt="Customers and jobs list - Quickbooks" /> </a>
</li> </ul> </div>


this is a copy paste from a old site bu should be easy to followi think

ok ill try this.

rjwortmann
11-22-2017, 09:45 AM
ok ill try this.

it doesn't work, with this sample of lightroom another window opens and thats not what i want. I want it as working on my website, where the image appears in teh same window but the original size of the image and close when clicked.
On my website the only thing that doesn't work is the image appearing in the original size. That's where the problem is at the moment.
thanks for your help anyway.