(working and testing beta version 3.1!!!)