My landing page is a static page. I do not want the "read more" option on my landing page. And I want to display the entire content. How can I remove "read more" in Drupal 7. I saw that this subject got attention back in Drupal 4, but the administration of Drupal 7 does not follow Drupal 4 methods.

Comments

biografica’s picture

This one is on my list to solve as well.

Be sure to post if you find the answer and I'll do the same...

RumpledElf’s picture

There's a module pending for d7 that makes the 'read more' stuff behave properly. Feel free to use it and test it :)

http://drupal.org/node/1056940

Otherwise, go into 'manage dispay' on your content type and at the bottom of the page is a collapsed fieldset you can remove the teaser display. This, however, often doesn't work very well - d7 actually adds the 'read more' link to ANY teaser whether you want it or not.

tomcatuk’s picture

"d7 actually adds the 'read more' link to ANY teaser whether you want it or not"

Maybe it's just me, but this seems both a bizarre and outdated way of linking when we're talking about teasers for non article type content. I see the logic for article teasers of course, but Drupal isn't Wordpress, and not every site built on the platform is a blog.

newbeGeorge’s picture

"Otherwise, go into 'manage dispay' on your content type and at the bottom of the page is a collapsed fieldset you can remove the teaser display."

I could not find these options. :(

Starbuck’s picture

Go to Administration » Structure » Content types.
You'll see types like Basic page.
Note in the table it shows "manage display". Click that.
You are now looking at Default settings and for main content types the default Format is that the default content (all of it) will be displayed.
Open Custom Display Settings.
Note that there are custom settings for a Teaser. For each custom type you'll see a button at the top-right of the page that allows you to customize each type. Since Teaser is already there, you should see a Teaser button next to the Default button (which returns you back to the current tab/page). Click the Teaser button.
The displayed settings apply just to Teasers.
The Body Format for some types is set to "Summary or Trimmed" and you can set how far down it's trimmed.
If you set that Body Format value to Default, then the default body, that is all of it, is displayed for Teasers.

Now, all that said, if you have a Basic page displayed in your Main content area, you get the whole content, but you still get a "Read More" link. *sigh*

I eliminated Read More from my D6 install and I will look to see if that technique applies in D7. I will post most info here unless someone else posts first.

Two things bother me about the procedure above.

First, I'm describing how to reset the Teaser display for all teasers for a given content type. That might not be what someone wants when all they want to do is to put full content on the front page.

Second, rather than modifying a content type to change how it displays a teaser, I think it would be better to tell the front page that it should not display a teaser, but rather that it should display full the full body of a node. Some people might not want that either.

I think the best solution is to create a new content type which is intended specifically for front-page news, and only that type should be promoted to the front page. Further, all such content types should not have teasers, and the front-page should not attempt to display a teaser for these types, nor should it display a Read More link for them.

That solution is beyond my current expertise, but I'm guessing it would be fairly easy to create. I would be happy to work with someone on that, as the knowledge would certainly help with other tasks that require custom content types that are treated uniquely.

HTH

Radion’s picture

go to content
choose content type you want to edit not to display the teaser and click on that content types display settings at the top then go to custom display settings in blue at the bottom of the page, click on that and remove the bullet from teaser and put it on full content. save and there you go.

jimmyhomesick’s picture

That worked for me.. Thx mate.

junkbox’s picture

hit up that module, it's flawless.

Thanks giraffin!

Starbuck’s picture

I installed the Read More Control module as suggested above and WOW, it works great. No more manually tweaking CSS or tpl files! From http://drupal.org/node/1056940, I went to the sandbox and loaded everything via git.

Per my other reply today, I also created a new Content Type called News Item which never displays a Read More link. I went to Manage Display and unchecked the Teaser, so while the front page probably still thinks it's displaying the content as a teaser, at least the teaser is now the full body of the node. I created this Type so that I don't have to worry about trying to bully any other content types to render in a similar way. Now if I want a front-page posting I should be able to just use this node type.

I'm open to suggestions for how to enhance this.

The only thing I think I'd want to do now is to have the option to remove the title from these types. That could be bad in some situations but useful in others.

lelandnielsen’s picture

Subscribe

Anthony Pero’s picture

As with every thing else in Drupal, you could always use the Views module to rebuild the front page. In fact, all you have to do is enable the frontpage view that is built for you, then go in and set the node option from teaser to full node, and the read more link will disappear. About 2 minutes of work. Less if views is already installed.

Anthony Pero
Project Lead
Virtuosic Media
http://www.virtuosic.me/

Russell Mann’s picture

Views method is smart. What sort of cache clearing or "rebuilding" needs done after changing the view to make it active?

Anthony Pero’s picture

Not sure, because I never have a river of news Frontpage. Look in the view, at the page view, down in Page Settings, at the path. What does it say? To make this path your Frontpage, you may need to add the path to your site information under configuration. Not sure of the exact address in D7.

Anthony Pero
Project Lead
Virtuosic Media
http://www.virtuosic.me/

tuccio’s picture

Why is it that the Content Types settings seem to have gotten more complicated instead of simpler in Drupal 7? Or is it just me? I can't understand how Drupal 7 is said t be more user friendly than D6. If I want to display the full content, the "Read More" link should just get out of my face. The admin layout just doesn't make sense to me anymore. I moved to Drupal when I thought that my very own custom CMS was getting too complicated. Now I am thinking of going back to writing my own simple CMS because Drupal is just turning into a cult. And a bloated one for that. Anyone else feels like this?

Anthony Pero’s picture

Anything that does everything is by necessity complicated. Drupal is designed to be able to be configured without coding for a wide range of web applications. With Drupal 7, the Core maintainers attempted to streamline and simplify the interface, not the software itself. This is why Drupal is becoming more of a framework in some people's eyes. If you want simple, and have the chops, there's nothing that will perform better for you than your own custom script.

Anthony Pero
Project Lead
Virtuosic Media
http://www.virtuosic.me/

tuccio’s picture

I love Drupal, don't get me wrong. But I believe I am seeing a tendency toward making everything complicated by default, even simple things. Simple things should stay so even if the framework is powerful and complicated. Why do I have to install and learn to use Views just to get rid of the "read more" link?

Anthony Pero’s picture

See, to me, removing the option to remove the read more link is an example of simplifying things. Now, by default, you don't HAVE the option to do it. It's simpler. It ain't better, that's for sure. But it is simpler. Less flexible and simpler are synonymous these days. I'm not saying I disagree with what you are seeing. I'm just not sure there's any point in standing in front of the train. It's not gonna slow down now.

Anthony Pero
Project Lead
Virtuosic Media
http://www.virtuosic.me/

Anthony Pero’s picture

Are you saying that when you view a full node, that the read more link is still there? Or when you view a teaser?

Anthony Pero
Project Lead
Virtuosic Media
http://www.virtuosic.me/

tuccio’s picture

A Teaser that displays the full content (e.g. from inserting the break tag manually at the end of the post) still shows the "read more" link (but there is nothing more to read...)

Anthony Pero’s picture

Ok. I get it now. Of course it does. When you insert the teaser break, it's telling drupal that it needs a read more link.

So what you are saying (and trying to accomplish) is to have certain posts have a teaser, and some posts just display all of the content. In Drupal 6, you shut off the read more link, and used the teaser break in the text area to manually "fool" Drupal into showing all of the post in the teaser. Obviously Drupal wasn't intented to be use this way, so it's understandable how the use case wasn't taken into consideration when the interface was updated.

So what you really need is to code a small module that adds the ability to toggle the Read More link on/off for each content type. You could then contribute this back to the community, so others in your use case could do this also (I could certainly see myself using it on some sites).

Alternately, you could adjust the tpl file to remove the read more link.

Anthony Pero
Project Lead
Virtuosic Media
http://www.virtuosic.me/

Anthony Pero’s picture

And your last statement is not strictly true. Even if the teaser shows the whole body text, there could be other fields not shown in the teaser, comments wouldn't show up, downloads wouldn't show up, etc...

Anthony Pero
Project Lead
Virtuosic Media
http://www.virtuosic.me/

Jerya’s picture

In the cases you want the teaser to show the full content (when is at the very end of the article), you may want the "Read more" link not to show up for this material.
If it is a simple text node and there are no more additional fields (a simple text node) - this is how we can do it:

In your theme template.php :

function <your-template-name>_preprocess_node(&$variables) {
  ... // In some themes it can be '$variables' in the others - '$vars'.
  $node = $vars['node'];

  // Check first the "body field" exists or not.
  $field = field_get_items('node', $node, 'body');

  // If available do execution ..
  if($field) {
    $show_read_more = 1;
    if(array_key_exists($GLOBALS['language_content']->language, $node->body))
    {
        $body = $node->body[$GLOBALS['language_content']->language][0]['safe_value'];
        if(stristr($body, "<!--break-->")) // Lets make sure that this is indeed the end of article.
        {
            $rest_of_the_text = substr($body, strpos($body, "<!--break-->"));
            if(strlen($rest_of_the_text)<strlen("<!--break--></p><p>&nbsp;</p>"))
                $show_read_more = 0;
        }
        else if ($vars['content']['body'][0]['#markup'] == $body)
            $show_read_more = 0;
    }
    if($show_read_more == 0)
        unset($vars['content']['links']['node']['#links']['node-readmore']);
  }
  ...
}
mengi’s picture

Try out the Display Suite (http://drupal.org/project/ds) module. It gives you full control of the fields being displayed including the 'read more link' field. Couple that with the excellent read more module and you should be set. Note: D6 & D7 have different read more modules.

You could also make a view and have it display fields instead of a nodes teaser. Set front page to the views url in your sites configuration and your good to go,

Michael_Lessard_micles.biz’s picture

Agreed, the Read More Link module is awesome and should be core/default as far as I am concerned.

I have been using it for years on D6 and I have now tested it on my new D7 migration.

Michael Lessard
webmaster of Quebec City "democracy in action" media

jarednielsen’s picture

Works like a charm.