Sitemap Sitemap  |  Contact Us Contact Us  |  Clients Clients
   AddDefaultIndexToFolder
  Home |  WebHare Lite |  Downloads |  HareScript |  Websites/CMS |  Applications
Search for:  in: 
Websites/CMS
Website development
Publisher modules
 
Content types
File manager
Publisher database definitions
Publisher webui components
Scheduler/queue control
AddDefaultIndexToFolder
  Add an index file to a folder
 
Library module::publisher/filemanager.whlib
 
Syntax PUBLIC RECORD FUNCTION AddDefaultIndexToFolder (INTEGER parentfolderid,INTEGER ownerid)
 
Description AddDefaultIndexToFolder() tries to add an index file to the folder with ID parentFolderID.
If there already is an index available in the folder it will return the ID of this index file.
If not, it will try to add an index to the folder using the standard rules:
- Check if the site is configured to always use an index assigned to the folder
If so, use it. If not then
- check if there is an indexfile available in the parent folder.
If so: copy this into our folder. If not, then
- check if there is a default index file assigned to the site that should be used in no index
can be copied from the parent folder.
If so: use it. If not, there's nothing we can do.
The index file that will be added must be an HTML (type: 5) or HareScript file (type: 7)
 
Parameters
parentFolderID The ID of the folder in which to insert the index file.
ownerID The ID of the owner of the index file
 
Returns A record containing the ID of new index file and an error message (if any)
  The record contains the following cells:
ID The ID of new index file or 0 if we could find an index file to add, or if an error occurred
errorcode 1: Site misconfigured
 
 
In library 'filemanager'
AddDefaultIndexToFolder
AddFolder
AddFolderWithMetadata
AddGroup
AddGroupToFolder
AddSite
AddUserToGroup
AssignFileToSite
AssignUserToSite
ConcatMoveResults
CopyFile
CopyFolder
CopyFolderIntoFolder
CopyFolderStructure
CopyFolderStructureIntoFolder
DeleteFile
DeleteFolder
DeleteGroup
EmptyMoveResults
ExportFolderToArchive
FindGroup
FindGroupByName
FindUserSiteRecord
ImportArchive
IsUserInGroup
IsValidName
MoveAndRenameFolder
MoveFile
MoveFolder
RecycleFile
RecycleFolder
RemoveGroupFromFolder
RemoveUserFromGroup
RenameFile
RenameFolder
RestoreRecycledFile
SetSiteOutput
UpdateFolderWithMetadata
 
Top To top of page