Strange subpage behaviour

No, they don’t work. That is really strange, any idea where the issue might be?

Hm, if it was a rewriting issue, I would expect only the Startpage to work. But I don’t know what additional stuff you have working in your project, so it’s hard to tell what’s happening here.

Okay, back to the drawing board then. As I ported stuff from an old kirby 2 theme I created I will reset stuff and check where the issue might be. I’ll keep you posted.

Found the issue, I do inline an svg sprite with an ajax request in the header that fails on subpages:

  <!-- svg sprite -->
  <script> 
        var ajax = new XMLHttpRequest();
        ajax.open("GET", "assets/img/sprite.svg", true);
        ajax.send();
        ajax.onload = function(e) {
          var div = document.createElement("div");
          div.innerHTML = ajax.responseText;
          document.body.insertBefore(div, document.body.childNodes[0]);
        }
   </script>
   <!-- //svg sprite -->

I should probably not hardcode the path though.