Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
It would be great to have the option to display full node body on the same page by clicking 'Read more' link.
Comments
Comment #1
Alan D. CreditAttribution: Alan D. commentedSorry, this would be outside the scope of this module. And from a 2 min search, there does not appear to be a module that handles this :(
Re: Feature itself: Like these ideas?
https://github.com/seanbuscay/drupal-ajax-demo
http://seanbuscay.com/ajax-reader-demo
http://www.drupalgardens.com/content/use-ajax-display-full-content-conte...
http://drupal.stackexchange.com/questions/16055/replacing-a-teaser-theme...
...
https://www.google.com.au/search?q=drupal+ajax+teaser+full+view
Note that of the first 10 examples I found via google, I have not seen any that take node_access() into account. The menu callbacks should use the access callback node_access and the access arguments ('view', 1) where 1 is the position of %node in the menu callback.
Then to integrate back to this module, in the node preprocessor, use this flag to remove the ajax action if there is nothing to read:
This works on the other entities too, $user->readmore_required, etc, (only if the user entity had fields and the the read more control module was enabled on users).
Comment #2
quotesBro CreditAttribution: quotesBro commentedThank you, I guess I need something like