0

I have following code:

$(document).ready(function() {
    $(".image").fancybox({
          helpers: {
              title : {
                  type : 'float'
              }
          }
      }); 

});
    </script>

</head>
<body>
    <a class="image" href="http://farm4.staticflickr.com/3712/9032543579_1217e6566b_m.jpg"  title="Singapore from the air (Andrew Tan 2011)">
<img src="http://farm4.staticflickr.com/3712/9032543579_1217e6566b_m.jpg" alt="" />

it works as expected when click on image:

enter image description here

if rewrite body like this:

<a class="image" href="http://localhost:9091/member/createCompany/getOriginalImage/1"  title="Singapore from the air (Andrew Tan 2011)">
<img src="http://farm4.staticflickr.com/3712/9032543579_1217e6566b_m.jpg" alt="" />

I see following result when I click on picture:

enter image description here

I don't understand what the problem. please help.

gstackoverflow
  • 36,709
  • 117
  • 359
  • 710

1 Answers1

0

It is working as expected if add .jpg at the end of the url.

href="http://localhost:9091/member/createCompany/getOriginalImage/1.jpg"

But I don't know why.

I've found related links:

Fancybox urls without .jpg opens not in box
Fancybox not working with images from Twitter API

Community
  • 1
  • 1
gstackoverflow
  • 36,709
  • 117
  • 359
  • 710