TypeError thrown

ftp_mkdir(): Argument #1 ($ftp) must be of type resource, null given