PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

How to Style the Message Field

  1. Hi,

    I have a simple form which when submitted sends the user a custom html table with values and quotes, now the question I have is, I have managed to get the form submitting and the form sending the table however it does not take the <STYLE> settings outlined within the form message field, I am using standard HTML tags. In addition i need to do some calculations, normally I do this through PHP, is there another way I can achieve this and display it in the form?

    Thanks

    Tariq

    Posted 9 years ago on Saturday May 21, 2011 | Permalink
  2. Hi I dont suppose anyone can help please? this is very urgent....

    Thanks

    Posted 9 years ago on Sunday May 22, 2011 | Permalink
  3. Try using inline styles rather than a style block to define your styles. CSS support in HTML emails varies greatly and you're probably running into problems with the mail clients themselves and not something from the plugin. We haven't had any other reports of problems so I'd give that a shot.

    If you need to do calculations before the form is submitted, you should be able to use the "gform_pre_submission" action hook to run your own code before the form gets submitted. You can find usage information and samples here.

    http://www.gravityhelp.com/documentation/page/Gform_pre_submission

    Posted 9 years ago on Sunday May 22, 2011 | Permalink
  4. Hi Thanks for that but the question I have is where do I use the gform_pre_submission statements? I have a beginner to this, as you have probably noticed.

    Thanks

    Posted 9 years ago on Monday May 23, 2011 | Permalink
  5. You would put that in your theme's functions.php file.

    http://rkt.gs/where

    Posted 9 years ago on Monday May 23, 2011 | Permalink
  6. Instead of that approach could I do the following, create a hidden field on the form that when the form is submitted takes the cost field value and * by say 5 and enters that value as the hidden field?

    If not, then how do I find the ID names for the fields onn the form so I can create PHP Hook?

    Thanks

    Posted 9 years ago on Monday May 23, 2011 | Permalink