Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Jan Bengtsson 64 posts 107 karma points
    Sep 04, 2013 @ 09:11
    Jan Bengtsson
    0

    Hidden field issue with commas

    Hi,

    I've got a HiddenField type in my Contour form. Using jQuery, I dynamically try to add a comma-separated list of numbers to that field. However, when I look in Umbraco's backend the commas are gone. The numbers are there alright, but separated by space only. I'm able to use other separators, like semicolon, but not commas. I tested to give the hidden field a DefaultValue (in backend) with commas in it ("1, 3, 5") with the same result - the commas are removed.

    Is there anyone who knows if/how it's possible to correctly handle commas in a Contour hidden field?

    I'm using Contour version 1.1.12 on a Umbraco 4.7.1.1 installation. The site runs on IIS 7.5/Windows Web Server 2008 R2. Asp.Net: 4.0.

    Regards
    /Jan

  • Tim 1193 posts 2655 karma points c-trib
    Sep 05, 2013 @ 17:16
    Tim
    0

    This still appears to be an issue in newer versions of Contour as well....... I've just tested it on 3.0.2 on a 4.8 installation. I'd guess it's something to do with the fact that it is treated as CSV so the commas are being stripped? Tim G will be able to answer this one best!

  • Tim Geyssens 6562 posts 15373 karma points MVP 2x c-trib
    Sep 11, 2013 @ 16:00
    Tim Geyssens
    0

    Hmm yeah might be that but will have a look :) Does this only happen on hidden fields? SO works fine when you enter it in a textfield?

  • Jan Bengtsson 64 posts 107 karma points
    Sep 11, 2013 @ 16:23
    Jan Bengtsson
    0

    Tim, it doesn't not work in text fields either - commas are removed (hadn't noticed that before).
    /Jan

     

  • Tim Geyssens 6562 posts 15373 karma points MVP 2x c-trib
    Sep 11, 2013 @ 16:25
    Tim Geyssens
    0

    Ok thanks for confirming will take a look :)

  • Tim Geyssens 6562 posts 15373 karma points MVP 2x c-trib
    Sep 11, 2013 @ 16:30
    Tim Geyssens
    0

    Well data is stored correctly so might be to aggressive stripping of illegal chars in the viewer, looking into that now

  • Jon Benedict 4 posts 25 karma points
    Oct 18, 2013 @ 15:31
    Jon Benedict
    0

    Have there been any developments on this issue? I have a few sites with contour and complaints are coming in about the stripping of commas within the forms.

  • Tim Geyssens 6562 posts 15373 karma points MVP 2x c-trib
    Oct 21, 2013 @ 09:54
    Tim Geyssens
    0

    Yeah it's just the viewer, if you export the data with the toolbar button you get the correct data

  • Jon Benedict 4 posts 25 karma points
    Oct 24, 2013 @ 22:12
    Jon Benedict
    1

    Thanks Tim! The export method you recommended works perfectly for what I needed.

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies