2017 © Pedro Peláez
 

library mahana-messaging-library-for-codeigniter

CodeIgniter library for internal application messaging

image

jrmadsen67/mahana-messaging-library-for-codeigniter

CodeIgniter library for internal application messaging

  • Monday, October 23, 2017
  • by jrmadsen67
  • Repository
  • 9 Watchers
  • 53 Stars
  • 16 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 31 Forks
  • 6 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Name: Mahana Messaging Library for CodeIgniter, (*1)

Author: Jeff Madsen jrmadsen67@gmail.com http://www.codebyjeff.com, (*2)

Location: - git@github.com:jrmadsen67/Mahana-Messaging-library-for-CodeIgniter.git, (*3)

Description: CI library for linking to application's existing user table and creating basis of an internal messaging system No views or controllers included - DO CHECK the README for setup instructions and notes, (*4)

Welcome to the Mahana Messaging Library for CodeIgniter, (*5)

This library is intended as a starting off point for building an internal messaging system for your CodeIgniter application. It does NOT include any controllers or views. To use this library:, (*6)

1) download from github at the above url, (*7)

2) there are 5 files (not including this README):, (*8)

- mahana.sql  -- run this sql script in your database. Note that these tables are all InnoDB - Mahana uses transactions

- config/mahana.php -- you will need to set up your existing users table information here, following the sample data style

- language/english/mahana_lang.php -- all error and success messages can be changed here, or multilingual support can be added

-- models/mahana_model.php -- the database model

-- libraries/Mahana_messaging -- the main library file

3) from your controller, load the library as either:, (*9)

(Recommended)
$this->load->library('mahana_messaging');
$msg = $this->mahana_messaging->get_message($msg_id, $sender_id);

or

$this->load->library('mahana_messaging');
    $mahana = new Mahana_messaging();
$msg = $mahana->get_message($msg_id, $sender_id);

4) All functions return the array:, (*10)

$status['err']      1= error, 0 = no error
$status['code']     a specific code for that return value, found in config/mahana.php
$status['msg']      a configurable message, found in language/english/mahana_lang.php
$status['retval']   (optional) returned array of data

5) Features, (*11)

Mahana Messaging has a couple of small features you should be aware of:

1) using the config/mahana.php constants USER_TABLE_TABLENAME, USER_TABLE_ID, USER_TABLE_USERNAME you may quickly and easily integrate the messaging library with your exisiting user table

2) all return messages are configurable and can be made multi-lingual

3) return array $status makes for easy conversion to json format for ajax-based systems

4) get_full_thread() and get_all_threads() have a unique parameter - $full_thread. If set to true, a newly added participant to a thread can see all messages dating BEFORE he was added, allowing him to "catch up" on the conversation. Ideal for adding a manager or a new salesperson to a conversation.

Thank you for using Mahana Messaging! Please be sure to leave the author's credits in the library file., (*12)

The Versions

23/10 2017

dev-master

9999999-dev https://github.com/jrmadsen67/Mahana-Messaging-library-for-CodeIgniter

CodeIgniter library for internal application messaging

  Sources   Download

The Requires

  • php >=5.3.0

 

codeigniter messaging