I am developing a plugin to customize wordpress administration.

Creating / Editing an article, when i user insert an image from media library or uploading it, i want to clear the image title, as default is set as image file name, and i want to set Big as image size.

I am looking for the hook to work on it, i tried by using jquery but i guess the view button load the content in ajax.


function set_form_fields() {
    echo"<script type=\"text/javascript\">
    jQuery(document).ready( function($) {
        jQuery('tr.post-title td.field input').attr('value','');

i am looking for how to set image post title='' and big radio button to "checked"

  • Show the code so we can integrate easier?
    – kaiser
    Commented Aug 29, 2011 at 7:37
  • it's really long and it sets other changes. I'm looking on how to set form values in the media box. thanks for you help
    – Michele
    Commented Aug 29, 2011 at 7:45
  • 1
    @TrustWeb kaiser is not asking for your entire plugin code, but only the code related to your problem. if you explore more, you will solve your problems, else .... Commented Aug 29, 2011 at 8:23
  • ok, i edited the post but i know it is not the right way to do it
    – Michele
    Commented Aug 29, 2011 at 8:36

1 Answer 1


Not sure about the title part, but you should be able to set some defaults for images using update_option(). You can try adding the following to your functions.php to set the default size to large - you should be able to take it back out after it's been called once so you're not updating the option every single time something loads:

  • Or filter option_image_default_size and replace the size if it doesn't exist with large. Commented Sep 22, 2012 at 0:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.