E-mail link columns in wpDataTables

E-mail columns in wpDataTablesE-mail column type and when to use it

“E-mail link” columns are used to render the hyperlinks which can be clicked to open default mail applications to write messages.

  • Rendering rules: If the content of the cells contains a combination of “two sticks” – || – everything to the left of this combination is used as an E-mail address for the link, and everything to the right as displayed text. Like this:

[email protected]||Write me an e-mail

will be rendered as this:

Write me an e-mail

If the “||” combination is not found in the content, the entire content will be used for both the link, and as the display value. Like this:

[email protected]

will be rendered as this:

[email protected]

  • Sorting rules: alphabetical.
  • Applicable filter types: text.
  • Issues to note: some issues may appear when you’re sorting on E-mail columns that feature a complicated HTML structure

ExampleDemo table with E-mail columns

Referral e-mail” column in this table is an E-mail type column: