What about adding a new display style for this field so that instead of displayind a link it actually displays an embedded contact form? Or for even better usability an AJAX form would be even nicer.
What about adding a new display style for this field so that instead of displayind a link it actually displays an embedded contact form? Or for even better usability an AJAX form would be even nicer.
Comments
Comment #1
ximo commentedYou mean something like this? (Goes into template.php of your theme.)
I might look into writing a patch with a display style that does this during the weekend, but can't guarantee I get the time. If I don't, feel free to pick this up someone :)
Comment #2
pauldawg commentedHmmm... well at first glance, that looks right, but I replaced the all-caps areas and it had no effect at all. Not sure if there is something I am missing. I've tried putting this in template.php and in field.tpl.php, with no effect.
But yes, this would need to use its own display style, as there are other views in which I actually show the email address itself. Or alternately, it could just show whenever "email contact form" is the chosen display style.
Comment #3
lorenlang commentedximo: This worked perfectly for me (v6.13) by only changing the THEME_NAME and FIELD_NAME. Thanks much!
pauldawg: What are you seeing? Are you getting anything? Show us a screenshot maybe?
Comment #4
perkeIt does work when using default node.tpl but how do you go about adding this into custom node-type.tpl ?
I added
but got only link to form. what am I missing?
Comment #5
johnvDoes the following D7-patch help? #1264210: Add actual contact form display formatter