/functions/folder_manip.php

Description

folder_manip.php

Functions for IMAP folder manipulation: (un)subscribe, create, rename, delete.

Functions
folders_checkname (line 23)

Helper function for the functions below; checks if the user entered folder name is valid according to the IMAP standard. If not, it bails out with an error and cleanly terminates the IMAP connection.

void folders_checkname ( $imapConnection,  $folder_name,  $delimiter)
  • $imapConnection
  • $folder_name
  • $delimiter
folders_create (line 51)

Called from folders.php to create a new folder.

  • since: 1.5.1
void folders_create (stream $imapConnection, string $delimiter, string $folder_name, string $subfolder, string $contain_subs)
  • stream $imapConnection: imap connection resource
  • string $delimiter: delimiter
  • string $folder_name: new folder name
  • string $subfolder: folder that stores new folder
  • string $contain_subs: if not empty, creates folder that can store subfolders
folders_delete_ask (line 180)

Presents a confirmation dialog to the user asking whether they're sure they want to delete this folder.

void folders_delete_ask ( $imapConnection,  $folder_name)
  • $imapConnection
  • $folder_name
folders_delete_do (line 213)

Given a folder, moves it to trash (and all subfolders of it too).

void folders_delete_do ( $imapConnection,  $delimiter,  $folder_name)
  • $imapConnection
  • $delimiter
  • $folder_name
folders_rename_do (line 141)

Given an old and new folder name, renames the folder.

void folders_rename_do ( $imapConnection,  $delimiter,  $orig,  $old_name,  $new_name)
  • $imapConnection
  • $delimiter
  • $orig
  • $old_name
  • $new_name
folders_rename_getname (line 88)

Called from folders.php, given a folder name, ask the user what this folder should be renamed to.

void folders_rename_getname ( $imapConnection,  $delimiter,  $old)
  • $imapConnection
  • $delimiter
  • $old
folders_subscribe (line 272)

Given an array of folder_names, subscribes to each of them.

void folders_subscribe ( $imapConnection,  $folder_names)
  • $imapConnection
  • $folder_names
folders_unsubscribe (line 308)

Given a list of folder names, unsubscribes from each of them.

void folders_unsubscribe ( $imapConnection,  $folder_names)
  • $imapConnection
  • $folder_names

Documentation generated on Mon, 13 Jan 2020 04:22:31 +0100 by phpDocumentor 1.4.3