Move to Subfolders based on date

How would I go about running a command which would move selected files and folders into subfolders based on the file date?

Optionally I also will then want:
*option to group by day, week or month
*use file create date, modify date or the current system date

I am a perl coder, is my best bet to try and write something with the PerlScript guide at [Rename scripts in JScript, VBScript and PerlScript)
or is there a native way to do it using the approach in resource.dopus.com/viewtopic.php ... +thumbnail
e.g.
Copy MOVE FILE {filepath$} HERE CREATEFOLDER {file$|noext}

Something like this (see Leo's reply): [One button to move files to a new folder) ?

Or this: [Move files by date)