Manifest: File Component

Modified on 2012/01/30 07:31 PM by cathal Categorized as Uncategorized
The File Component is used to install files. It can be used in all the package types and is one of the most used components since it nearly all case a package will require some files being installed on the DotNetNuke installation.

Allowed files include files with extensions registered at the Host Settings as valid file extensions by the host user.

The FileInstaller component is also used a base class for a number of other components that take advantage and expand the feauture defined here. Components that inherit from FileInstaller include:


Elements and attributes»

<component type="File">
  <files>
    <basePath> </basePath>
    <file>
      <path> <path/>
      <name> <name/>
      <sourceFileName> </sourceFileName>
    </file>
  </files>
</component>

  • basePath: relative path (from the root of the site) where the files will be copied
  • file: for each file to be copied include a node
  • path: relative path from where the file will be copied. If omitted the file will be copied in the folder expecified on . Notice that if a element is defined the file will have to be found in a similar relative folder inside the .zip package, otherwise the installer will not find it
  • name: the name of the file
  • sourceFileName: this can be used to override the behaviour of the node defined above. If present, it will tell the installer where the file is found in the .zip package. This node must contain a relative path + file name.

Sample»

<component type="File">
  <files>
    <basePath>DesktopModules\MyModule</basePath>
    <file>
      <path>app_localresources</path>
      <name>MyModule.ascx.resx</name>
    </file>
    <file>
      <name>MyModule.ascx</name>
    </file>
  </files>
</component>

References»


Copyright 2014 by DNN Corp | Terms of Use | Privacy | Design by Parker Moore Design