• First of all, thanks for coding this plugin πŸ™‚

    Here’s the point. I ran into a client who wanted to change these labels:

    Acceptable file types: zip,rar.
    => Supported file formats: zip or rar

    Maximum file size: 1mb.
    => Maximum file size: 1 MB

    and also wanted to personalize the Browse button label.

    Would it be possible to add these to the built-in “Change labels” options?

    http://wordpress.org/extend/plugins/si-contact-form/

Viewing 7 replies - 1 through 7 (of 7 total)
  • Yes, in the next version.

    These labels will be changeable.
    Supported file formats:
    Maximum file size:

    (zip or rar)? maybe
    (it is a programming variable).

    Thread Starter

    (@rickjoe)

    Mike, thanks for the quick response!

    I know, I wouldn’t mess with programming variables. But note that if you use wildcards in the labels and replace them later with the programming variables, we can choose not to show those wildcards, i.e.:

    Acceptable file types: $s
    => Supported file formats: zip or rar

    Maximum file size: $s
    => Maximum file size: 1 MB

    This can be achieved in translations by using WPML, but even with that plugin it’s not possible to change the labels for the main language.

    Of course, changes to file formats and file sizes wouldn’t be automatically reflected in those strings, but I don’t think that should be a problem, if we choose to personalize the labels like this we can always update then manually.

    What about the “Browse” button label for attachments? Are you planning to make that one changeable too?

    Currently, there is no way to style an attachment selector field with HTML or CSS. It can be styled with with JavaScript techniques, but this form does not have a built in way to support changing it like that.

    FAQ page:
    http://www.fastsecurecontactform.com/file-attachment-field-style

    Thread Starter

    (@rickjoe)

    I’m not talking about styling, I just wanted to change the word “Browse” in that button for any other string. Here’s the code that FSCF is generating for it:

    <input style="text-align:left; margin:0; width:700px;" type="file" id="si_contact_ex_field2_10" name="si_contact_ex_field10" value=""  size="20" />

    This should do the trick:

    <input style="text-align:left; margin:0; width:700px;" type="file" id="si_contact_ex_field2_10" name="si_contact_ex_field10" value="PERSONALIZED_BUTTON_TEXT"  size="20" />

    You can store that custom text the way you do with all other labels.

    Rick, did you try that code because it does not have any effect on the “Browse” button. Like I said, HTML does not allow changing the word “Browse” or the style of a file type field, only javascript can(looks too complex for my liking).
    http://www.quirksmode.org/dom/inputfile.html

    I added the labels you can change, manually update the program to use it before next version:
    http://www.fastsecurecontactform.com/update-to-the-latest

    Thread Starter

    (@rickjoe)

    Mike, sorry for the delay, I had a busy weekend.

    I didn’t try that code, I mistakenly assumed that field would behave like other standard form elements. The main goal behind this is to localize that label when you use different languages, but since it pulls the language from the browser configuration, it shouldn’t be a problem.

    Thanks a lot for adding those labels!

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘[Plugin: Fast Secure Contact Form] A couple of suggestions regarding labels’ is closed to new replies.