Community Documentation

Submitted_by: Submission line by content type

Last updated December 17, 2012. Created by NancyDru on October 21, 2008.
Edited by tax14. Log in to edit this page.

The Submitted_by module is a simple little bit of code that allows the admin to change the "Submitted by..." line for nodes and comments by content type. Each content type gets its own pattern for this line. Using the Token module, there is a wide variety of data available to fill in the pattern. The Real Name module places nicely with this one and even provides more tokens.

Installation

Normal module installation applies to this module.

Settings

Submitted by node edit fieldset
The settings are found on the content type administration form, in a fieldset titled "Appearance." There is a similar fieldset inside the Comment settings for changing the "Submitted by..." line in the comments. Within each of those fieldsets is another fieldset that, when expanded, shows all the available tokens that you may use.

For example, on one content type that is often user-submitted, we use: Contributed on [month]  [d], [yyyy] by [realname-link].

Step by Step Example for Drupal 7

Assuming that you want to change the submitted by information for the Article page from the default Submitted by admin on Thu, 06/21/2012 - 15:26 to Created on June 21, 2012 where June 21, 2012 is the date the node was created on.

  • Choose Structure, Content Types and click Edit against Article.
  • Click Display Settings.

If the Submitted_by module is installed and enabled, you should see a windows similar to the following.

Editing Display Settings

Notice the Byline text box, which is used to define the replacement text for the default "submitted by" information. You may take the help of the Tokens displayed on the screen.

  • Enter the following text in the Byline text box.

Created on [node:created:custom:F] [node:created:custom:j], [node:created:custom:Y]

Notice that F, j and Y format characters used here are the PHP date format characters.

  • Click the Save Content Type button.

Now if you view an article node, you should see the revised submitted by information on the page.

Menus

There are no exposed menu items for this module.

Permissions

There are no extra permissions for this module.

Blocks

There are no blocks for this module.

AttachmentSize
submitted_by1.PNG46.32 KB

Comments

Submitted by - another example

In case you want to format Submitted by as something like:

Nov 1, 2009 by AuthorName in ArticleCategory (Last updated: Nov 7, 2009)

where AuthorName and ArticleCategory are links, you can try the following 'Submitted by...' text:
[mon] [d], [yyyy] by [author-link] in <a href="/drupal/[termalias]">[term]</a> (Last updated: [last-edit-mon] [last-edit-d], [last-edit-yyyy])

Submitted by info not visible on pages?

If Submitted by info is not visible to users, be sure to check that you've enabled Display post information on:

(Administer > Site building > themes), select the "Configure" tab, then "Global settings."

something doesn't work

i don't know what have i done
but i made field_name_forum
and i put the token in 'Submitted by...' text:
but still it doen't show the override on submitted in the forum
pls help

p.s. drupal 6

Hmm

Are you sure the token is being populated?

Issue queue: http://drupal.org/project/issues/submitted_by

set it for all node types...

If you go to admin->content mgmt->post settings, you can set the "submitted by" text for all nodes (only applies to new nodes).

~elizabeth

Page status

No known problems

Log in to edit this page

About this page

Drupal version
Drupal 6.x, Drupal 7.x
Level
Beginner, Intermediate

Site Building Guide

Drupal’s online documentation is © 2000-2013 by the individual contributors and can be used in accordance with the Creative Commons License, Attribution-ShareAlike 2.0. PHP code is distributed under the GNU General Public License. Comments on documentation pages are used to improve content and then deleted.
nobody click here