• Resolved joymorin

    (@joymorin)


    Goal: I would like to be able to show a clickable icon (such as <span class=”dashicons dashicons-email-alt”></span>) as a placeholder to lead to website links and/or a “mailto:” email address links.

    I found the instructions explaining how to use create a text link or a clickable icon that leads to a single record page, but it’s unclear to me if I can set it up to lead to URLs entered in link fields entered by participants. I’ve been scouring the plugin documentation, but am not sure whether I am missing something or if this is a functionality this plugin does not support. Any chance you could let me know?

    Thanks so much.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author xnau webdesign

    (@xnau)

    One way to do this is using a “link” field. Put the icon tag in the Default value in the field definition. As long as the user does not enter a value for the clickable text, the icon will be shown and clickable.

    If you need, you can use some CSS to hide the input from the user so they won’t type something in.

    Thread Starter joymorin

    (@joymorin)

    Thank you so much! That solution works perfectly for my website link column!

    Any magic for using a similar approach for email addresses? I was thinking a clickable mail icon would take up less room than displaying the entire email address.

    Plugin Author xnau webdesign

    (@xnau)

    With email addresses, it’s a bit tricker, since the field is not already set up to have a different clickable string. With a little custom code, you can alter the appearance of your email field (usually this is a regular text-line type field) so that it shows the icon rather than the email address.

    There is a filter pdb-before_display_form_element that you can use to alter the display of the field. Best way to add this filter is with a custom plugin or add it to your theme functions.php

    Thread Starter joymorin

    (@joymorin)

    I think those steps might be a little bit over my head… or at the very least pretty time intensive, so I think I’ll remain content with the way the email addresses display as they are. But thank you so much for getting back to me so promptly for both questions!

    Perhaps you could consider it as a future new feature for your plugin? Maybe other users would find it useful to be able to display an icon for email. It looks nice and also saves space in the table.

    Anyway, thanks so much for the great plugin! Happy Holidays.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Question re: placeholders; icons’ is closed to new replies.