• Resolved dakini2

    (@dakini2)


    Hi Guys, please advise how and where is there an option to translate “Select Some Options” which is showing up in the submission form in the fields with Categories and Tags selection? I do not find this expression in Loco Translate. Thank you ??

    • This topic was modified 3 years, 10 months ago by dakini2.
    • This topic was modified 3 years, 10 months ago by dakini2.
    • This topic was modified 3 years, 10 months ago by dakini2.

    The page I need help with: [log in to see the link]

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author Jeff Starr

    (@specialk)

    I’m not sure if it is possible to change that text because it is set by the browser. But I have added to the list and will try to find a way for the next update. Thanks for the feedback, @dakini2.

    Plugin Author Jeff Starr

    (@specialk)

    Hi @dakini2, just wanted to follow up with this. It’s been awhile with no reply, so I hope the issue is resolved? Or if there is anything I can do to help, please let me know. Thank you.

    Thread Starter dakini2

    (@dakini2)

    Yes, the issue is resolved. And this has nothing to do with the browser. Shame that the developers can not help with such plain issue ??

    • This reply was modified 3 years, 10 months ago by dakini2.
    Plugin Author Jeff Starr

    (@specialk)

    Hi @dakini2,

    Looking again at your question, about changing the default “Select” text for the category field, here is what I found:

    – The “Please select” text is defined in the plugin’s submission-form.php file

    – The “Please select” text is fully ready to be translated, it is internationalized in the source code:

    <option value=""><?php esc_attr_e('Please select some tags..', 'usp'); ?></option>

    – It is possible to customize the default “Please select” option by implementing the custom form template. Instructions for how to do this are provided in the plugin documentation. Basically you would need to set up the custom form, and then you could modify the template with custom “Please select” text or any other details.

    I hope this helps. Let me know if I can provide any further infos.

    Plugin Author Jeff Starr

    (@specialk)

    Looking further at this, here is a simple way to customize the “Please select” options for both Category and Tag fields:

    1) Add the following code to the option “Custom Content”:

    <script>
    var usp_disable_chosen = true;
    jQuery(document).ready(function($) {
    	$('select option:contains("Please select some tags..")').text('Whatever..');
    	$('select option:contains("Please select a category..")').text('Whatever..');
    });
    </script>

    2) Edit the “Whatever..” text in the code above to whatever you want. The first instance is for the Tag field. The second instance is for the Category field.

    Save changes and done. May need to empty/clear browser cache and/or reload the form page to view changes.

    • This reply was modified 3 years, 10 months ago by Jeff Starr. Reason: adds infos
    Thread Starter dakini2

    (@dakini2)

    Thank you for this, but I did it in much easier way. However your second solution also looks easy and fine. Why did you say it was a browser issue at first then, Jeff?

    • This reply was modified 3 years, 10 months ago by dakini2.
    • This reply was modified 3 years, 10 months ago by dakini2.
    • This reply was modified 3 years, 10 months ago by dakini2.
    Plugin Author Jeff Starr

    (@specialk)

    What is the easier way that you found?

    Plugin Author Jeff Starr

    (@specialk)

    “Why did you say it is a browser issue at first then, Jeff?”

    Because I misread the question. It is the File(s) input field that cannot easily be changed, because the “Please select” text for files depends on the browser.

    Thread Starter dakini2

    (@dakini2)

    I simply changed the words in one of .js files. Don’t remember which. Thank you for your help anyway!

    • This reply was modified 3 years, 10 months ago by dakini2.
    Plugin Author Jeff Starr

    (@specialk)

    “I simply changed the words in one of .js files.”

    Are you sure? I just checked all of the plugin’s JavaScript files and the text “Please select” is not found anywhere. Also, even if it were to exist somewhere, it is not recommended to make any changes to the plugin core files. The reason is because any changes made will be overwritten immediately when the plugin is next updated.

    Best advice for anyone who wants to customize the “Please select” tags/category option, is to use the technique described in my previous comment.

    In any case, glad you got it sorted, @dakini2.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘How and where to translate “Select Some Options”’ is closed to new replies.