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.

Passing Total to Confirmation Page via query string Without Currency Symbol

  1. bluantinoo
    Member

    Hello,
    I'm using GF to sell a configurable service (a product with options).

    I would like to pass to confirmation page (redirect page) via quesry string all info I need to build Google Analytics ecommerce Tracking code.

    The only issue I'm having is about the Total Amount: I can't find a way to pass it without the currency symbol.

    I've tried like this:
    total={Total:87}

    and like this:
    total={Total:87:value}

    but in both ways the querystring is dirty (as the currency symbol is converted to be URL-compatible) so I keep get something like this:

    http://www.mysite.com/thank-you/?total=136%2C90+%26%238364%3B

    is there a way to clean the value of that field to have just the numeric total?

    Posted 10 years ago on Monday June 10, 2013 | Permalink
  2. David Peralty

    That's an interesting issue. The only way I could think of would be to have a hidden field and then process the value on submission. You could using our pre_submission hook, grab the value of the total, and strip out the currency symbol before putting the value in your hidden field, and using that field as the one for the query string. Does that make sense?

    Posted 10 years ago on Monday June 10, 2013 | Permalink
  3. bluantinoo
    Member

    If this is the only way I have no choice.
    I'll try and I'll let you know

    Posted 10 years ago on Tuesday June 11, 2013 | Permalink
  4. bluantinoo
    Member

    I've tried and actually I have some problems:

    1) I have several forms (24 and growing) so I cannot make a scritp that grab the value of the total from a specific imput.
    Is there a way to build an abstract function about "total" grabbing to make it work on any form?

    2) same question of point 1, this time about the hidden field that should receive the value.

    3) are hidden field shown in the notification merging tag {all_fields}?
    If yes, there's a way to clean up rendering of all_fields from that hidden field?

    Posted 10 years ago on Tuesday June 11, 2013 | Permalink