Search code examples
widgetblogstumblrsidebarcustom-pages

How can I hide a Tumblr sidebar widget from pages?


I've added a widget to my Tumblr sidebar and I don't want it to show on Ask and other custom pages.

I used the following code

{block:PermalinkPagination}
   ...code...
{/block:PermalinkPagination}

It didn't work.

I've tried wrapping between these codes as well.

{block:HasPages}
   ...code...
{/block:HasPages}
{block:Pages}
   ...code...
{/block:Pages}
{block:Date}
   ...code...
{/block:Date}

but it's still showing up on the pages. I'd like to remove the widget on Ask and other static pages. Is that possible?


Solution

  • Try using {block:IndexPage}. It should not be true for custom pages or the Ask page.

    {block:IndexPage}
        ...code...
    {/block:IndexPage}
    

    For permalink pages use:

    {block:PermalinkPage} 
        ...code...
    {/block:PermalinkPage}