splntrdgrss
splntrdgrss

Reputation: 11

AngularJS website works in Firefox, but not in Chrome

For some reason, my website doesn't work in Chrome.

I've pinpointed it down to a gallery controller. It seems that if it's present, the whole app cannot work in Chrome. Apparently, it could be because Firefox autocompletes tags. However, the problem lies only in the Angular app itself. If I change the order of the 's, and put the section with the gallery last, the website remains unbroken in Chrome, BUT, the gallery is.

app.controller('GalleryCtrl', function ($scope, Lightbox) {
  $scope.images = [
    {
      'url': 'https://www.kreo-it.pl/ResponsiveWebDesign.jpg',
      'thumbUrl': 'https://www.kreo-it.pl/rwdthumb.jpg',
    },
    ];

   $scope.openLightboxModal = function (index) {
    Lightbox.openModal($scope.images, index);
  };

});

app.controller('GalleryCtrl1', function ($scope, Lightbox) {
  $scope.images = [
    {
      'url': 'https://www.kreo-it.pl/BannerTemplate.jpg',
      'thumbUrl': 'https://www.kreo-it.pl/bthumb.jpg',
    },
    ];

  $scope.openLightboxModal = function (index) {
   Lightbox.openModal($scope.images, index);
  };

});

app.controller('GalleryCtrl2', function ($scope, Lightbox) {
  $scope.images = [
    {
      'url': 'https://www.kreo-it.pl/VisualIdentity.jpg',
      'thumbUrl': 'https://www.kreo-it.pl/vithumb.jpg',
    },
    ];

  $scope.openLightboxModal = function (index) {
    Lightbox.openModal($scope.images, index);
  };

 });

This is the code of the controller(s). I'm using multiple, because I haven't found a solution that will give me 3 single lightboxes that do not interact with eachother in a single controller. Anyhow, my questions are:

Thanks. The website in question is www.kreo-it.pl, click the "PORTFOLIO" tab. As you can see, the gallery works in Firefox, but not in Chrome.

Upvotes: 0

Views: 463

Answers (1)

Sunil Boricha
Sunil Boricha

Reputation: 456

Yes i have test your site in both browsers. All are working fine in chrome also. here attached Screenshot from my browsers. popup open perfect. yes i check there are issue from data loading. Your image size is high resolution so take load time for view image on popup. also rename all image with lowercase.

chrome tested

Upvotes: 1

Related Questions