How to implement the download of the index file for permissions 768, 1024 and so on. depending on the resolution of the user's monitor? Thank.

  • Sorry, why do you need it? - Stepan Kasyanenko 2:12 pm
  • @StepanKasyanenko I don’t need it, the customer needs it, I don’t understand why this hemorrhoids are. If you know how to implement, I will be grateful - undefined
  • 1080 then .. - ishidex2
  • @Duoxx what is 1080? - undefined
  • one
    Pervert, not the customer ..... - Air

1 answer 1

The customer most likely wants to adaptively make a website and came up with such a way :)

if ($('body').width() > 1024) { $("#info").load("max1024.html", function(response, status, xhr) { if(status == "error") { $("#info").html("Ошибка: " + xhr.status + " " + xhr.statusText); } }); } else { $("#info").load("min1024.html", function(response, status, xhr) { if(status == "error") { $("#info").html("Ошибка: " + xhr.status + " " + xhr.statusText); } }); } 

and all content displayed in the block with ID = info