Search code examples
http-redirecthttp-status-code-404tumblr

Tumblr Redirects to 404 Page


We have had a Tumblr page set up for a year with no issues until this past month.

We have a page redirect in our navigation bar. The redirect goes to our main website, WordBrewery.com. The link listed in the redirect is the main URL - http://www.wordbrewery.com.

Now it is redirecting to our site's 404 page and this is added to the end of the URL:

#_=_

I have tried using this script, but it has done nothing:

<script>
if (window.location.hash == "#_=_")
{
window.location.hash = "";
}
</script>

I have also tried replacing the main URL with a shortened Google version but this has not worked either.

Any help would be greatly appreciated.

EDIT:

The hard code that I am able to edit appears like this:

   <nav class="navbar navbar-inverse navbar-fixed-top">
      <div class="container">
        <div class="navbar-header">
            {block:IfShowAvatar}
              <a href="/" title="{lang:Home}" id="avatar"><img src="{PortraitURL-128}" class="{AvatarShape}" alt="{Title}" /></a>
            {/block:IfShowAvatar}
          <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
            <span class="sr-only">Toggle navigation</span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
          </button>
        </div>

        <div id="navbar" class="collapse navbar-collapse">
          <ul class="nav navbar-nav">
            {block:IfShowTitle}<li class="active"><a href="/" title="{Title}">{Title}</a></li>{/block:IfShowTitle}
            {block:IfShowArchiveLink}
              <li><a href="/archive" title="{lang:Archive}">{lang:Archive}</a></li>
            {/block:IfShowArchiveLink}
            {block:IfShowRandomLink}
              <li><a href="/random" title="{lang:Random}">{lang:Random}</a></li>
            {/block:IfShowRandomLink}
            {block:HasPages}
                {block:Pages}<li><a href="{URL}" title="{Label}">{Label}</a></li>{/block:Pages}
            {/block:HasPages}
            {block:AskEnabled}
              <li><a href="/ask" title="{AskLabel}">{AskLabel}</a></li>
            {/block:AskEnabled}
            {block:SubmissionsEnabled}
              <li><a href="/submit" title="{SubmitLabel}">{SubmitLabel}</a></li>
            {/block:SubmissionsEnabled}
            {block:IfTagMenuList}
              <li class="dropdown">
                <a href="#" id="tag-menu" data-toggle="dropdown" aria-expanded="true">
                  {text:Tag Menu Title} <span class="caret"></span>
                </a>
                <script>
                  var list = '{text:Tag Menu List}';
                  list = list.split(',');
                  var html = '<ul class="dropdown-menu" role="menu" aria-labelledby="tag-menu">';
                   for(var i=0; i<list.length; i++) {
                      html += '<li role="presentation"><a role="menuitem" tabindex="-1" href="/tagged/' + list[i] + '">#' + list[i] + '</a></li>';
                    }
                  html += '</ul>';
                  document.write(html);
                </script>
              </li>
            {/block:IfTagMenuList}
            {block:IfShowSearch}
              <li><a class="icon-search search-overlay-show"></a></li>
            {/block:IfShowSearch}
          </ul>
        </div><!--/.nav-collapse -->
      </div>
    </nav>

Solution

  • I am unsure of how to get rid of the string Tumblr adds to redirected URLs but alternatively you can hard code the link to avoid utilising Tumblr's redirect.

    Beneath {block:HasPages} add <li><a href="https://www.wordbrewery.com/" title="WordBrewery.com">WordBrewery.com</a></li>