Hide the block on the "node/add/my_content_type" page I created a content type. I want to show a block on all nodes of this content type except "node/add/my_content_type". I used the following PHP code:

global $node;
$arg1 = arg(1);
if ( $node-&gt;type == 'my_content_type') &amp;&amp; arg(0) == 'node' &amp;&amp; is_numeric($arg1) ) {
  return TRUE;
}
return FALSE;  //default


Result: the block does show on all nodes of this content type, but also show on "node/add/my_content_type". 

What I did wrong? Thanks for any help.
Try this

$node = menu_get_object();
return isset($node) &amp;&amp; $node-&gt;type == 'your_content_type' &amp;&amp; arg(2) == '';


Edit: forgot about the third parameter