<commit_before>extends ../layout

block content

  h1= t("page.offline.heading")
  p= t("page.offline.msg1") <commit_msg>changed: during attempt to access cached webform **offline** using a webform URL **with query string** that is not in applicationCache, redirect to non-querystring URL, https://github.com/kobotoolbox/enketo-express/issues/448<commit_after>extends ../layout

block style
    style.
        .error {
            margin: 40px 20px 20px 20px;
            padding: 20px;
            border: 1px solid #F2616D;
            position: relative;
            font-weight: normal;
            min-height: 100px;
        }

block content

  h1.error= t("page.offline.heading")
  p= t("page.offline.msg1") 

  script.
        var enketoId = _getEnketoId( '#', window.location.hash );
        var query = location.search;
        if (enketoId && query) {
            var bareUrl = window.location.pathname + window.location.hash;
            location.href = bareUrl;
        }
        function _getEnketoId( prefix, haystack ) {
            var id = new RegExp( prefix ).test( haystack ) ? haystack.substring( haystack.lastIndexOf( prefix ) + prefix.length ) : null;
            return id;
        }
{'fraction_non_alphanumeric': 0.1111111111111111, 'fraction_numerical': 0.020729684908789386, 'mean_word_length': 2.315934065934066, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4772026', 'n_tokens_mistral': 388, 'n_tokens_neox': 362, 'n_words': 96}