How do I change the style used by the "Archive" view to show the dates? By default the "Archive" views module displays the dates as "May 2011." I want to change them to "2011 year May."

How do I do that? Is it possible? 

from the instructions of googletorp: i made the following but it's not work. what's wrong with my code?


created a module named customviews. which have files(customviews.info, customviews.module, customviews.views.inc)
customviews.module has code:

    &lt;?php
      function customviews_views_api(){
        return array('api'=&gt;2);
      }


function customviews_views_data_alter(&amp;$data) {
             // Set the argument to the handler you named above.
             $data['node']['created_year_month']['argument']['handler'] = 'custom_handler';
           }
customviews.views.inc has code

 &lt;?php
   class custom_handler extends views_handler_argument_node_created_year_month {
     function construct() {
       parent::construct();
       $this-&gt;format = "Y year M month"; 
     }
   }



i have cleared the cache.

i put the function customviews_views_data_alter(&amp;$data) into the .module file. it's still can't work. what's wrong with it?
Views haven't supplied an easy way of doing this, but it is possible. To do this you would have to create your own handler and make views use that:

1. Creating own handler

class custom_handler extends views_handler_argument_node_created_year_month {
  function construct() {
    parent::construct();
    $this-&gt;format = 'F Y'; // Write your custom format here.
  }
}


2. Making view use your custom format

function module_name_views_data_alter(&amp;$data) {
  // Set the argument to the handler you named above.
  $data['node']['created_year_month']['argument']['handler'] = 'custom_handler';
}


Update.


The custom_handler class or whatever you choose to call it need to go in it's own file. For Drupal 7 the standard is to put it in a dir called handlers which is located in the dir that you specify with hook_views_api, and add the file as include in the .info file (Look at the views module for reference).
For the module_name_views_data_alter you need to replace module_name, with the name of your module.
Clear cache.