code: public CmsResource uploadFile(String localfile, String folder, String filename, String type)
      throws Exception, CmsIllegalArgumentException {
  
          I_CmsResourceType t = OpenCms.getResourceManager().getResourceType(type);
          return m_cms.createResource(folder + filename, t, CmsFileUtil.readFile(new File(localfile)), null);
      }
docs: Loads a file from the "real" file system to the VFS.<p>
  
  @param localfile the file upload
  @param folder the folder in the VFS to place the file into
  @param filename the name of the uploaded file in the VFS
  @param type the type of the new file in the VFS
  @return the createed file
  @throws Exception if something goes wrong
  @throws CmsIllegalArgumentException if the concatenation of String arguments
  <code>folder</code> and <code>localfile</code> is of length 0