How to really remove the node title of an embedded node? I want to have easily reusable pieces of content inside my nodes. I did something with Node Embed and Exclude Node Title.

But then I found out that Exclude Node Title is really dirty and simply makes the string itself empty, but there's still HTML, so I have &lt;h2&gt;&lt;a href="the-piece-of-reusable-content"&gt;&lt;/a&gt;&lt;/h2&gt;, which sucks for design (can be hacked around with CSS) but even more for SEO: I don't want my piece of reusable content to be indexed in Google, I don't want Google to start thinking I'm playing them by having an empty &lt;a&gt;.

Is there a good fix for this? Or maybe there's a better way to do this, e.g. by embedding blocks inside the content?
node_embed uses node_view() and drupal_render() to display a node.

With the default node.tpl.php, the title is always displayed unless the node is rendered as a "page". The "page" variable is determined in an obscure way in template_preprocess_node(), and is typically false with embedded nodes. So the title will be rendered.

  &lt;?php print render($title_prefix); ?&gt;
  &lt;?php if (!$page): ?&gt;
    &lt;h2&lt;?php print $title_attributes; ?&gt;&gt;&lt;a href="&lt;?php print $node_url; ?&gt;"&gt;&lt;?php print $title; ?&gt;&lt;/a&gt;&lt;/h2&gt;
  &lt;?php endif; ?&gt;
  &lt;?php print render($title_suffix); ?&gt;


I see two ways to prevent this:


A custom node template for the view mode that is used by node_embed, in your theme.
Use a display suite layout for the given view mode. With display suite, the usual node template is ignored, and the title is just one among other visual elements to be positioned in the display. I prefer this solution, because I like display suite :)


node_embed ships with a dedicated view mode 'node_embed', which is used by default for embedded nodes. So this is the one you need to configure or target with a template.

BTW, at the time of this writing, the module page of Node embed says it is no longer supported. There is another module, Entity embed, which seems not to have this problem.