first commit
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
<IfModule authz_core_module>
|
||||
Require all denied
|
||||
</IfModule>
|
||||
<IfModule !authz_core_module>
|
||||
Deny from all
|
||||
</IfModule>
|
||||
Vendored
+6
@@ -0,0 +1,6 @@
|
||||
<IfModule authz_core_module>
|
||||
Require all denied
|
||||
</IfModule>
|
||||
<IfModule !authz_core_module>
|
||||
Deny from all
|
||||
</IfModule>
|
||||
Vendored
+11
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,136 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| AUTO-LOADER
|
||||
| -------------------------------------------------------------------
|
||||
| This file specifies which systems should be loaded by default.
|
||||
|
|
||||
| In order to keep the framework as light-weight as possible only the
|
||||
| absolute minimal resources are loaded by default. For example,
|
||||
| the database is not connected to automatically since no assumption
|
||||
| is made regarding whether you intend to use it. This file lets
|
||||
| you globally define which systems you would like loaded with every
|
||||
| request.
|
||||
|
|
||||
| -------------------------------------------------------------------
|
||||
| Instructions
|
||||
| -------------------------------------------------------------------
|
||||
|
|
||||
| These are the things you can load automatically:
|
||||
|
|
||||
| 1. Packages
|
||||
| 2. Libraries
|
||||
| 3. Drivers
|
||||
| 4. Helper files
|
||||
| 5. Custom config files
|
||||
| 6. Language files
|
||||
| 7. Models
|
||||
|
|
||||
*/
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Packages
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['packages'] = array(APPPATH.'third_party', '/usr/local/shared');
|
||||
|
|
||||
*/
|
||||
$autoload['packages'] = array();
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Libraries
|
||||
| -------------------------------------------------------------------
|
||||
| These are the classes located in system/libraries/ or your
|
||||
| application/libraries/ directory, with the addition of the
|
||||
| 'database' library, which is somewhat of a special case.
|
||||
|
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['libraries'] = array('database', 'email', 'session');
|
||||
|
|
||||
| You can also supply an alternative library name to be assigned
|
||||
| in the controller:
|
||||
|
|
||||
| $autoload['libraries'] = array('user_agent' => 'ua');
|
||||
*/
|
||||
//$autoload['libraries'] = array();
|
||||
$autoload['libraries'] = array('database','session','form_validation');
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Drivers
|
||||
| -------------------------------------------------------------------
|
||||
| These classes are located in system/libraries/ or in your
|
||||
| application/libraries/ directory, but are also placed inside their
|
||||
| own subdirectory and they extend the CI_Driver_Library class. They
|
||||
| offer multiple interchangeable driver options.
|
||||
|
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['drivers'] = array('cache');
|
||||
|
|
||||
| You can also supply an alternative property name to be assigned in
|
||||
| the controller:
|
||||
|
|
||||
| $autoload['drivers'] = array('cache' => 'cch');
|
||||
|
|
||||
*/
|
||||
$autoload['drivers'] = array();
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Helper Files
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['helper'] = array('url', 'file');
|
||||
*/
|
||||
//$autoload['helper'] = array();
|
||||
$autoload['helper'] = array('form','url');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Config files
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['config'] = array('config1', 'config2');
|
||||
|
|
||||
| NOTE: This item is intended for use ONLY if you have created custom
|
||||
| config files. Otherwise, leave it blank.
|
||||
|
|
||||
*/
|
||||
$autoload['config'] = array();
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Language files
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['language'] = array('lang1', 'lang2');
|
||||
|
|
||||
| NOTE: Do not include the "_lang" part of your file. For example
|
||||
| "codeigniter_lang.php" would be referenced as array('codeigniter');
|
||||
|
|
||||
*/
|
||||
$autoload['language'] = array();
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Models
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['model'] = array('first_model', 'second_model');
|
||||
|
|
||||
| You can also supply an alternative model name to be assigned
|
||||
| in the controller:
|
||||
|
|
||||
| $autoload['model'] = array('first_model' => 'first');
|
||||
*/
|
||||
$autoload['model'] = array();
|
||||
@@ -0,0 +1,523 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Base Site URL
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| URL to your CodeIgniter root. Typically this will be your base URL,
|
||||
| WITH a trailing slash:
|
||||
|
|
||||
| http://example.com/
|
||||
|
|
||||
| WARNING: You MUST set this value!
|
||||
|
|
||||
| If it is not set, then CodeIgniter will try guess the protocol and path
|
||||
| your installation, but due to security concerns the hostname will be set
|
||||
| to $_SERVER['SERVER_ADDR'] if available, or localhost otherwise.
|
||||
| The auto-detection mechanism exists only for convenience during
|
||||
| development and MUST NOT be used in production!
|
||||
|
|
||||
| If you need to allow multiple domains, remember that this file is still
|
||||
| a PHP script and you can easily do that on your own.
|
||||
|
|
||||
*/
|
||||
$config['base_url'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Index File
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Typically this will be your index.php file, unless you've renamed it to
|
||||
| something else. If you are using mod_rewrite to remove the page set this
|
||||
| variable so that it is blank.
|
||||
|
|
||||
*/
|
||||
$config['index_page'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| URI PROTOCOL
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This item determines which server global should be used to retrieve the
|
||||
| URI string. The default setting of 'REQUEST_URI' works for most servers.
|
||||
| If your links do not seem to work, try one of the other delicious flavors:
|
||||
|
|
||||
| 'REQUEST_URI' Uses $_SERVER['REQUEST_URI']
|
||||
| 'QUERY_STRING' Uses $_SERVER['QUERY_STRING']
|
||||
| 'PATH_INFO' Uses $_SERVER['PATH_INFO']
|
||||
|
|
||||
| WARNING: If you set this to 'PATH_INFO', URIs will always be URL-decoded!
|
||||
*/
|
||||
$config['uri_protocol'] = 'REQUEST_URI';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| URL suffix
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This option allows you to add a suffix to all URLs generated by CodeIgniter.
|
||||
| For more information please see the user guide:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/urls.html
|
||||
*/
|
||||
$config['url_suffix'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Language
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This determines which set of language files should be used. Make sure
|
||||
| there is an available translation if you intend to use something other
|
||||
| than english.
|
||||
|
|
||||
*/
|
||||
$config['language'] = 'english';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Character Set
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This determines which character set is used by default in various methods
|
||||
| that require a character set to be provided.
|
||||
|
|
||||
| See http://php.net/htmlspecialchars for a list of supported charsets.
|
||||
|
|
||||
*/
|
||||
$config['charset'] = 'UTF-8';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable/Disable System Hooks
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you would like to use the 'hooks' feature you must enable it by
|
||||
| setting this variable to TRUE (boolean). See the user guide for details.
|
||||
|
|
||||
*/
|
||||
$config['enable_hooks'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Class Extension Prefix
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This item allows you to set the filename/classname prefix when extending
|
||||
| native libraries. For more information please see the user guide:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/core_classes.html
|
||||
| https://codeigniter.com/user_guide/general/creating_libraries.html
|
||||
|
|
||||
*/
|
||||
$config['subclass_prefix'] = 'MY_';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Composer auto-loading
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Enabling this setting will tell CodeIgniter to look for a Composer
|
||||
| package auto-loader script in application/vendor/autoload.php.
|
||||
|
|
||||
| $config['composer_autoload'] = TRUE;
|
||||
|
|
||||
| Or if you have your vendor/ directory located somewhere else, you
|
||||
| can opt to set a specific path as well:
|
||||
|
|
||||
| $config['composer_autoload'] = '/path/to/vendor/autoload.php';
|
||||
|
|
||||
| For more information about Composer, please visit http://getcomposer.org/
|
||||
|
|
||||
| Note: This will NOT disable or override the CodeIgniter-specific
|
||||
| autoloading (application/config/autoload.php)
|
||||
*/
|
||||
$config['composer_autoload'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Allowed URL Characters
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This lets you specify which characters are permitted within your URLs.
|
||||
| When someone tries to submit a URL with disallowed characters they will
|
||||
| get a warning message.
|
||||
|
|
||||
| As a security measure you are STRONGLY encouraged to restrict URLs to
|
||||
| as few characters as possible. By default only these are allowed: a-z 0-9~%.:_-
|
||||
|
|
||||
| Leave blank to allow all characters -- but only if you are insane.
|
||||
|
|
||||
| The configured value is actually a regular expression character group
|
||||
| and it will be executed as: ! preg_match('/^[<permitted_uri_chars>]+$/i
|
||||
|
|
||||
| DO NOT CHANGE THIS UNLESS YOU FULLY UNDERSTAND THE REPERCUSSIONS!!
|
||||
|
|
||||
*/
|
||||
$config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable Query Strings
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| By default CodeIgniter uses search-engine friendly segment based URLs:
|
||||
| example.com/who/what/where/
|
||||
|
|
||||
| You can optionally enable standard query string based URLs:
|
||||
| example.com?who=me&what=something&where=here
|
||||
|
|
||||
| Options are: TRUE or FALSE (boolean)
|
||||
|
|
||||
| The other items let you set the query string 'words' that will
|
||||
| invoke your controllers and its functions:
|
||||
| example.com/index.php?c=controller&m=function
|
||||
|
|
||||
| Please note that some of the helpers won't work as expected when
|
||||
| this feature is enabled, since CodeIgniter is designed primarily to
|
||||
| use segment based URLs.
|
||||
|
|
||||
*/
|
||||
$config['enable_query_strings'] = FALSE;
|
||||
$config['controller_trigger'] = 'c';
|
||||
$config['function_trigger'] = 'm';
|
||||
$config['directory_trigger'] = 'd';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Allow $_GET array
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| By default CodeIgniter enables access to the $_GET array. If for some
|
||||
| reason you would like to disable it, set 'allow_get_array' to FALSE.
|
||||
|
|
||||
| WARNING: This feature is DEPRECATED and currently available only
|
||||
| for backwards compatibility purposes!
|
||||
|
|
||||
*/
|
||||
$config['allow_get_array'] = TRUE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Logging Threshold
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| You can enable error logging by setting a threshold over zero. The
|
||||
| threshold determines what gets logged. Threshold options are:
|
||||
|
|
||||
| 0 = Disables logging, Error logging TURNED OFF
|
||||
| 1 = Error Messages (including PHP errors)
|
||||
| 2 = Debug Messages
|
||||
| 3 = Informational Messages
|
||||
| 4 = All Messages
|
||||
|
|
||||
| You can also pass an array with threshold levels to show individual error types
|
||||
|
|
||||
| array(2) = Debug Messages, without Error Messages
|
||||
|
|
||||
| For a live site you'll usually only enable Errors (1) to be logged otherwise
|
||||
| your log files will fill up very fast.
|
||||
|
|
||||
*/
|
||||
$config['log_threshold'] = 0;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Logging Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| application/logs/ directory. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['log_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Log File Extension
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The default filename extension for log files. The default 'php' allows for
|
||||
| protecting the log files via basic scripting, when they are to be stored
|
||||
| under a publicly accessible directory.
|
||||
|
|
||||
| Note: Leaving it blank will default to 'php'.
|
||||
|
|
||||
*/
|
||||
$config['log_file_extension'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Log File Permissions
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The file system permissions to be applied on newly created log files.
|
||||
|
|
||||
| IMPORTANT: This MUST be an integer (no quotes) and you MUST use octal
|
||||
| integer notation (i.e. 0700, 0644, etc.)
|
||||
*/
|
||||
$config['log_file_permissions'] = 0644;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Date Format for Logs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Each item that is logged has an associated date. You can use PHP date
|
||||
| codes to set your own date formatting
|
||||
|
|
||||
*/
|
||||
$config['log_date_format'] = 'Y-m-d H:i:s';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Views Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| application/views/errors/ directory. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['error_views_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cache Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| application/cache/ directory. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['cache_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cache Include Query String
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Whether to take the URL query string into consideration when generating
|
||||
| output cache files. Valid options are:
|
||||
|
|
||||
| FALSE = Disabled
|
||||
| TRUE = Enabled, take all query parameters into account.
|
||||
| Please be aware that this may result in numerous cache
|
||||
| files generated for the same page over and over again.
|
||||
| array('q') = Enabled, but only take into account the specified list
|
||||
| of query parameters.
|
||||
|
|
||||
*/
|
||||
$config['cache_query_string'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Encryption Key
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you use the Encryption class, you must set an encryption key.
|
||||
| See the user guide for more info.
|
||||
|
|
||||
| https://codeigniter.com/user_guide/libraries/encryption.html
|
||||
|
|
||||
*/
|
||||
$config['encryption_key'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Variables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| 'sess_driver'
|
||||
|
|
||||
| The storage driver to use: files, database, redis, memcached
|
||||
|
|
||||
| 'sess_cookie_name'
|
||||
|
|
||||
| The session cookie name, must contain only [0-9a-z_-] characters
|
||||
|
|
||||
| 'sess_expiration'
|
||||
|
|
||||
| The number of SECONDS you want the session to last.
|
||||
| Setting to 0 (zero) means expire when the browser is closed.
|
||||
|
|
||||
| 'sess_save_path'
|
||||
|
|
||||
| The location to save sessions to, driver dependent.
|
||||
|
|
||||
| For the 'files' driver, it's a path to a writable directory.
|
||||
| WARNING: Only absolute paths are supported!
|
||||
|
|
||||
| For the 'database' driver, it's a table name.
|
||||
| Please read up the manual for the format with other session drivers.
|
||||
|
|
||||
| IMPORTANT: You are REQUIRED to set a valid save path!
|
||||
|
|
||||
| 'sess_match_ip'
|
||||
|
|
||||
| Whether to match the user's IP address when reading the session data.
|
||||
|
|
||||
| WARNING: If you're using the database driver, don't forget to update
|
||||
| your session table's PRIMARY KEY when changing this setting.
|
||||
|
|
||||
| 'sess_time_to_update'
|
||||
|
|
||||
| How many seconds between CI regenerating the session ID.
|
||||
|
|
||||
| 'sess_regenerate_destroy'
|
||||
|
|
||||
| Whether to destroy session data associated with the old session ID
|
||||
| when auto-regenerating the session ID. When set to FALSE, the data
|
||||
| will be later deleted by the garbage collector.
|
||||
|
|
||||
| Other session cookie settings are shared with the rest of the application,
|
||||
| except for 'cookie_prefix' and 'cookie_httponly', which are ignored here.
|
||||
|
|
||||
*/
|
||||
$config['sess_driver'] = 'files';
|
||||
$config['sess_cookie_name'] = 'ci_session';
|
||||
$config['sess_expiration'] = 7200;
|
||||
$config['sess_save_path'] = NULL;
|
||||
$config['sess_match_ip'] = FALSE;
|
||||
$config['sess_time_to_update'] = 300;
|
||||
$config['sess_regenerate_destroy'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cookie Related Variables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| 'cookie_prefix' = Set a cookie name prefix if you need to avoid collisions
|
||||
| 'cookie_domain' = Set to .your-domain.com for site-wide cookies
|
||||
| 'cookie_path' = Typically will be a forward slash
|
||||
| 'cookie_secure' = Cookie will only be set if a secure HTTPS connection exists.
|
||||
| 'cookie_httponly' = Cookie will only be accessible via HTTP(S) (no javascript)
|
||||
|
|
||||
| Note: These settings (with the exception of 'cookie_prefix' and
|
||||
| 'cookie_httponly') will also affect sessions.
|
||||
|
|
||||
*/
|
||||
$config['cookie_prefix'] = '';
|
||||
$config['cookie_domain'] = '';
|
||||
$config['cookie_path'] = '/';
|
||||
$config['cookie_secure'] = FALSE;
|
||||
$config['cookie_httponly'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Standardize newlines
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Determines whether to standardize newline characters in input data,
|
||||
| meaning to replace \r\n, \r, \n occurrences with the PHP_EOL value.
|
||||
|
|
||||
| WARNING: This feature is DEPRECATED and currently available only
|
||||
| for backwards compatibility purposes!
|
||||
|
|
||||
*/
|
||||
$config['standardize_newlines'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Global XSS Filtering
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Determines whether the XSS filter is always active when GET, POST or
|
||||
| COOKIE data is encountered
|
||||
|
|
||||
| WARNING: This feature is DEPRECATED and currently available only
|
||||
| for backwards compatibility purposes!
|
||||
|
|
||||
*/
|
||||
$config['global_xss_filtering'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cross Site Request Forgery
|
||||
|--------------------------------------------------------------------------
|
||||
| Enables a CSRF cookie token to be set. When set to TRUE, token will be
|
||||
| checked on a submitted form. If you are accepting user data, it is strongly
|
||||
| recommended CSRF protection be enabled.
|
||||
|
|
||||
| 'csrf_token_name' = The token name
|
||||
| 'csrf_cookie_name' = The cookie name
|
||||
| 'csrf_expire' = The number in seconds the token should expire.
|
||||
| 'csrf_regenerate' = Regenerate token on every submission
|
||||
| 'csrf_exclude_uris' = Array of URIs which ignore CSRF checks
|
||||
*/
|
||||
$config['csrf_protection'] = FALSE;
|
||||
$config['csrf_token_name'] = 'csrf_test_name';
|
||||
$config['csrf_cookie_name'] = 'csrf_cookie_name';
|
||||
$config['csrf_expire'] = 7200;
|
||||
$config['csrf_regenerate'] = TRUE;
|
||||
$config['csrf_exclude_uris'] = array();
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Output Compression
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Enables Gzip output compression for faster page loads. When enabled,
|
||||
| the output class will test whether your server supports Gzip.
|
||||
| Even if it does, however, not all browsers support compression
|
||||
| so enable only if you are reasonably sure your visitors can handle it.
|
||||
|
|
||||
| Only used if zlib.output_compression is turned off in your php.ini.
|
||||
| Please do not use it together with httpd-level output compression.
|
||||
|
|
||||
| VERY IMPORTANT: If you are getting a blank page when compression is enabled it
|
||||
| means you are prematurely outputting something to your browser. It could
|
||||
| even be a line of whitespace at the end of one of your scripts. For
|
||||
| compression to work, nothing can be sent before the output buffer is called
|
||||
| by the output class. Do not 'echo' any values with compression enabled.
|
||||
|
|
||||
*/
|
||||
$config['compress_output'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Master Time Reference
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Options are 'local' or any PHP supported timezone. This preference tells
|
||||
| the system whether to use your server's local time as the master 'now'
|
||||
| reference, or convert it to the configured one timezone. See the 'date
|
||||
| helper' page of the user guide for information regarding date handling.
|
||||
|
|
||||
*/
|
||||
$config['time_reference'] = 'local';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Rewrite PHP Short Tags
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your PHP installation does not have short tag support enabled CI
|
||||
| can rewrite the tags on-the-fly, enabling you to utilize that syntax
|
||||
| in your view files. Options are TRUE or FALSE (boolean)
|
||||
|
|
||||
| Note: You need to have eval() enabled for this to work.
|
||||
|
|
||||
*/
|
||||
$config['rewrite_short_tags'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Reverse Proxy IPs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your server is behind a reverse proxy, you must whitelist the proxy
|
||||
| IP addresses from which CodeIgniter should trust headers such as
|
||||
| HTTP_X_FORWARDED_FOR and HTTP_CLIENT_IP in order to properly identify
|
||||
| the visitor's IP address.
|
||||
|
|
||||
| You can use both an array or a comma-separated list of proxy addresses,
|
||||
| as well as specifying whole subnets. Here are a few examples:
|
||||
|
|
||||
| Comma-separated: '10.0.1.200,192.168.5.0/24'
|
||||
| Array: array('10.0.1.200', '192.168.5.0/24')
|
||||
*/
|
||||
$config['proxy_ips'] = '';
|
||||
@@ -0,0 +1,536 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/* function __autoload($classname) {
|
||||
|
||||
if (strpos($classname, 'CL_') !== 0) {
|
||||
$file = APPPATH . 'libraries/' . $classname . '.php';
|
||||
if (file_exists($file) && is_file($file)) {
|
||||
@include_once($file);
|
||||
}
|
||||
}
|
||||
} */
|
||||
|
||||
spl_autoload_register(function($classname) {
|
||||
if (strpos($classname, 'CL_') !== 0) {
|
||||
$file = APPPATH . 'libraries/' . $classname . '.php';
|
||||
if (file_exists($file) && is_file($file)) {
|
||||
@include_once($file);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Base Site URL
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| URL to your CodeIgniter root. Typically this will be your base URL,
|
||||
| WITH a trailing slash:
|
||||
|
|
||||
| http://example.com/
|
||||
|
|
||||
| WARNING: You MUST set this value!
|
||||
|
|
||||
| If it is not set, then CodeIgniter will try guess the protocol and path
|
||||
| your installation, but due to security concerns the hostname will be set
|
||||
| to $_SERVER['SERVER_ADDR'] if available, or localhost otherwise.
|
||||
| The auto-detection mechanism exists only for convenience during
|
||||
| development and MUST NOT be used in production!
|
||||
|
|
||||
| If you need to allow multiple domains, remember that this file is still
|
||||
| a PHP script and you can easily do that on your own.
|
||||
|
|
||||
*/
|
||||
// load back end here -----
|
||||
//require_once('backend.php');
|
||||
|
||||
|
||||
//$config['base_url'] = $wrenchboard->cfgReadChar("system.base_url"); //'http://oameye.works.wrenchboard.com/';
|
||||
$config['base_url'] = 'https://'.$_SERVER['SERVER_NAME'].'/';
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Index File
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Typically this will be your index.php file, unless you've renamed it to
|
||||
| something else. If you are using mod_rewrite to remove the page set this
|
||||
| variable so that it is blank.
|
||||
|
|
||||
*/
|
||||
$config['index_page'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| URI PROTOCOL
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This item determines which server global should be used to retrieve the
|
||||
| URI string. The default setting of 'REQUEST_URI' works for most servers.
|
||||
| If your links do not seem to work, try one of the other delicious flavors:
|
||||
|
|
||||
| 'REQUEST_URI' Uses $_SERVER['REQUEST_URI']
|
||||
| 'QUERY_STRING' Uses $_SERVER['QUERY_STRING']
|
||||
| 'PATH_INFO' Uses $_SERVER['PATH_INFO']
|
||||
|
|
||||
| WARNING: If you set this to 'PATH_INFO', URIs will always be URL-decoded!
|
||||
*/
|
||||
$config['uri_protocol'] = 'REQUEST_URI';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| URL suffix
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This option allows you to add a suffix to all URLs generated by CodeIgniter.
|
||||
| For more information please see the user guide:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/urls.html
|
||||
*/
|
||||
$config['url_suffix'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Language
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This determines which set of language files should be used. Make sure
|
||||
| there is an available translation if you intend to use something other
|
||||
| than english.
|
||||
|
|
||||
*/
|
||||
$config['language'] = 'english';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Character Set
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This determines which character set is used by default in various methods
|
||||
| that require a character set to be provided.
|
||||
|
|
||||
| See http://php.net/htmlspecialchars for a list of supported charsets.
|
||||
|
|
||||
*/
|
||||
$config['charset'] = 'UTF-8';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable/Disable System Hooks
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you would like to use the 'hooks' feature you must enable it by
|
||||
| setting this variable to TRUE (boolean). See the user guide for details.
|
||||
|
|
||||
*/
|
||||
$config['enable_hooks'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Class Extension Prefix
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This item allows you to set the filename/classname prefix when extending
|
||||
| native libraries. For more information please see the user guide:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/core_classes.html
|
||||
| https://codeigniter.com/user_guide/general/creating_libraries.html
|
||||
|
|
||||
*/
|
||||
//$config['subclass_prefix'] = 'MY_';
|
||||
$config['subclass_prefix'] = 'WRB_';
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Composer auto-loading
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Enabling this setting will tell CodeIgniter to look for a Composer
|
||||
| package auto-loader script in application/vendor/autoload.php.
|
||||
|
|
||||
| $config['composer_autoload'] = TRUE;
|
||||
|
|
||||
| Or if you have your vendor/ directory located somewhere else, you
|
||||
| can opt to set a specific path as well:
|
||||
|
|
||||
| $config['composer_autoload'] = '/path/to/vendor/autoload.php';
|
||||
|
|
||||
| For more information about Composer, please visit http://getcomposer.org/
|
||||
|
|
||||
| Note: This will NOT disable or override the CodeIgniter-specific
|
||||
| autoloading (application/config/autoload.php)
|
||||
*/
|
||||
$config['composer_autoload'] = TRUE; // FALSE; // Tolik
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Allowed URL Characters
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This lets you specify which characters are permitted within your URLs.
|
||||
| When someone tries to submit a URL with disallowed characters they will
|
||||
| get a warning message.
|
||||
|
|
||||
| As a security measure you are STRONGLY encouraged to restrict URLs to
|
||||
| as few characters as possible. By default only these are allowed: a-z 0-9~%.:_-
|
||||
|
|
||||
| Leave blank to allow all characters -- but only if you are insane.
|
||||
|
|
||||
| The configured value is actually a regular expression character group
|
||||
| and it will be executed as: ! preg_match('/^[<permitted_uri_chars>]+$/i
|
||||
|
|
||||
| DO NOT CHANGE THIS UNLESS YOU FULLY UNDERSTAND THE REPERCUSSIONS!!
|
||||
|
|
||||
*/
|
||||
$config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable Query Strings
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| By default CodeIgniter uses search-engine friendly segment based URLs:
|
||||
| example.com/who/what/where/
|
||||
|
|
||||
| By default CodeIgniter enables access to the $_GET array. If for some
|
||||
| reason you would like to disable it, set 'allow_get_array' to FALSE.
|
||||
|
|
||||
| You can optionally enable standard query string based URLs:
|
||||
| example.com?who=me&what=something&where=here
|
||||
|
|
||||
| Options are: TRUE or FALSE (boolean)
|
||||
|
|
||||
| The other items let you set the query string 'words' that will
|
||||
| invoke your controllers and its functions:
|
||||
| example.com/index.php?c=controller&m=function
|
||||
|
|
||||
| Please note that some of the helpers won't work as expected when
|
||||
| this feature is enabled, since CodeIgniter is designed primarily to
|
||||
| use segment based URLs.
|
||||
|
|
||||
*/
|
||||
$config['allow_get_array'] = TRUE;
|
||||
$config['enable_query_strings'] = FALSE;
|
||||
$config['controller_trigger'] = 'c';
|
||||
$config['function_trigger'] = 'm';
|
||||
$config['directory_trigger'] = 'd';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Logging Threshold
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| You can enable error logging by setting a threshold over zero. The
|
||||
| threshold determines what gets logged. Threshold options are:
|
||||
|
|
||||
| 0 = Disables logging, Error logging TURNED OFF
|
||||
| 1 = Error Messages (including PHP errors)
|
||||
| 2 = Debug Messages
|
||||
| 3 = Informational Messages
|
||||
| 4 = All Messages
|
||||
|
|
||||
| You can also pass an array with threshold levels to show individual error types
|
||||
|
|
||||
| array(2) = Debug Messages, without Error Messages
|
||||
|
|
||||
| For a live site you'll usually only enable Errors (1) to be logged otherwise
|
||||
| your log files will fill up very fast.
|
||||
|
|
||||
*/
|
||||
$config['log_threshold'] = 0;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Logging Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| application/logs/ directory. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['log_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Log File Extension
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The default filename extension for log files. The default 'php' allows for
|
||||
| protecting the log files via basic scripting, when they are to be stored
|
||||
| under a publicly accessible directory.
|
||||
|
|
||||
| Note: Leaving it blank will default to 'php'.
|
||||
|
|
||||
*/
|
||||
$config['log_file_extension'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Log File Permissions
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The file system permissions to be applied on newly created log files.
|
||||
|
|
||||
| IMPORTANT: This MUST be an integer (no quotes) and you MUST use octal
|
||||
| integer notation (i.e. 0700, 0644, etc.)
|
||||
*/
|
||||
$config['log_file_permissions'] = 0644;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Date Format for Logs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Each item that is logged has an associated date. You can use PHP date
|
||||
| codes to set your own date formatting
|
||||
|
|
||||
*/
|
||||
$config['log_date_format'] = 'Y-m-d H:i:s';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Views Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| application/views/errors/ directory. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['error_views_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cache Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| application/cache/ directory. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['cache_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cache Include Query String
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Whether to take the URL query string into consideration when generating
|
||||
| output cache files. Valid options are:
|
||||
|
|
||||
| FALSE = Disabled
|
||||
| TRUE = Enabled, take all query parameters into account.
|
||||
| Please be aware that this may result in numerous cache
|
||||
| files generated for the same page over and over again.
|
||||
| array('q') = Enabled, but only take into account the specified list
|
||||
| of query parameters.
|
||||
|
|
||||
*/
|
||||
$config['cache_query_string'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Encryption Key
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you use the Encryption class, you must set an encryption key.
|
||||
| See the user guide for more info.
|
||||
|
|
||||
| https://codeigniter.com/user_guide/libraries/encryption.html
|
||||
|
|
||||
*/
|
||||
$config['encryption_key'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Variables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| 'sess_driver'
|
||||
|
|
||||
| The storage driver to use: files, database, redis, memcached
|
||||
|
|
||||
| 'sess_cookie_name'
|
||||
|
|
||||
| The session cookie name, must contain only [0-9a-z_-] characters
|
||||
|
|
||||
| 'sess_expiration'
|
||||
|
|
||||
| The number of SECONDS you want the session to last.
|
||||
| Setting to 0 (zero) means expire when the browser is closed.
|
||||
|
|
||||
| 'sess_save_path'
|
||||
|
|
||||
| The location to save sessions to, driver dependent.
|
||||
|
|
||||
| For the 'files' driver, it's a path to a writable directory.
|
||||
| WARNING: Only absolute paths are supported!
|
||||
|
|
||||
| For the 'database' driver, it's a table name.
|
||||
| Please read up the manual for the format with other session drivers.
|
||||
|
|
||||
| IMPORTANT: You are REQUIRED to set a valid save path!
|
||||
|
|
||||
| 'sess_match_ip'
|
||||
|
|
||||
| Whether to match the user's IP address when reading the session data.
|
||||
|
|
||||
| WARNING: If you're using the database driver, don't forget to update
|
||||
| your session table's PRIMARY KEY when changing this setting.
|
||||
|
|
||||
| 'sess_time_to_update'
|
||||
|
|
||||
| How many seconds between CI regenerating the session ID.
|
||||
|
|
||||
| 'sess_regenerate_destroy'
|
||||
|
|
||||
| Whether to destroy session data associated with the old session ID
|
||||
| when auto-regenerating the session ID. When set to FALSE, the data
|
||||
| will be later deleted by the garbage collector.
|
||||
|
|
||||
| Other session cookie settings are shared with the rest of the application,
|
||||
| except for 'cookie_prefix' and 'cookie_httponly', which are ignored here.
|
||||
|
|
||||
*/
|
||||
$config['sess_driver'] = 'files';
|
||||
$config['sess_cookie_name'] = 'ci_session';
|
||||
$config['sess_expiration'] = 7200;
|
||||
$config['sess_save_path'] = NULL;
|
||||
$config['sess_match_ip'] = FALSE;
|
||||
$config['sess_time_to_update'] = 300;
|
||||
$config['sess_regenerate_destroy'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cookie Related Variables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| 'cookie_prefix' = Set a cookie name prefix if you need to avoid collisions
|
||||
| 'cookie_domain' = Set to .your-domain.com for site-wide cookies
|
||||
| 'cookie_path' = Typically will be a forward slash
|
||||
| 'cookie_secure' = Cookie will only be set if a secure HTTPS connection exists.
|
||||
| 'cookie_httponly' = Cookie will only be accessible via HTTP(S) (no javascript)
|
||||
|
|
||||
| Note: These settings (with the exception of 'cookie_prefix' and
|
||||
| 'cookie_httponly') will also affect sessions.
|
||||
|
|
||||
*/
|
||||
$config['cookie_prefix'] = '';
|
||||
$config['cookie_domain'] = '';
|
||||
$config['cookie_path'] = '/';
|
||||
$config['cookie_secure'] = FALSE;
|
||||
$config['cookie_httponly'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Standardize newlines
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Determines whether to standardize newline characters in input data,
|
||||
| meaning to replace \r\n, \r, \n occurrences with the PHP_EOL value.
|
||||
|
|
||||
| This is particularly useful for portability between UNIX-based OSes,
|
||||
| (usually \n) and Windows (\r\n).
|
||||
|
|
||||
*/
|
||||
$config['standardize_newlines'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Global XSS Filtering
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Determines whether the XSS filter is always active when GET, POST or
|
||||
| COOKIE data is encountered
|
||||
|
|
||||
| WARNING: This feature is DEPRECATED and currently available only
|
||||
| for backwards compatibility purposes!
|
||||
|
|
||||
*/
|
||||
$config['global_xss_filtering'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cross Site Request Forgery
|
||||
|--------------------------------------------------------------------------
|
||||
| Enables a CSRF cookie token to be set. When set to TRUE, token will be
|
||||
| checked on a submitted form. If you are accepting user data, it is strongly
|
||||
| recommended CSRF protection be enabled.
|
||||
|
|
||||
| 'csrf_token_name' = The token name
|
||||
| 'csrf_cookie_name' = The cookie name
|
||||
| 'csrf_expire' = The number in seconds the token should expire.
|
||||
| 'csrf_regenerate' = Regenerate token on every submission
|
||||
| 'csrf_exclude_uris' = Array of URIs which ignore CSRF checks
|
||||
*/
|
||||
$config['csrf_protection'] = FALSE;
|
||||
$config['csrf_token_name'] = 'csrf_test_name';
|
||||
$config['csrf_cookie_name'] = 'csrf_cookie_name';
|
||||
$config['csrf_expire'] = 7200;
|
||||
$config['csrf_regenerate'] = TRUE;
|
||||
$config['csrf_exclude_uris'] = array();
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Output Compression
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Enables Gzip output compression for faster page loads. When enabled,
|
||||
| the output class will test whether your server supports Gzip.
|
||||
| Even if it does, however, not all browsers support compression
|
||||
| so enable only if you are reasonably sure your visitors can handle it.
|
||||
|
|
||||
| Only used if zlib.output_compression is turned off in your php.ini.
|
||||
| Please do not use it together with httpd-level output compression.
|
||||
|
|
||||
| VERY IMPORTANT: If you are getting a blank page when compression is enabled it
|
||||
| means you are prematurely outputting something to your browser. It could
|
||||
| even be a line of whitespace at the end of one of your scripts. For
|
||||
| compression to work, nothing can be sent before the output buffer is called
|
||||
| by the output class. Do not 'echo' any values with compression enabled.
|
||||
|
|
||||
*/
|
||||
$config['compress_output'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Master Time Reference
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Options are 'local' or any PHP supported timezone. This preference tells
|
||||
| the system whether to use your server's local time as the master 'now'
|
||||
| reference, or convert it to the configured one timezone. See the 'date
|
||||
| helper' page of the user guide for information regarding date handling.
|
||||
|
|
||||
*/
|
||||
$config['time_reference'] = 'local';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Rewrite PHP Short Tags
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your PHP installation does not have short tag support enabled CI
|
||||
| can rewrite the tags on-the-fly, enabling you to utilize that syntax
|
||||
| in your view files. Options are TRUE or FALSE (boolean)
|
||||
|
|
||||
| Note: You need to have eval() enabled for this to work.
|
||||
|
|
||||
*/
|
||||
$config['rewrite_short_tags'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Reverse Proxy IPs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your server is behind a reverse proxy, you must whitelist the proxy
|
||||
| IP addresses from which CodeIgniter should trust headers such as
|
||||
| HTTP_X_FORWARDED_FOR and HTTP_CLIENT_IP in order to properly identify
|
||||
| the visitor's IP address.
|
||||
|
|
||||
| You can use both an array or a comma-separated list of proxy addresses,
|
||||
| as well as specifying whole subnets. Here are a few examples:
|
||||
|
|
||||
| Comma-separated: '10.0.1.200,192.168.5.0/24'
|
||||
| Array: array('10.0.1.200', '192.168.5.0/24')
|
||||
*/
|
||||
$config['proxy_ips'] = '';
|
||||
@@ -0,0 +1,271 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Display Debug backtrace
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If set to TRUE, a backtrace will be displayed along with php errors. If
|
||||
| error_reporting is disabled, the backtrace will not display, regardless
|
||||
| of this setting
|
||||
|
|
||||
*/
|
||||
defined('SHOW_DEBUG_BACKTRACE') OR define('SHOW_DEBUG_BACKTRACE', TRUE);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| File and Directory Modes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| These prefs are used when checking and setting modes when working
|
||||
| with the file system. The defaults are fine on servers with proper
|
||||
| security, but you may wish (or even need) to change the values in
|
||||
| certain environments (Apache running a separate process for each
|
||||
| user, PHP under CGI with Apache suEXEC, etc.). Octal values should
|
||||
| always be used to set the mode correctly.
|
||||
|
|
||||
*/
|
||||
defined('FILE_READ_MODE') OR define('FILE_READ_MODE', 0644);
|
||||
defined('FILE_WRITE_MODE') OR define('FILE_WRITE_MODE', 0666);
|
||||
defined('DIR_READ_MODE') OR define('DIR_READ_MODE', 0755);
|
||||
defined('DIR_WRITE_MODE') OR define('DIR_WRITE_MODE', 0755);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| File Stream Modes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| These modes are used when working with fopen()/popen()
|
||||
|
|
||||
*/
|
||||
defined('FOPEN_READ') OR define('FOPEN_READ', 'rb');
|
||||
defined('FOPEN_READ_WRITE') OR define('FOPEN_READ_WRITE', 'r+b');
|
||||
defined('FOPEN_WRITE_CREATE_DESTRUCTIVE') OR define('FOPEN_WRITE_CREATE_DESTRUCTIVE', 'wb'); // truncates existing file data, use with care
|
||||
defined('FOPEN_READ_WRITE_CREATE_DESTRUCTIVE') OR define('FOPEN_READ_WRITE_CREATE_DESTRUCTIVE', 'w+b'); // truncates existing file data, use with care
|
||||
defined('FOPEN_WRITE_CREATE') OR define('FOPEN_WRITE_CREATE', 'ab');
|
||||
defined('FOPEN_READ_WRITE_CREATE') OR define('FOPEN_READ_WRITE_CREATE', 'a+b');
|
||||
defined('FOPEN_WRITE_CREATE_STRICT') OR define('FOPEN_WRITE_CREATE_STRICT', 'xb');
|
||||
defined('FOPEN_READ_WRITE_CREATE_STRICT') OR define('FOPEN_READ_WRITE_CREATE_STRICT', 'x+b');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Exit Status Codes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Used to indicate the conditions under which the script is exit()ing.
|
||||
| While there is no universal standard for error codes, there are some
|
||||
| broad conventions. Three such conventions are mentioned below, for
|
||||
| those who wish to make use of them. The CodeIgniter defaults were
|
||||
| chosen for the least overlap with these conventions, while still
|
||||
| leaving room for others to be defined in future versions and user
|
||||
| applications.
|
||||
|
|
||||
| The three main conventions used for determining exit status codes
|
||||
| are as follows:
|
||||
|
|
||||
| Standard C/C++ Library (stdlibc):
|
||||
| http://www.gnu.org/software/libc/manual/html_node/Exit-Status.html
|
||||
| (This link also contains other GNU-specific conventions)
|
||||
| BSD sysexits.h:
|
||||
| http://www.gsp.com/cgi-bin/man.cgi?section=3&topic=sysexits
|
||||
| Bash scripting:
|
||||
| http://tldp.org/LDP/abs/html/exitcodes.html
|
||||
|
|
||||
*/
|
||||
defined('EXIT_SUCCESS') OR define('EXIT_SUCCESS', 0); // no errors
|
||||
defined('EXIT_ERROR') OR define('EXIT_ERROR', 1); // generic error
|
||||
defined('EXIT_CONFIG') OR define('EXIT_CONFIG', 3); // configuration error
|
||||
defined('EXIT_UNKNOWN_FILE') OR define('EXIT_UNKNOWN_FILE', 4); // file not found
|
||||
defined('EXIT_UNKNOWN_CLASS') OR define('EXIT_UNKNOWN_CLASS', 5); // unknown class
|
||||
defined('EXIT_UNKNOWN_METHOD') OR define('EXIT_UNKNOWN_METHOD', 6); // unknown class member
|
||||
defined('EXIT_USER_INPUT') OR define('EXIT_USER_INPUT', 7); // invalid user input
|
||||
defined('EXIT_DATABASE') OR define('EXIT_DATABASE', 8); // database error
|
||||
defined('EXIT__AUTO_MIN') OR define('EXIT__AUTO_MIN', 9); // lowest automatically-assigned error code
|
||||
defined('EXIT__AUTO_MAX') OR define('EXIT__AUTO_MAX', 125); // highest automatically-assigned error code
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
define('PHP_API_OK', 0);
|
||||
define('PHP_LOGIN_OK', 100);
|
||||
define('PHP_CREATED_OK', 10);
|
||||
define('PHP_API_BAD_PARAM', -1);
|
||||
define('SESSION_TIMEOUT_LOGOUT',72000);
|
||||
|
||||
define('SUPPORT_PHONE','+234 (818)-3866434');
|
||||
|
||||
define('UPLOAD_FILE_SIZE',1);
|
||||
|
||||
define('OFFER_ACCEPT',100);
|
||||
define('OFFER_REJECT',333);
|
||||
define('OFFER_CANCEL',222);
|
||||
define('OFFER_EXPIRE',444);
|
||||
|
||||
define('OFFER_SENDTOME',777);
|
||||
|
||||
|
||||
define('JOB_INTEREST_ACCEPT',100);
|
||||
define('JOB_INTEREST_REJECT',200);
|
||||
define('JOB_INTEREST_CANCEL',300);
|
||||
|
||||
define('SMONEY_PROCC_MANUAL',100);
|
||||
define('SMONEY_PROCC_AUTO',200);
|
||||
define('SMONEY_PROCC_INTERSWITCH',300);
|
||||
|
||||
define('ACCOUNT_AGREE_JOBS',100);
|
||||
define('ACCOUNT_AGREE_REFER',200);
|
||||
|
||||
|
||||
define('WRENCHBOARD_SESSION_CHECK', 299);
|
||||
define('WRENCHBOARD_USER_LOGIN', 300);
|
||||
define('WRENCHBOARD_USER_LOGOUT', 301);
|
||||
define('WRENCHBOARD_CREATE_ACCOUNT', 320);
|
||||
|
||||
define('CONTRACT_CANCEL_CONTRACT', 7);
|
||||
define('CONTRACT_EXTEND_TIMELINE', 9);
|
||||
define('CONTRACT_NOTIFY_COMPLETE', 4);
|
||||
define('CONTRACT_REQUEST_CANCEL', 3);
|
||||
define('CONTRACT_ACCEPT_COMPLETE', 5);
|
||||
define('CONTRACT_REJECT_COMPLETE', 1);
|
||||
|
||||
|
||||
//**************************************************************
|
||||
define('WRENCHBOARD_BKO_START', 10000);
|
||||
|
||||
define('WRENCHBOARD_BKO_LOGIN', 10010);
|
||||
define('WRENCHBOARD_BKO_CREATEUSER', 10015);
|
||||
define('WRENCHBOARD_BKO_UPDATEUSER', 10020);
|
||||
|
||||
define('WRENCHBOARD_BKO_END', 10999);
|
||||
//**************************************************************
|
||||
define('WRENCHBOARD_ACCOUNT_START', 11000);
|
||||
|
||||
define('WRENCHBOARD_ACCOUNT_TESTEMAIL', 11001);
|
||||
define('WRENCHBOARD_ACCOUNT_PENDING', 11010);
|
||||
define('WRENCHBOARD_VERIFY_PENDING_LINK', 11015);
|
||||
define('WRENCHBOARD_ACCOUNT_RESETPASS', 11016);
|
||||
define('WRENCHBOARD_ACCOUNT_SETPASSWD', 11017);
|
||||
|
||||
define('WRENCHBOARD_DELETE_PENDING_LINK', 11018);
|
||||
define('WRENCHBOARD_RESEND_PENDING_LINK', 11019);
|
||||
|
||||
|
||||
define('WRENCHBOARD_ACCOUNT_CREATEACC', 11020);
|
||||
define('WRENCHBOARD_ACCOUNT_LOGIN', 11025);
|
||||
define('WRENCHBOARD_FACEBOOK_LOGIN', 11026);
|
||||
define('WRENCHBOARD_SEND_CONTACTUS', 11030);
|
||||
define('WRENCHBOARD_ACCOUNT_SENDREFER',11032);
|
||||
define('WRENCHBOARD_ACCOUNT_REFERLINK',11033);
|
||||
define('WRENCHBOARD_SESSION_VERIFY', 11034);
|
||||
define('WRENCHBOARD_UPDATE_PROFILE',11035);
|
||||
define('WRENCHBOARD_ACCOUNT_TERMS',11036);
|
||||
define('WRENCHBOARD_ACCOUNT_MDESCRIPTION',11037);
|
||||
define('WRENCHBOARD_ACCOUNT_SAVESKILL', 11038);
|
||||
define('WRENCHBOARD_ACCOUNT_DELSKILL', 11039);
|
||||
define('WRENCHBOARD_LOG_MEMBER', 11040);
|
||||
|
||||
define('WRENCHBOARD_DELETE_RECACC', 11041);
|
||||
define('WRENCHBOARD_SAVE_GALLERY', 11042);
|
||||
|
||||
define('WRENCHBOARD_ACCOUNT_END', 11999);
|
||||
//**************************************************************
|
||||
define('WRENCHBOARD_JOB_CREATEJOB',13010 );
|
||||
define('WRENCHBOARD_JOB_DELETEJOB',13011 );
|
||||
|
||||
define('WRENCHBOARD_JOB_GROUP_MEMBER', 13015) ;
|
||||
define('WRENCHBOARD_JOB_DELETE_GROUPMEMBER',13017);
|
||||
define('WRENCHBOARD_JOB_CREATE_GROUP', 13020);
|
||||
define('WRENCHBOARD_JOB_DELETE_GROUP',13023);
|
||||
|
||||
define('WRENCHBOARD_JOB_OFFER_INDVI',13030);
|
||||
define('WRENCHBOARD_JOB_OFFER_GROUP',13031);
|
||||
define('WRENCHBOARD_JOB_OFFER_PUBLIC',13032);
|
||||
define('WRENCHBOARD_JOB_SEND_INTEREST',13033);
|
||||
define('WRENCHBOARD_JOB_PROC_INTEREST',13034);
|
||||
define('WRENCHBOARD_JOB_OFFER_CONCLUDE',13035);
|
||||
define('WRENCHBOARD_JOB_SEND_QUESTION',13036);
|
||||
define('WRENCHBOARD_JOB_MRKTINT_QUEST',13037);
|
||||
define('WRENCHBOARD_JOB_REPLY_QUESTION',13038);
|
||||
|
||||
|
||||
define('WRENCHBOARD_GROUP_START', 12000);
|
||||
|
||||
|
||||
define('WRENCHBOARD_GROUP_CREATEGROUP', 12010);
|
||||
define('WRENCHBOARD_GROUP_INVITEGROUP', 12015);
|
||||
define('WRENCHBOARD_GROUP_ACCEPTGROUP', 12020);
|
||||
|
||||
define('WRENCHBOARD_GROUP_END', 12999);
|
||||
//**************************************************************
|
||||
|
||||
define('WRENCHBOARD_CONTRACT_MESSAGE', 14010);
|
||||
define('WRENCHBOARD_CONTRACT_STATUS', 14015);
|
||||
|
||||
define('WRENCHBOARD_SMONEY_ADDRECIPIENT', 33010);
|
||||
define('WRENCHBOARD_SMONEY_MEMBER', 33020);
|
||||
define('WRENCHBOARD_SMONEY_PROCFEE', 33025);
|
||||
|
||||
define('WRENCHBOARD_SMONEY_BKOPROC', 33030 );
|
||||
|
||||
|
||||
define('WRENCHBOARD_LOGIN_SHOP', 50501);
|
||||
define('WRENCHBOARD_LOGIN_ADMIN', 50502);
|
||||
define('WRENCHBOARD_LOGIN_MANAGER', 50503);
|
||||
|
||||
define('WRENCHBOARD_SURVEY_DATA', 55000);
|
||||
define('WRENCHBOARD_ADD_SURVEY', 55050);
|
||||
define('WRENCHBOARD_LOAD_SURVEY', 55055);
|
||||
|
||||
|
||||
define('WRENCHBOARD_COMPLETE_SENDMONEY_INTERSW', 555);
|
||||
define('WRENCHBOARD_GETBILLER_INTERSW', 556);
|
||||
define('WRENCHBOARD_BILL_PAYMENT_ADVICE_INTERSW', 557);
|
||||
|
||||
define('WRENCHBOARD_INTERSW_GETBILLER', 556);
|
||||
define('WRENCHBOARD_INTERSW_BILL_PAYMENT_ADVICE', 557);
|
||||
define('WRENCHBOARD_INTERSW_GETBILLERPAYMENTINTEMS', 558);
|
||||
define('WRENCHBOARD_INTERSW_GETBILLERCATEGORIES', 559);
|
||||
define('WRENCHBOARD_INTERSW_DO_TRANSFER', 560);
|
||||
define('WRENCHBOARD_INTERSW_QUERY_TRANSACTION', 561);
|
||||
|
||||
define('WRENCHBOARD_ADD_MONEYRECIPIENT', 600);
|
||||
|
||||
define('WRENCHBOARD_CREATE_USER_ACCOUNT', 700);
|
||||
define('WRENCHBOARD_USER_ACCOUNT_LOGIN', 710);
|
||||
define('WRENCHBOARD_START_PASSWORDRESET', 720);
|
||||
define('WRENCHBOARD_COMPLETE_PASSWORDRESET', 730);
|
||||
|
||||
//#define WRENCHBOARD_START_ADDMONEY', 770 );
|
||||
//#define WRENCHBOARD_COMPLETE_ADDMONEY' 775 );
|
||||
|
||||
define('WRENCHBOARD_ADD_MOBILE_TOPUPNUM', 900);
|
||||
define('WRENCHBOARD_PROMO_CALL', 990);
|
||||
|
||||
|
||||
define('WRENCHBOARD_STOREFACE_GET_ACCOUNT_BALANCE', 891);
|
||||
|
||||
define('WRENCHBOARD_LOG_ENTRY', 900000);
|
||||
define('WRENCHBOARD_CREDIT_TOPUP', 900010);
|
||||
|
||||
define('WRENCHBOARD_TOPUP_ORDER', 900020);
|
||||
define('WRENCHBOARD_TOPUP_ORDER_PURCHASE', 900030);
|
||||
define('WRENCHBOARD_PAYPAL_IPNMSG', 900090);
|
||||
|
||||
define('WRENCHBOARD_BULKTOPUP_ORDER', 700010);
|
||||
define('WRENCHBOARD_BULKTOPUP_ITEM', 700020);
|
||||
define('WRENCHBOARD_BULKTOPUP_ITEMUPDATE', 700030);
|
||||
define('WRENCHBOARD_BULKTOPUP_DELIVER', 700040);
|
||||
|
||||
define('WRENCHBOARD_BALANCE_TOPUP_ORDER', 800020);
|
||||
define('WRENCHBOARD_BALANCE_TOPUP_PURCHASE', 800030);
|
||||
define('WRENCHBOARD_BALANCE_TOPUP_PAYMENT', 800040);
|
||||
|
||||
define('VIRTUAL_AIRTOPUP', 70011);
|
||||
define('PAY_MODE_BALANCE', 0);
|
||||
define('PAY_MODE_CCARD', 1);
|
||||
define('PAY_MODE_BONUS', 9);
|
||||
define('APPROVED_BALANCE', 5);
|
||||
define('DISAPROVE_BALANCE', 3);
|
||||
|
||||
@@ -0,0 +1,109 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| DATABASE CONNECTIVITY SETTINGS
|
||||
| -------------------------------------------------------------------
|
||||
| This file will contain the settings needed to access your database.
|
||||
|
|
||||
| For complete instructions please consult the 'Database Connection'
|
||||
| page of the User Guide.
|
||||
|
|
||||
| -------------------------------------------------------------------
|
||||
| EXPLANATION OF VARIABLES
|
||||
| -------------------------------------------------------------------
|
||||
|
|
||||
| ['dsn'] The full DSN string describe a connection to the database.
|
||||
| ['hostname'] The hostname of your database server.
|
||||
| ['username'] The username used to connect to the database
|
||||
| ['password'] The password used to connect to the database
|
||||
| ['database'] The name of the database you want to connect to
|
||||
| ['dbdriver'] The database driver. e.g.: mysqli.
|
||||
| Currently supported:
|
||||
| cubrid, ibase, mssql, mysql, mysqli, oci8,
|
||||
| odbc, pdo, postgre, sqlite, sqlite3, sqlsrv
|
||||
| ['dbprefix'] You can add an optional prefix, which will be added
|
||||
| to the table name when using the Query Builder class
|
||||
| ['pconnect'] TRUE/FALSE - Whether to use a persistent connection
|
||||
| ['db_debug'] TRUE/FALSE - Whether database errors should be displayed.
|
||||
| ['cache_on'] TRUE/FALSE - Enables/disables query caching
|
||||
| ['cachedir'] The path to the folder where cache files should be stored
|
||||
| ['char_set'] The character set used in communicating with the database
|
||||
| ['dbcollat'] The character collation used in communicating with the database
|
||||
| NOTE: For MySQL and MySQLi databases, this setting is only used
|
||||
| as a backup if your server is running PHP < 5.2.3 or MySQL < 5.0.7
|
||||
| (and in table creation queries made with DB Forge).
|
||||
| There is an incompatibility in PHP with mysql_real_escape_string() which
|
||||
| can make your site vulnerable to SQL injection if you are using a
|
||||
| multi-byte character set and are running versions lower than these.
|
||||
| Sites using Latin-1 or UTF-8 database character set and collation are unaffected.
|
||||
| ['swap_pre'] A default table prefix that should be swapped with the dbprefix
|
||||
| ['encrypt'] Whether or not to use an encrypted connection.
|
||||
|
|
||||
| 'mysql' (deprecated), 'sqlsrv' and 'pdo/sqlsrv' drivers accept TRUE/FALSE
|
||||
| 'mysqli' and 'pdo/mysql' drivers accept an array with the following options:
|
||||
|
|
||||
| 'ssl_key' - Path to the private key file
|
||||
| 'ssl_cert' - Path to the public key certificate file
|
||||
| 'ssl_ca' - Path to the certificate authority file
|
||||
| 'ssl_capath' - Path to a directory containing trusted CA certificats in PEM format
|
||||
| 'ssl_cipher' - List of *allowed* ciphers to be used for the encryption, separated by colons (':')
|
||||
| 'ssl_verify' - TRUE/FALSE; Whether verify the server certificate or not ('mysqli' only)
|
||||
|
|
||||
| ['compress'] Whether or not to use client compression (MySQL only)
|
||||
| ['stricton'] TRUE/FALSE - forces 'Strict Mode' connections
|
||||
| - good for ensuring strict SQL while developing
|
||||
| ['ssl_options'] Used to set various SSL options that can be used when making SSL connections.
|
||||
| ['failover'] array - A array with 0 or more data for connections if the main should fail.
|
||||
| ['save_queries'] TRUE/FALSE - Whether to "save" all executed queries.
|
||||
| NOTE: Disabling this will also effectively disable both
|
||||
| $this->db->last_query() and profiling of DB queries.
|
||||
| When you run a query, with this setting set to TRUE (default),
|
||||
| CodeIgniter will store the SQL statement for debugging purposes.
|
||||
| However, this may cause high memory usage, especially if you run
|
||||
| a lot of SQL queries ... disable this to avoid that problem.
|
||||
|
|
||||
| The $active_group variable lets you choose which connection group to
|
||||
| make active. By default there is only one group (the 'default' group).
|
||||
|
|
||||
| The $query_builder variables lets you determine whether or not to load
|
||||
| the query builder class.
|
||||
*/
|
||||
$active_group = 'default';
|
||||
$query_builder = TRUE;
|
||||
|
||||
// load back end here -----
|
||||
require_once('backend.php');
|
||||
|
||||
$show_database_error = true;
|
||||
$is_live = $wrenchboard->cfgReadChar("system.live");
|
||||
if ($is_live == false) {
|
||||
$show_database_error = false;
|
||||
}
|
||||
|
||||
|
||||
$db['default'] = array(
|
||||
'dsn' => '',
|
||||
'hostname' => $wrenchboard->cfgReadChar("database.host"),
|
||||
'username' => $wrenchboard->cfgReadChar("database.user"),
|
||||
'password' => $wrenchboard->cfgReadChar("database.pass"),
|
||||
'database' => $wrenchboard->cfgReadChar("database.name"),
|
||||
'dbdriver' => 'postgre',
|
||||
'dbprefix' => '',
|
||||
'pconnect' => FALSE,
|
||||
'db_debug' => $show_database_error,
|
||||
'db_debug2' => (ENVIRONMENT !== 'production'),
|
||||
'cache_on' => FALSE,
|
||||
'cachedir' => '',
|
||||
'char_set' => 'utf8',
|
||||
'dbcollat' => 'utf8_general_ci',
|
||||
'swap_pre' => '',
|
||||
'encrypt' => FALSE,
|
||||
'compress' => FALSE,
|
||||
'stricton' => FALSE,
|
||||
'failover' => array(),
|
||||
'save_queries' => TRUE
|
||||
);
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
$_doctypes = array(
|
||||
'xhtml11' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">',
|
||||
'xhtml1-strict' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">',
|
||||
'xhtml1-trans' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">',
|
||||
'xhtml1-frame' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">',
|
||||
'xhtml-basic11' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.1//EN" "http://www.w3.org/TR/xhtml-basic/xhtml-basic11.dtd">',
|
||||
'html5' => '<!DOCTYPE html>',
|
||||
'html4-strict' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">',
|
||||
'html4-trans' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">',
|
||||
'html4-frame' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">',
|
||||
'mathml1' => '<!DOCTYPE math SYSTEM "http://www.w3.org/Math/DTD/mathml1/mathml.dtd">',
|
||||
'mathml2' => '<!DOCTYPE math PUBLIC "-//W3C//DTD MathML 2.0//EN" "http://www.w3.org/Math/DTD/mathml2/mathml2.dtd">',
|
||||
'svg10' => '<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">',
|
||||
'svg11' => '<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">',
|
||||
'svg11-basic' => '<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Basic//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-basic.dtd">',
|
||||
'svg11-tiny' => '<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Tiny//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-tiny.dtd">',
|
||||
'xhtml-math-svg-xh' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN" "http://www.w3.org/2002/04/xhtml-math-svg/xhtml-math-svg.dtd">',
|
||||
'xhtml-math-svg-sh' => '<!DOCTYPE svg:svg PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN" "http://www.w3.org/2002/04/xhtml-math-svg/xhtml-math-svg.dtd">',
|
||||
'xhtml-rdfa-1' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd">',
|
||||
'xhtml-rdfa-2' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.1//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-2.dtd">'
|
||||
);
|
||||
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Facebook App details
|
||||
| -------------------------------------------------------------------
|
||||
|
|
||||
| To get an facebook app details you have to be a registered developer
|
||||
| at http://developer.facebook.com and create an app for your project.
|
||||
|
|
||||
| facebook_app_id string Your facebook app ID.
|
||||
| facebook_app_secret string Your facebook app secret.
|
||||
| facebook_login_type string Set login type. (web, js, canvas)
|
||||
| facebook_login_redirect_url string URL tor redirect back to after login. Do not include domain.
|
||||
| facebook_logout_redirect_url string URL tor redirect back to after login. Do not include domain.
|
||||
| facebook_permissions array The permissions you need.
|
||||
| facebook_graph_version string Set Facebook Graph version to be used. Eg v2.6
|
||||
| facebook_auth_on_load boolean Set to TRUE to have the library to check for valid access token on every page load.
|
||||
*/
|
||||
$config['facebook_app_id'] = '390204307987009';
|
||||
$config['facebook_app_secret'] = '19f778e312f2ab96d147bacb612910c2';
|
||||
$config['facebook_default_scope'] = 'email,public_profile';
|
||||
$config['facebook_login_type'] = 'web';
|
||||
$config['facebook_login_redirect_url'] = 'login';
|
||||
$config['facebook_logout_redirect_url'] = 'login/logout';
|
||||
$config['facebook_permissions'] = array('public_profile', 'email');
|
||||
$config['facebook_graph_version'] = 'v2.2';
|
||||
$config['facebook_auth_on_load'] = TRUE;
|
||||
|
||||
@@ -0,0 +1,103 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Foreign Characters
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains an array of foreign characters for transliteration
|
||||
| conversion used by the Text helper
|
||||
|
|
||||
*/
|
||||
$foreign_characters = array(
|
||||
'/ä|æ|ǽ/' => 'ae',
|
||||
'/ö|œ/' => 'oe',
|
||||
'/ü/' => 'ue',
|
||||
'/Ä/' => 'Ae',
|
||||
'/Ü/' => 'Ue',
|
||||
'/Ö/' => 'Oe',
|
||||
'/À|Á|Â|Ã|Ä|Å|Ǻ|Ā|Ă|Ą|Ǎ|Α|Ά|Ả|Ạ|Ầ|Ẫ|Ẩ|Ậ|Ằ|Ắ|Ẵ|Ẳ|Ặ|А/' => 'A',
|
||||
'/à|á|â|ã|å|ǻ|ā|ă|ą|ǎ|ª|α|ά|ả|ạ|ầ|ấ|ẫ|ẩ|ậ|ằ|ắ|ẵ|ẳ|ặ|а/' => 'a',
|
||||
'/Б/' => 'B',
|
||||
'/б/' => 'b',
|
||||
'/Ç|Ć|Ĉ|Ċ|Č/' => 'C',
|
||||
'/ç|ć|ĉ|ċ|č/' => 'c',
|
||||
'/Д/' => 'D',
|
||||
'/д/' => 'd',
|
||||
'/Ð|Ď|Đ|Δ/' => 'Dj',
|
||||
'/ð|ď|đ|δ/' => 'dj',
|
||||
'/È|É|Ê|Ë|Ē|Ĕ|Ė|Ę|Ě|Ε|Έ|Ẽ|Ẻ|Ẹ|Ề|Ế|Ễ|Ể|Ệ|Е|Э/' => 'E',
|
||||
'/è|é|ê|ë|ē|ĕ|ė|ę|ě|έ|ε|ẽ|ẻ|ẹ|ề|ế|ễ|ể|ệ|е|э/' => 'e',
|
||||
'/Ф/' => 'F',
|
||||
'/ф/' => 'f',
|
||||
'/Ĝ|Ğ|Ġ|Ģ|Γ|Г|Ґ/' => 'G',
|
||||
'/ĝ|ğ|ġ|ģ|γ|г|ґ/' => 'g',
|
||||
'/Ĥ|Ħ/' => 'H',
|
||||
'/ĥ|ħ/' => 'h',
|
||||
'/Ì|Í|Î|Ï|Ĩ|Ī|Ĭ|Ǐ|Į|İ|Η|Ή|Ί|Ι|Ϊ|Ỉ|Ị|И|Ы/' => 'I',
|
||||
'/ì|í|î|ï|ĩ|ī|ĭ|ǐ|į|ı|η|ή|ί|ι|ϊ|ỉ|ị|и|ы|ї/' => 'i',
|
||||
'/Ĵ/' => 'J',
|
||||
'/ĵ/' => 'j',
|
||||
'/Ķ|Κ|К/' => 'K',
|
||||
'/ķ|κ|к/' => 'k',
|
||||
'/Ĺ|Ļ|Ľ|Ŀ|Ł|Λ|Л/' => 'L',
|
||||
'/ĺ|ļ|ľ|ŀ|ł|λ|л/' => 'l',
|
||||
'/М/' => 'M',
|
||||
'/м/' => 'm',
|
||||
'/Ñ|Ń|Ņ|Ň|Ν|Н/' => 'N',
|
||||
'/ñ|ń|ņ|ň|ʼn|ν|н/' => 'n',
|
||||
'/Ò|Ó|Ô|Õ|Ō|Ŏ|Ǒ|Ő|Ơ|Ø|Ǿ|Ο|Ό|Ω|Ώ|Ỏ|Ọ|Ồ|Ố|Ỗ|Ổ|Ộ|Ờ|Ớ|Ỡ|Ở|Ợ|О/' => 'O',
|
||||
'/ò|ó|ô|õ|ō|ŏ|ǒ|ő|ơ|ø|ǿ|º|ο|ό|ω|ώ|ỏ|ọ|ồ|ố|ỗ|ổ|ộ|ờ|ớ|ỡ|ở|ợ|о/' => 'o',
|
||||
'/П/' => 'P',
|
||||
'/п/' => 'p',
|
||||
'/Ŕ|Ŗ|Ř|Ρ|Р/' => 'R',
|
||||
'/ŕ|ŗ|ř|ρ|р/' => 'r',
|
||||
'/Ś|Ŝ|Ş|Ș|Š|Σ|С/' => 'S',
|
||||
'/ś|ŝ|ş|ș|š|ſ|σ|ς|с/' => 's',
|
||||
'/Ț|Ţ|Ť|Ŧ|τ|Т/' => 'T',
|
||||
'/ț|ţ|ť|ŧ|т/' => 't',
|
||||
'/Þ|þ/' => 'th',
|
||||
'/Ù|Ú|Û|Ũ|Ū|Ŭ|Ů|Ű|Ų|Ư|Ǔ|Ǖ|Ǘ|Ǚ|Ǜ|Ũ|Ủ|Ụ|Ừ|Ứ|Ữ|Ử|Ự|У/' => 'U',
|
||||
'/ù|ú|û|ũ|ū|ŭ|ů|ű|ų|ư|ǔ|ǖ|ǘ|ǚ|ǜ|υ|ύ|ϋ|ủ|ụ|ừ|ứ|ữ|ử|ự|у/' => 'u',
|
||||
'/Ý|Ÿ|Ŷ|Υ|Ύ|Ϋ|Ỳ|Ỹ|Ỷ|Ỵ|Й/' => 'Y',
|
||||
'/ý|ÿ|ŷ|ỳ|ỹ|ỷ|ỵ|й/' => 'y',
|
||||
'/В/' => 'V',
|
||||
'/в/' => 'v',
|
||||
'/Ŵ/' => 'W',
|
||||
'/ŵ/' => 'w',
|
||||
'/Ź|Ż|Ž|Ζ|З/' => 'Z',
|
||||
'/ź|ż|ž|ζ|з/' => 'z',
|
||||
'/Æ|Ǽ/' => 'AE',
|
||||
'/ß/' => 'ss',
|
||||
'/IJ/' => 'IJ',
|
||||
'/ij/' => 'ij',
|
||||
'/Œ/' => 'OE',
|
||||
'/ƒ/' => 'f',
|
||||
'/ξ/' => 'ks',
|
||||
'/π/' => 'p',
|
||||
'/β/' => 'v',
|
||||
'/μ/' => 'm',
|
||||
'/ψ/' => 'ps',
|
||||
'/Ё/' => 'Yo',
|
||||
'/ё/' => 'yo',
|
||||
'/Є/' => 'Ye',
|
||||
'/є/' => 'ye',
|
||||
'/Ї/' => 'Yi',
|
||||
'/Ж/' => 'Zh',
|
||||
'/ж/' => 'zh',
|
||||
'/Х/' => 'Kh',
|
||||
'/х/' => 'kh',
|
||||
'/Ц/' => 'Ts',
|
||||
'/ц/' => 'ts',
|
||||
'/Ч/' => 'Ch',
|
||||
'/ч/' => 'ch',
|
||||
'/Ш/' => 'Sh',
|
||||
'/ш/' => 'sh',
|
||||
'/Щ/' => 'Shch',
|
||||
'/щ/' => 'shch',
|
||||
'/Ъ|ъ|Ь|ь/' => '',
|
||||
'/Ю/' => 'Yu',
|
||||
'/ю/' => 'yu',
|
||||
'/Я/' => 'Ya',
|
||||
'/я/' => 'ya'
|
||||
);
|
||||
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| Hooks
|
||||
| -------------------------------------------------------------------------
|
||||
| This file lets you define "hooks" to extend CI without hacking the core
|
||||
| files. Please see the user guide for info:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/hooks.html
|
||||
|
|
||||
*/
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| Memcached settings
|
||||
| -------------------------------------------------------------------------
|
||||
| Your Memcached servers can be specified below.
|
||||
|
|
||||
| See: https://codeigniter.com/user_guide/libraries/caching.html#memcached
|
||||
|
|
||||
*/
|
||||
$config = array(
|
||||
'default' => array(
|
||||
'hostname' => '127.0.0.1',
|
||||
'port' => '11211',
|
||||
'weight' => '1',
|
||||
),
|
||||
);
|
||||
@@ -0,0 +1,84 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable/Disable Migrations
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Migrations are disabled by default for security reasons.
|
||||
| You should enable migrations whenever you intend to do a schema migration
|
||||
| and disable it back when you're done.
|
||||
|
|
||||
*/
|
||||
$config['migration_enabled'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migration Type
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Migration file names may be based on a sequential identifier or on
|
||||
| a timestamp. Options are:
|
||||
|
|
||||
| 'sequential' = Sequential migration naming (001_add_blog.php)
|
||||
| 'timestamp' = Timestamp migration naming (20121031104401_add_blog.php)
|
||||
| Use timestamp format YYYYMMDDHHIISS.
|
||||
|
|
||||
| Note: If this configuration value is missing the Migration library
|
||||
| defaults to 'sequential' for backward compatibility with CI2.
|
||||
|
|
||||
*/
|
||||
$config['migration_type'] = 'timestamp';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migrations table
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This is the name of the table that will store the current migrations state.
|
||||
| When migrations runs it will store in a database table which migration
|
||||
| level the system is at. It then compares the migration level in this
|
||||
| table to the $config['migration_version'] if they are not the same it
|
||||
| will migrate up. This must be set.
|
||||
|
|
||||
*/
|
||||
$config['migration_table'] = 'migrations';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Auto Migrate To Latest
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If this is set to TRUE when you load the migrations class and have
|
||||
| $config['migration_enabled'] set to TRUE the system will auto migrate
|
||||
| to your latest migration (whatever $config['migration_version'] is
|
||||
| set to). This way you do not have to call migrations anywhere else
|
||||
| in your code to have the latest migration.
|
||||
|
|
||||
*/
|
||||
$config['migration_auto_latest'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migrations version
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This is used to set migration version that the file system should be on.
|
||||
| If you run $this->migration->current() this is the version that schema will
|
||||
| be upgraded / downgraded to.
|
||||
|
|
||||
*/
|
||||
$config['migration_version'] = 0;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migrations Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Path to your migrations folder.
|
||||
| Typically, it will be within your application path.
|
||||
| Also, writing permission is required within the migrations path.
|
||||
|
|
||||
*/
|
||||
$config['migration_path'] = APPPATH.'migrations/';
|
||||
@@ -0,0 +1,167 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| MIME TYPES
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains an array of mime types. It is used by the
|
||||
| Upload class to help identify allowed file types.
|
||||
|
|
||||
*/
|
||||
return array(
|
||||
'hqx' => array('application/mac-binhex40', 'application/mac-binhex', 'application/x-binhex40', 'application/x-mac-binhex40'),
|
||||
'cpt' => 'application/mac-compactpro',
|
||||
'csv' => array('text/x-comma-separated-values', 'text/comma-separated-values', 'application/octet-stream', 'application/vnd.ms-excel', 'application/x-csv', 'text/x-csv', 'text/csv', 'application/csv', 'application/excel', 'application/vnd.msexcel', 'text/plain'),
|
||||
'bin' => array('application/macbinary', 'application/mac-binary', 'application/octet-stream', 'application/x-binary', 'application/x-macbinary'),
|
||||
'dms' => 'application/octet-stream',
|
||||
'lha' => 'application/octet-stream',
|
||||
'lzh' => 'application/octet-stream',
|
||||
'exe' => array('application/octet-stream', 'application/x-msdownload'),
|
||||
'class' => 'application/octet-stream',
|
||||
'psd' => array('application/x-photoshop', 'image/vnd.adobe.photoshop'),
|
||||
'so' => 'application/octet-stream',
|
||||
'sea' => 'application/octet-stream',
|
||||
'dll' => 'application/octet-stream',
|
||||
'oda' => 'application/oda',
|
||||
'pdf' => array('application/pdf', 'application/force-download', 'application/x-download', 'binary/octet-stream'),
|
||||
'ai' => array('application/pdf', 'application/postscript'),
|
||||
'eps' => 'application/postscript',
|
||||
'ps' => 'application/postscript',
|
||||
'smi' => 'application/smil',
|
||||
'smil' => 'application/smil',
|
||||
'mif' => 'application/vnd.mif',
|
||||
'xls' => array('application/vnd.ms-excel', 'application/msexcel', 'application/x-msexcel', 'application/x-ms-excel', 'application/x-excel', 'application/x-dos_ms_excel', 'application/xls', 'application/x-xls', 'application/excel', 'application/download', 'application/vnd.ms-office', 'application/msword'),
|
||||
'ppt' => array('application/powerpoint', 'application/vnd.ms-powerpoint', 'application/vnd.ms-office', 'application/msword'),
|
||||
'pptx' => array('application/vnd.openxmlformats-officedocument.presentationml.presentation', 'application/x-zip', 'application/zip'),
|
||||
'wbxml' => 'application/wbxml',
|
||||
'wmlc' => 'application/wmlc',
|
||||
'dcr' => 'application/x-director',
|
||||
'dir' => 'application/x-director',
|
||||
'dxr' => 'application/x-director',
|
||||
'dvi' => 'application/x-dvi',
|
||||
'gtar' => 'application/x-gtar',
|
||||
'gz' => 'application/x-gzip',
|
||||
'gzip' => 'application/x-gzip',
|
||||
'php' => array('application/x-httpd-php', 'application/php', 'application/x-php', 'text/php', 'text/x-php', 'application/x-httpd-php-source'),
|
||||
'php4' => 'application/x-httpd-php',
|
||||
'php3' => 'application/x-httpd-php',
|
||||
'phtml' => 'application/x-httpd-php',
|
||||
'phps' => 'application/x-httpd-php-source',
|
||||
'js' => array('application/x-javascript', 'text/plain'),
|
||||
'swf' => 'application/x-shockwave-flash',
|
||||
'sit' => 'application/x-stuffit',
|
||||
'tar' => 'application/x-tar',
|
||||
'tgz' => array('application/x-tar', 'application/x-gzip-compressed'),
|
||||
'z' => 'application/x-compress',
|
||||
'xhtml' => 'application/xhtml+xml',
|
||||
'xht' => 'application/xhtml+xml',
|
||||
'zip' => array('application/x-zip', 'application/zip', 'application/x-zip-compressed', 'application/s-compressed', 'multipart/x-zip'),
|
||||
'rar' => array('application/x-rar', 'application/rar', 'application/x-rar-compressed'),
|
||||
'mid' => 'audio/midi',
|
||||
'midi' => 'audio/midi',
|
||||
'mpga' => 'audio/mpeg',
|
||||
'mp2' => 'audio/mpeg',
|
||||
'mp3' => array('audio/mpeg', 'audio/mpg', 'audio/mpeg3', 'audio/mp3'),
|
||||
'aif' => array('audio/x-aiff', 'audio/aiff'),
|
||||
'aiff' => array('audio/x-aiff', 'audio/aiff'),
|
||||
'aifc' => 'audio/x-aiff',
|
||||
'ram' => 'audio/x-pn-realaudio',
|
||||
'rm' => 'audio/x-pn-realaudio',
|
||||
'rpm' => 'audio/x-pn-realaudio-plugin',
|
||||
'ra' => 'audio/x-realaudio',
|
||||
'rv' => 'video/vnd.rn-realvideo',
|
||||
'wav' => array('audio/x-wav', 'audio/wave', 'audio/wav'),
|
||||
'bmp' => array('image/bmp', 'image/x-bmp', 'image/x-bitmap', 'image/x-xbitmap', 'image/x-win-bitmap', 'image/x-windows-bmp', 'image/ms-bmp', 'image/x-ms-bmp', 'application/bmp', 'application/x-bmp', 'application/x-win-bitmap'),
|
||||
'gif' => 'image/gif',
|
||||
'jpeg' => array('image/jpeg', 'image/pjpeg'),
|
||||
'jpg' => array('image/jpeg', 'image/pjpeg'),
|
||||
'jpe' => array('image/jpeg', 'image/pjpeg'),
|
||||
'jp2' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'j2k' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'jpf' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'jpg2' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'jpx' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'jpm' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'mj2' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'mjp2' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'png' => array('image/png', 'image/x-png'),
|
||||
'tiff' => 'image/tiff',
|
||||
'tif' => 'image/tiff',
|
||||
'css' => array('text/css', 'text/plain'),
|
||||
'html' => array('text/html', 'text/plain'),
|
||||
'htm' => array('text/html', 'text/plain'),
|
||||
'shtml' => array('text/html', 'text/plain'),
|
||||
'txt' => 'text/plain',
|
||||
'text' => 'text/plain',
|
||||
'log' => array('text/plain', 'text/x-log'),
|
||||
'rtx' => 'text/richtext',
|
||||
'rtf' => 'text/rtf',
|
||||
'xml' => array('application/xml', 'text/xml', 'text/plain'),
|
||||
'xsl' => array('application/xml', 'text/xsl', 'text/xml'),
|
||||
'mpeg' => 'video/mpeg',
|
||||
'mpg' => 'video/mpeg',
|
||||
'mpe' => 'video/mpeg',
|
||||
'qt' => 'video/quicktime',
|
||||
'mov' => 'video/quicktime',
|
||||
'avi' => array('video/x-msvideo', 'video/msvideo', 'video/avi', 'application/x-troff-msvideo'),
|
||||
'movie' => 'video/x-sgi-movie',
|
||||
'doc' => array('application/msword', 'application/vnd.ms-office'),
|
||||
'docx' => array('application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'application/zip', 'application/msword', 'application/x-zip'),
|
||||
'dot' => array('application/msword', 'application/vnd.ms-office'),
|
||||
'dotx' => array('application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'application/zip', 'application/msword'),
|
||||
'xlsx' => array('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'application/zip', 'application/vnd.ms-excel', 'application/msword', 'application/x-zip'),
|
||||
'word' => array('application/msword', 'application/octet-stream'),
|
||||
'xl' => 'application/excel',
|
||||
'eml' => 'message/rfc822',
|
||||
'json' => array('application/json', 'text/json'),
|
||||
'pem' => array('application/x-x509-user-cert', 'application/x-pem-file', 'application/octet-stream'),
|
||||
'p10' => array('application/x-pkcs10', 'application/pkcs10'),
|
||||
'p12' => 'application/x-pkcs12',
|
||||
'p7a' => 'application/x-pkcs7-signature',
|
||||
'p7c' => array('application/pkcs7-mime', 'application/x-pkcs7-mime'),
|
||||
'p7m' => array('application/pkcs7-mime', 'application/x-pkcs7-mime'),
|
||||
'p7r' => 'application/x-pkcs7-certreqresp',
|
||||
'p7s' => 'application/pkcs7-signature',
|
||||
'crt' => array('application/x-x509-ca-cert', 'application/x-x509-user-cert', 'application/pkix-cert'),
|
||||
'crl' => array('application/pkix-crl', 'application/pkcs-crl'),
|
||||
'der' => 'application/x-x509-ca-cert',
|
||||
'kdb' => 'application/octet-stream',
|
||||
'pgp' => 'application/pgp',
|
||||
'gpg' => 'application/gpg-keys',
|
||||
'sst' => 'application/octet-stream',
|
||||
'csr' => 'application/octet-stream',
|
||||
'rsa' => 'application/x-pkcs7',
|
||||
'cer' => array('application/pkix-cert', 'application/x-x509-ca-cert'),
|
||||
'3g2' => 'video/3gpp2',
|
||||
'3gp' => array('video/3gp', 'video/3gpp'),
|
||||
'mp4' => 'video/mp4',
|
||||
'm4a' => 'audio/x-m4a',
|
||||
'f4v' => array('video/mp4', 'video/x-f4v'),
|
||||
'flv' => 'video/x-flv',
|
||||
'webm' => 'video/webm',
|
||||
'aac' => 'audio/x-acc',
|
||||
'm4u' => 'application/vnd.mpegurl',
|
||||
'm3u' => 'text/plain',
|
||||
'xspf' => 'application/xspf+xml',
|
||||
'vlc' => 'application/videolan',
|
||||
'wmv' => array('video/x-ms-wmv', 'video/x-ms-asf'),
|
||||
'au' => 'audio/x-au',
|
||||
'ac3' => 'audio/ac3',
|
||||
'flac' => 'audio/x-flac',
|
||||
'ogg' => array('audio/ogg', 'video/ogg', 'application/ogg'),
|
||||
'kmz' => array('application/vnd.google-earth.kmz', 'application/zip', 'application/x-zip'),
|
||||
'kml' => array('application/vnd.google-earth.kml+xml', 'application/xml', 'text/xml'),
|
||||
'ics' => 'text/calendar',
|
||||
'ical' => 'text/calendar',
|
||||
'zsh' => 'text/x-scriptzsh',
|
||||
'7zip' => array('application/x-compressed', 'application/x-zip-compressed', 'application/zip', 'multipart/x-zip'),
|
||||
'cdr' => array('application/cdr', 'application/coreldraw', 'application/x-cdr', 'application/x-coreldraw', 'image/cdr', 'image/x-cdr', 'zz-application/zz-winassoc-cdr'),
|
||||
'wma' => array('audio/x-ms-wma', 'video/x-ms-asf'),
|
||||
'jar' => array('application/java-archive', 'application/x-java-application', 'application/x-jar', 'application/x-compressed'),
|
||||
'svg' => array('image/svg+xml', 'application/xml', 'text/xml'),
|
||||
'vcf' => 'text/x-vcard',
|
||||
'srt' => array('text/srt', 'text/plain'),
|
||||
'vtt' => array('text/vtt', 'text/plain'),
|
||||
'ico' => array('image/x-icon', 'image/x-ico', 'image/vnd.microsoft.icon')
|
||||
);
|
||||
@@ -0,0 +1,14 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| Profiler Sections
|
||||
| -------------------------------------------------------------------------
|
||||
| This file lets you determine whether or not various sections of Profiler
|
||||
| data are displayed when the Profiler is enabled.
|
||||
| Please see the user guide for info:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/profiling.html
|
||||
|
|
||||
*/
|
||||
@@ -0,0 +1,55 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| URI ROUTING
|
||||
| -------------------------------------------------------------------------
|
||||
| This file lets you re-map URI requests to specific controller functions.
|
||||
|
|
||||
| Typically there is a one-to-one relationship between a URL string
|
||||
| and its corresponding controller class/method. The segments in a
|
||||
| URL normally follow this pattern:
|
||||
|
|
||||
| example.com/class/method/id/
|
||||
|
|
||||
| In some instances, however, you may want to remap this relationship
|
||||
| so that a different class/function is called than the one
|
||||
| corresponding to the URL.
|
||||
|
|
||||
| Please see the user guide for complete details:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/routing.html
|
||||
|
|
||||
| -------------------------------------------------------------------------
|
||||
| RESERVED ROUTES
|
||||
| -------------------------------------------------------------------------
|
||||
|
|
||||
| There are three reserved routes:
|
||||
|
|
||||
| $route['default_controller'] = 'welcome';
|
||||
|
|
||||
| This route indicates which controller class should be loaded if the
|
||||
| URI contains no data. In the above example, the "welcome" class
|
||||
| would be loaded.
|
||||
|
|
||||
| $route['404_override'] = 'errors/page_missing';
|
||||
|
|
||||
| This route will tell the Router which controller/method to use if those
|
||||
| provided in the URL cannot be matched to a valid route.
|
||||
|
|
||||
| $route['translate_uri_dashes'] = FALSE;
|
||||
|
|
||||
| This is not exactly a route, but allows you to automatically route
|
||||
| controller and method names that contain dashes. '-' isn't a valid
|
||||
| class or method name character, so it requires translation.
|
||||
| When you set this option to TRUE, it will replace ALL dashes in the
|
||||
| controller and method URI segments.
|
||||
|
|
||||
| Examples: my-controller/index -> my_controller/index
|
||||
| my-controller/my-method -> my_controller/my_method
|
||||
*/
|
||||
$route['default_controller'] = 'site';
|
||||
$route['404_override'] = 'Wrb404';
|
||||
$route['translate_uri_dashes'] = FALSE;
|
||||
|
||||
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| SMILEYS
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains an array of smileys for use with the emoticon helper.
|
||||
| Individual images can be used to replace multiple smileys. For example:
|
||||
| :-) and :) use the same image replacement.
|
||||
|
|
||||
| Please see user guide for more info:
|
||||
| https://codeigniter.com/user_guide/helpers/smiley_helper.html
|
||||
|
|
||||
*/
|
||||
$smileys = array(
|
||||
|
||||
// smiley image name width height alt
|
||||
|
||||
':-)' => array('grin.gif', '19', '19', 'grin'),
|
||||
':lol:' => array('lol.gif', '19', '19', 'LOL'),
|
||||
':cheese:' => array('cheese.gif', '19', '19', 'cheese'),
|
||||
':)' => array('smile.gif', '19', '19', 'smile'),
|
||||
';-)' => array('wink.gif', '19', '19', 'wink'),
|
||||
';)' => array('wink.gif', '19', '19', 'wink'),
|
||||
':smirk:' => array('smirk.gif', '19', '19', 'smirk'),
|
||||
':roll:' => array('rolleyes.gif', '19', '19', 'rolleyes'),
|
||||
':-S' => array('confused.gif', '19', '19', 'confused'),
|
||||
':wow:' => array('surprise.gif', '19', '19', 'surprised'),
|
||||
':bug:' => array('bigsurprise.gif', '19', '19', 'big surprise'),
|
||||
':-P' => array('tongue_laugh.gif', '19', '19', 'tongue laugh'),
|
||||
'%-P' => array('tongue_rolleye.gif', '19', '19', 'tongue rolleye'),
|
||||
';-P' => array('tongue_wink.gif', '19', '19', 'tongue wink'),
|
||||
':P' => array('raspberry.gif', '19', '19', 'raspberry'),
|
||||
':blank:' => array('blank.gif', '19', '19', 'blank stare'),
|
||||
':long:' => array('longface.gif', '19', '19', 'long face'),
|
||||
':ohh:' => array('ohh.gif', '19', '19', 'ohh'),
|
||||
':grrr:' => array('grrr.gif', '19', '19', 'grrr'),
|
||||
':gulp:' => array('gulp.gif', '19', '19', 'gulp'),
|
||||
'8-/' => array('ohoh.gif', '19', '19', 'oh oh'),
|
||||
':down:' => array('downer.gif', '19', '19', 'downer'),
|
||||
':red:' => array('embarrassed.gif', '19', '19', 'red face'),
|
||||
':sick:' => array('sick.gif', '19', '19', 'sick'),
|
||||
':shut:' => array('shuteye.gif', '19', '19', 'shut eye'),
|
||||
':-/' => array('hmm.gif', '19', '19', 'hmmm'),
|
||||
'>:(' => array('mad.gif', '19', '19', 'mad'),
|
||||
':mad:' => array('mad.gif', '19', '19', 'mad'),
|
||||
'>:-(' => array('angry.gif', '19', '19', 'angry'),
|
||||
':angry:' => array('angry.gif', '19', '19', 'angry'),
|
||||
':zip:' => array('zip.gif', '19', '19', 'zipper'),
|
||||
':kiss:' => array('kiss.gif', '19', '19', 'kiss'),
|
||||
':ahhh:' => array('shock.gif', '19', '19', 'shock'),
|
||||
':coolsmile:' => array('shade_smile.gif', '19', '19', 'cool smile'),
|
||||
':coolsmirk:' => array('shade_smirk.gif', '19', '19', 'cool smirk'),
|
||||
':coolgrin:' => array('shade_grin.gif', '19', '19', 'cool grin'),
|
||||
':coolhmm:' => array('shade_hmm.gif', '19', '19', 'cool hmm'),
|
||||
':coolmad:' => array('shade_mad.gif', '19', '19', 'cool mad'),
|
||||
':coolcheese:' => array('shade_cheese.gif', '19', '19', 'cool cheese'),
|
||||
':vampire:' => array('vampire.gif', '19', '19', 'vampire'),
|
||||
':snake:' => array('snake.gif', '19', '19', 'snake'),
|
||||
':exclaim:' => array('exclaim.gif', '19', '19', 'exclaim'),
|
||||
':question:' => array('question.gif', '19', '19', 'question')
|
||||
|
||||
);
|
||||
@@ -0,0 +1,214 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| USER AGENT TYPES
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains four arrays of user agent data. It is used by the
|
||||
| User Agent Class to help identify browser, platform, robot, and
|
||||
| mobile device data. The array keys are used to identify the device
|
||||
| and the array values are used to set the actual name of the item.
|
||||
*/
|
||||
$platforms = array(
|
||||
'windows nt 10.0' => 'Windows 10',
|
||||
'windows nt 6.3' => 'Windows 8.1',
|
||||
'windows nt 6.2' => 'Windows 8',
|
||||
'windows nt 6.1' => 'Windows 7',
|
||||
'windows nt 6.0' => 'Windows Vista',
|
||||
'windows nt 5.2' => 'Windows 2003',
|
||||
'windows nt 5.1' => 'Windows XP',
|
||||
'windows nt 5.0' => 'Windows 2000',
|
||||
'windows nt 4.0' => 'Windows NT 4.0',
|
||||
'winnt4.0' => 'Windows NT 4.0',
|
||||
'winnt 4.0' => 'Windows NT',
|
||||
'winnt' => 'Windows NT',
|
||||
'windows 98' => 'Windows 98',
|
||||
'win98' => 'Windows 98',
|
||||
'windows 95' => 'Windows 95',
|
||||
'win95' => 'Windows 95',
|
||||
'windows phone' => 'Windows Phone',
|
||||
'windows' => 'Unknown Windows OS',
|
||||
'android' => 'Android',
|
||||
'blackberry' => 'BlackBerry',
|
||||
'iphone' => 'iOS',
|
||||
'ipad' => 'iOS',
|
||||
'ipod' => 'iOS',
|
||||
'os x' => 'Mac OS X',
|
||||
'ppc mac' => 'Power PC Mac',
|
||||
'freebsd' => 'FreeBSD',
|
||||
'ppc' => 'Macintosh',
|
||||
'linux' => 'Linux',
|
||||
'debian' => 'Debian',
|
||||
'sunos' => 'Sun Solaris',
|
||||
'beos' => 'BeOS',
|
||||
'apachebench' => 'ApacheBench',
|
||||
'aix' => 'AIX',
|
||||
'irix' => 'Irix',
|
||||
'osf' => 'DEC OSF',
|
||||
'hp-ux' => 'HP-UX',
|
||||
'netbsd' => 'NetBSD',
|
||||
'bsdi' => 'BSDi',
|
||||
'openbsd' => 'OpenBSD',
|
||||
'gnu' => 'GNU/Linux',
|
||||
'unix' => 'Unknown Unix OS',
|
||||
'symbian' => 'Symbian OS'
|
||||
);
|
||||
|
||||
|
||||
// The order of this array should NOT be changed. Many browsers return
|
||||
// multiple browser types so we want to identify the sub-type first.
|
||||
$browsers = array(
|
||||
'OPR' => 'Opera',
|
||||
'Flock' => 'Flock',
|
||||
'Edge' => 'Spartan',
|
||||
'Chrome' => 'Chrome',
|
||||
// Opera 10+ always reports Opera/9.80 and appends Version/<real version> to the user agent string
|
||||
'Opera.*?Version' => 'Opera',
|
||||
'Opera' => 'Opera',
|
||||
'MSIE' => 'Internet Explorer',
|
||||
'Internet Explorer' => 'Internet Explorer',
|
||||
'Trident.* rv' => 'Internet Explorer',
|
||||
'Shiira' => 'Shiira',
|
||||
'Firefox' => 'Firefox',
|
||||
'Chimera' => 'Chimera',
|
||||
'Phoenix' => 'Phoenix',
|
||||
'Firebird' => 'Firebird',
|
||||
'Camino' => 'Camino',
|
||||
'Netscape' => 'Netscape',
|
||||
'OmniWeb' => 'OmniWeb',
|
||||
'Safari' => 'Safari',
|
||||
'Mozilla' => 'Mozilla',
|
||||
'Konqueror' => 'Konqueror',
|
||||
'icab' => 'iCab',
|
||||
'Lynx' => 'Lynx',
|
||||
'Links' => 'Links',
|
||||
'hotjava' => 'HotJava',
|
||||
'amaya' => 'Amaya',
|
||||
'IBrowse' => 'IBrowse',
|
||||
'Maxthon' => 'Maxthon',
|
||||
'Ubuntu' => 'Ubuntu Web Browser'
|
||||
);
|
||||
|
||||
$mobiles = array(
|
||||
// legacy array, old values commented out
|
||||
'mobileexplorer' => 'Mobile Explorer',
|
||||
// 'openwave' => 'Open Wave',
|
||||
// 'opera mini' => 'Opera Mini',
|
||||
// 'operamini' => 'Opera Mini',
|
||||
// 'elaine' => 'Palm',
|
||||
'palmsource' => 'Palm',
|
||||
// 'digital paths' => 'Palm',
|
||||
// 'avantgo' => 'Avantgo',
|
||||
// 'xiino' => 'Xiino',
|
||||
'palmscape' => 'Palmscape',
|
||||
// 'nokia' => 'Nokia',
|
||||
// 'ericsson' => 'Ericsson',
|
||||
// 'blackberry' => 'BlackBerry',
|
||||
// 'motorola' => 'Motorola'
|
||||
|
||||
// Phones and Manufacturers
|
||||
'motorola' => 'Motorola',
|
||||
'nokia' => 'Nokia',
|
||||
'palm' => 'Palm',
|
||||
'iphone' => 'Apple iPhone',
|
||||
'ipad' => 'iPad',
|
||||
'ipod' => 'Apple iPod Touch',
|
||||
'sony' => 'Sony Ericsson',
|
||||
'ericsson' => 'Sony Ericsson',
|
||||
'blackberry' => 'BlackBerry',
|
||||
'cocoon' => 'O2 Cocoon',
|
||||
'blazer' => 'Treo',
|
||||
'lg' => 'LG',
|
||||
'amoi' => 'Amoi',
|
||||
'xda' => 'XDA',
|
||||
'mda' => 'MDA',
|
||||
'vario' => 'Vario',
|
||||
'htc' => 'HTC',
|
||||
'samsung' => 'Samsung',
|
||||
'sharp' => 'Sharp',
|
||||
'sie-' => 'Siemens',
|
||||
'alcatel' => 'Alcatel',
|
||||
'benq' => 'BenQ',
|
||||
'ipaq' => 'HP iPaq',
|
||||
'mot-' => 'Motorola',
|
||||
'playstation portable' => 'PlayStation Portable',
|
||||
'playstation 3' => 'PlayStation 3',
|
||||
'playstation vita' => 'PlayStation Vita',
|
||||
'hiptop' => 'Danger Hiptop',
|
||||
'nec-' => 'NEC',
|
||||
'panasonic' => 'Panasonic',
|
||||
'philips' => 'Philips',
|
||||
'sagem' => 'Sagem',
|
||||
'sanyo' => 'Sanyo',
|
||||
'spv' => 'SPV',
|
||||
'zte' => 'ZTE',
|
||||
'sendo' => 'Sendo',
|
||||
'nintendo dsi' => 'Nintendo DSi',
|
||||
'nintendo ds' => 'Nintendo DS',
|
||||
'nintendo 3ds' => 'Nintendo 3DS',
|
||||
'wii' => 'Nintendo Wii',
|
||||
'open web' => 'Open Web',
|
||||
'openweb' => 'OpenWeb',
|
||||
|
||||
// Operating Systems
|
||||
'android' => 'Android',
|
||||
'symbian' => 'Symbian',
|
||||
'SymbianOS' => 'SymbianOS',
|
||||
'elaine' => 'Palm',
|
||||
'series60' => 'Symbian S60',
|
||||
'windows ce' => 'Windows CE',
|
||||
|
||||
// Browsers
|
||||
'obigo' => 'Obigo',
|
||||
'netfront' => 'Netfront Browser',
|
||||
'openwave' => 'Openwave Browser',
|
||||
'mobilexplorer' => 'Mobile Explorer',
|
||||
'operamini' => 'Opera Mini',
|
||||
'opera mini' => 'Opera Mini',
|
||||
'opera mobi' => 'Opera Mobile',
|
||||
'fennec' => 'Firefox Mobile',
|
||||
|
||||
// Other
|
||||
'digital paths' => 'Digital Paths',
|
||||
'avantgo' => 'AvantGo',
|
||||
'xiino' => 'Xiino',
|
||||
'novarra' => 'Novarra Transcoder',
|
||||
'vodafone' => 'Vodafone',
|
||||
'docomo' => 'NTT DoCoMo',
|
||||
'o2' => 'O2',
|
||||
|
||||
// Fallback
|
||||
'mobile' => 'Generic Mobile',
|
||||
'wireless' => 'Generic Mobile',
|
||||
'j2me' => 'Generic Mobile',
|
||||
'midp' => 'Generic Mobile',
|
||||
'cldc' => 'Generic Mobile',
|
||||
'up.link' => 'Generic Mobile',
|
||||
'up.browser' => 'Generic Mobile',
|
||||
'smartphone' => 'Generic Mobile',
|
||||
'cellphone' => 'Generic Mobile'
|
||||
);
|
||||
|
||||
// There are hundreds of bots but these are the most common.
|
||||
$robots = array(
|
||||
'googlebot' => 'Googlebot',
|
||||
'msnbot' => 'MSNBot',
|
||||
'baiduspider' => 'Baiduspider',
|
||||
'bingbot' => 'Bing',
|
||||
'slurp' => 'Inktomi Slurp',
|
||||
'yahoo' => 'Yahoo',
|
||||
'ask jeeves' => 'Ask Jeeves',
|
||||
'fastcrawler' => 'FastCrawler',
|
||||
'infoseek' => 'InfoSeek Robot 1.0',
|
||||
'lycos' => 'Lycos',
|
||||
'yandex' => 'YandexBot',
|
||||
'mediapartners-google' => 'MediaPartners Google',
|
||||
'CRAZYWEBCRAWLER' => 'Crazy Webcrawler',
|
||||
'adsbot-google' => 'AdsBot Google',
|
||||
'feedfetcher-google' => 'Feedfetcher Google',
|
||||
'curious george' => 'Curious George',
|
||||
'ia_archiver' => 'Alexa Crawler',
|
||||
'MJ12bot' => 'Majestic-12',
|
||||
'Uptimebot' => 'Uptimebot'
|
||||
);
|
||||
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
class About extends WRB_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
$data['title'] = "About"; // Capitalize the first letter
|
||||
$data['page_title'] = "About WrenchBoard";
|
||||
|
||||
$data['page_key'] = 'WRB_MAIN_ABOUT_US';
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_about', $data);
|
||||
$this->load->view('users/view_external_footer');
|
||||
// $this->load->view('templates/footer_boxed', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,71 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Bko extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
$data["username"] = "";
|
||||
$this->load->view('bko/view_bko_login', $data);
|
||||
}
|
||||
|
||||
public function logout() {
|
||||
$data['username'] = $data['password'] = '';
|
||||
$this->load->view('bko/view_bko_login', $data);
|
||||
}
|
||||
|
||||
public function login() {
|
||||
$data = array();
|
||||
$data['username'] = $data['password'] = '';
|
||||
$data['bko_username'] = $data['bko_password'] = '';
|
||||
|
||||
if ($_POST) {
|
||||
|
||||
$data['username'] = trim($this->input->post('username'));
|
||||
$data['password'] = $this->input->post('password');
|
||||
|
||||
if ($data['username'] != '' && $data['password'] != '') { // NOTE THAT IT msg_type is IMPORTTANT
|
||||
$this->load->model('backend_model');
|
||||
$data['action'] = WRENCHBOARD_BKO_LOGIN;
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($data, $out);
|
||||
// echo "~~~~~~~~ ".$res." ~~~~~~~~~";
|
||||
// print_r($out);
|
||||
/*
|
||||
*
|
||||
* - 10:36:20.728 INFO [14300]: RET: backoffice_id=1
|
||||
- 10:36:20.728 INFO [14300]: RET: created=2017-03-26 00:32:07.062577
|
||||
- 10:36:20.728 INFO [14300]: RET: email=ameye@chiefsoft.com
|
||||
- 10:36:20.728 INFO [14300]: RET: group_id=1
|
||||
- 10:36:20.728 INFO [14300]: RET: id=1
|
||||
- 10:36:20.728 INFO [14300]: RET: pass=d0fbea2563b377ea7074bced45c88dcb
|
||||
- 10:36:20.728 INFO [14300]: RET: result=YES I GET TO BACK END
|
||||
- 10:36:20.728 INFO [14300]: RET: sessionid=3ff02565e39c84d56cb01360f8a0ab4f
|
||||
- 10:36:20.728 INFO [14300]: RET: status=1
|
||||
- 10:36:20.728 INFO [14300]: RET: stauts=OK
|
||||
- 10:36:20.728 INFO [14300]: RET: username=admin
|
||||
|
||||
*/
|
||||
$this->populate_bko_session($res, $out);
|
||||
}
|
||||
}
|
||||
|
||||
$this->load->view('bko/view_bko_login', $data);
|
||||
}
|
||||
|
||||
private function populate_bko_session($res, $out) {
|
||||
|
||||
if ($res == PHP_API_OK && $out["sessionid"] != '' && $out["backoffice_id"] > 0) {
|
||||
|
||||
$_SESSION['backoffice_id'] = $out["backoffice_id"];
|
||||
$_SESSION['bko_email'] = $out["email"];
|
||||
$_SESSION['bko_sessionid'] = $out["sessionid"];
|
||||
$_SESSION['bko_username'] = $out["username"];
|
||||
$_SESSION['bko_selected_memberd_id'] = 0;
|
||||
$_SESSION['bko_group'] = $out['group_id'];
|
||||
$_SESSION['bkodata'] = $out;
|
||||
redirect('bkouser/dash');
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Bkoadmin extends Bko_Controller {
|
||||
|
||||
public function users() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Bkomember extends Bko_Controller {
|
||||
|
||||
public function mtransfer() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function mpayments() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function mjobsdone() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function mjobposted() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,134 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Bkoreport extends Bko_Controller {
|
||||
/*
|
||||
var $template = array(
|
||||
'table_open' => "<table class='table table-striped table-hover table-bordered table-condensed'>",
|
||||
'thead_open' => '<thead>',
|
||||
'thead_close' => '</thead>',
|
||||
'heading_row_start' => '<tr>',
|
||||
'heading_row_end' => '</tr>',
|
||||
'heading_cell_start' => '<th>',
|
||||
'heading_cell_end' => '</th>',
|
||||
'tbody_open' => '<tbody>',
|
||||
'tbody_close' => '</tbody>',
|
||||
'row_start' => '<tr>',
|
||||
'row_end' => '</tr>',
|
||||
'cell_start' => '<td>',
|
||||
'cell_end' => '</td>',
|
||||
'row_alt_start' => '<tr>',
|
||||
'row_alt_end' => '</tr>',
|
||||
'cell_alt_start' => '<td>',
|
||||
'cell_alt_end' => '</td>',
|
||||
'table_close' => '</table>'
|
||||
);
|
||||
|
||||
*
|
||||
*/
|
||||
public function index() {
|
||||
$data["username"] = "";
|
||||
$this->load->view('bko/view_bko_login', $data);
|
||||
}
|
||||
|
||||
public function logout() {
|
||||
$data['username'] = $data['password'] = '';
|
||||
$this->load->view('bko/view_bko_login', $data);
|
||||
}
|
||||
|
||||
public function withdraws() {
|
||||
$data["title"] = "Withdraws Report";
|
||||
$mysql = "SELECT m.added::date AS date,m.terminatingamount*0.01 AS amount,m.fee*0.01 as fee, "
|
||||
. "mm.firstname||' '||mm.lastname||'<br>Email:'||mm.email AS Sender,"
|
||||
. "r.firstname||' '||r.lastname||'<br><b>Acc:</b>'||r.account_no||'-'||b.name AS Recitient,mp.confirmation,"
|
||||
. "CASE WHEN m.status=1 THEN 'Pending' WHEN m.status=3 THEN 'Cancelled' WHEN m.status=5 THEN 'Completed' ELSE '' END AS Status "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN sendmoney_recipient r ON r.id = m.recipientid "
|
||||
. " LEFT JOIN members mm ON mm.id = m.member_id "
|
||||
. "LEFT JOIN bank_entity_codes b ON b.code = r.bank_code "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "WHERE mp.confirmation IS NOT NULL ORDER BY m.id DESC LIMIT 4000";
|
||||
|
||||
// $query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Date', 'Amount', 'Fee', 'Recipient', 'Confirmation', 'Status')
|
||||
//$this->table->set_heading('Date', 'Amount','Fee','Recipient','Confirmation', 'Status');
|
||||
|
||||
$data['mysql'] = $mysql;
|
||||
$this->renderbkoreportpage($data);
|
||||
}
|
||||
|
||||
public function pendpay() {
|
||||
$data["title"] = "Pending withdraws Report";
|
||||
$mysql = "SELECT * FROM members";
|
||||
$data['mysql'] = $mysql;
|
||||
$this->renderbkoreportpage($data);
|
||||
}
|
||||
|
||||
public function payments() {
|
||||
$data["title"] = "Payment Report";
|
||||
$mysql = "SELECT * FROM members_payments";
|
||||
$data['mysql'] = $mysql;
|
||||
$this->renderbkoreportpage($data);
|
||||
}
|
||||
|
||||
public function signup() {
|
||||
$data["title"] = "Signup Report";
|
||||
$mysql = "SElECT added::date,username,firstname||' '||lastname AS Name,loc,last_login::date FROM members ORDER BY id DESC LIMIT 7000";
|
||||
$data['mysql'] = $mysql;
|
||||
$this->renderbkoreportpage($data);
|
||||
}
|
||||
|
||||
public function pendsignup() {
|
||||
$data["page_title"] = "Pending Signup Report";
|
||||
|
||||
$mysql = "SELECT '<b>ADDED:</b>'||added::date||'<br><b>EXPIRE:</b>'||expire::date As Dates,'<b>Username:</b>'||username||'<br> <b>Name:</b>'||firstname||' '||lastname AS Name,"
|
||||
. " (CASE WHEN status=1 THEN '<div id=\"btu'||id||'\"><button id=\"acc'||id||'\" class=\"btn btn-info btn-xs\" onclick=\"return resendLink('''||id||''');\" >Resend</button></div>' ELSE ' ' END) AS action ,"
|
||||
. " (CASE WHEN status=1 THEN '<div id=\"btu'||id||'\"><button id=\"acc'||id||'\" class=\"btn btn-warning btn-xs\" onclick=\"return resendLink('''||id||''');\" >Del</button></div>' ELSE ' ' END) AS Del "
|
||||
. " FROM members_pending WHERE expire> now() AND status = 1"
|
||||
. " ORDER BY id desc limit 5000";
|
||||
|
||||
|
||||
// $data['mysql'] = $mysql;
|
||||
|
||||
|
||||
|
||||
//$this->renderbkoreportpage($data);
|
||||
|
||||
//
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$this->table->set_heading(array('data' => 'Date', 'style' => 'width:180px'), 'Email/Name', array('data' => 'RES', 'style' => 'width:40px; cellpadding:0px;'), array('data' => 'Del', 'style' => 'width:40px; cellpadding:0px;'));
|
||||
//$mysql = $ydata['mysql'];
|
||||
$query = $this->db->query($mysql);
|
||||
$data['pendingsignup_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_pendingsignup', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
private function renderbkoreportpage($ydata) {
|
||||
$data = array();
|
||||
$data["page_title"] = $ydata["title"];
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT * FROM money_transfer LIMIT 100";
|
||||
|
||||
$sdate = '2016-01-01';
|
||||
$edate = '2018-01-01';
|
||||
|
||||
|
||||
$mysql = $ydata['mysql'];
|
||||
$query = $this->db->query($mysql);
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_report_generic', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,53 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Bkosmember extends Bkomember_Controller {
|
||||
|
||||
public function userdash() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
|
||||
$data = $this->bkoUserDashData($_SESSION['bko_selected_id']);
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_userdash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function mtransfer() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function mpayments() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function mjobsdone() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function mjobposted() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,540 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
function smart_htmlspecialchars($str) {
|
||||
if (substr($str, 0, 1) == '<')
|
||||
return $str;
|
||||
return htmlspecialchars($str);
|
||||
}
|
||||
|
||||
class Bkotransaction extends Bko_Controller {
|
||||
|
||||
public function index() {
|
||||
$data["username"] = "";
|
||||
$this->load->view('bko/view_bko_login', $data);
|
||||
}
|
||||
|
||||
public function smprocess() {
|
||||
// url: "/bkotransaction/smprocess?proc=PROCESS&sendmoney_id="+link_id
|
||||
$proc = $this->input->get('proc');
|
||||
$sendmoney_id = $this->input->get('sendmoney_id');
|
||||
|
||||
switch ($proc) {
|
||||
case 'PROCESS':
|
||||
$mysql = "SELECT m.id,mp.confirmation, m.added,me.firstname||' '||me.lastname||'<br>'||me.email AS Sender,"
|
||||
. "sr.firstname||' '||sr.lastname||'<br>ACC:'||sr.account_no||'-'||be.name AS recipient, m.initiatingamount*0.01 AS Amount,m.fee*0.01 AS Fee, "
|
||||
. "'<input type=submit id=\"accs'||m.id||'\" onclick=\"return smoneyDetail('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Detail\">' As Detail, "
|
||||
. "'<input type=submit id=\"acc'||m.id||'\" onclick=\"return smoneyProcess('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Process\">' As Process "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN members me ON me.id=m.member_id "
|
||||
. "LEFT JOIN sendmoney_recipient sr ON sr.id=m.recipientid "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "LEFT JOIN bank_entity_codes be ON be.code=sr.bank_code WHERE m.id=" . $sendmoney_id;
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$row = $query->row_array();
|
||||
|
||||
echo $this->sendmoneyProcessPage($row);
|
||||
|
||||
break;
|
||||
|
||||
case 'TRANSDETAIL':
|
||||
|
||||
$mysql = "SELECT m.id,mp.confirmation, m.added,me.firstname||' '||me.lastname||'<br>'||me.email AS Sender,"
|
||||
. "sr.firstname||' '||sr.lastname||'<br>ACC:'||sr.account_no||'-'||be.name AS recipient, m.initiatingamount*0.01 AS Amount,m.fee*0.01 AS Fee, "
|
||||
. "'<input type=submit id=\"accs'||m.id||'\" onclick=\"return smoneyDetail('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Detail\">' As Detail, "
|
||||
. "'<input type=submit id=\"acc'||m.id||'\" onclick=\"return smoneyProcess('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Process\">' As Process "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN members me ON me.id=m.member_id "
|
||||
. "LEFT JOIN sendmoney_recipient sr ON sr.id=m.recipientid "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "LEFT JOIN bank_entity_codes be ON be.code=sr.bank_code WHERE m.id=" . $sendmoney_id;
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$row = $query->row_array();
|
||||
|
||||
echo $this->TransmitSendmoneyProcessPage($row);
|
||||
|
||||
|
||||
break;
|
||||
|
||||
case 'DETAIL':
|
||||
|
||||
echo 'detail';
|
||||
|
||||
break;
|
||||
|
||||
case 'COMPLETE':
|
||||
//echo 'complete 1';
|
||||
// url: "/bkotransaction/smprocess?proc=COMPLETE&sendmoney_id="+link_id+'&tcode='+tcode+'&tref='+tref
|
||||
$data["trans_code"] = $this->input->get('tcode');
|
||||
$data["trans_tref"] = $this->input->get('tref');
|
||||
$data["sendmoney_id"] = $sendmoney_id;
|
||||
$data['action'] = WRENCHBOARD_SMONEY_BKOPROC;
|
||||
$data['action_mode'] = SMONEY_PROCC_MANUAL;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$this->backend_model->wrenchboard_api($data, $out);
|
||||
echo $out['status'];
|
||||
|
||||
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public function smTransmitProcess() {
|
||||
// url: "/bkotransaction/smprocess?proc=PROCESS&sendmoney_id="+link_id
|
||||
$proc = $this->input->get('proc');
|
||||
$sendmoney_id = $this->input->get('sendmoney_id');
|
||||
|
||||
switch ($proc) {
|
||||
case 'PROCESS':
|
||||
$mysql = "SELECT m.id,mp.confirmation, m.added,me.firstname||' '||me.lastname||'<br>'||me.email AS Sender,"
|
||||
. "sr.firstname||' '||sr.lastname||'<br>ACC:'||sr.account_no||'-'||be.name AS recipient, m.initiatingamount*0.01 AS Amount,m.fee*0.01 AS Fee, "
|
||||
. "'<input type=submit id=\"accs'||m.id||'\" onclick=\"return smoneyDetail('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Detail\">' As Detail, "
|
||||
. "'<input type=submit id=\"acc'||m.id||'\" onclick=\"return smoneyProcess('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Process\">' As Process "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN members me ON me.id=m.member_id "
|
||||
. "LEFT JOIN sendmoney_recipient sr ON sr.id=m.recipientid "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "LEFT JOIN bank_entity_codes be ON be.code=sr.bank_code WHERE m.id=" . $sendmoney_id;
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$row = $query->row_array();
|
||||
|
||||
echo $this->sendmoneyProcessPage($row);
|
||||
|
||||
break;
|
||||
|
||||
case 'DETAIL':
|
||||
|
||||
echo 'detail';
|
||||
|
||||
break;
|
||||
|
||||
case 'TRANSMIT':
|
||||
//echo 'complete 1';
|
||||
// url: "/bkotransaction/smprocess?proc=COMPLETE&sendmoney_id="+link_id+'&tcode='+tcode+'&tref='+tref
|
||||
$data["trans_code"] = $this->input->get('tcode');
|
||||
$data["trans_tref"] = $this->input->get('tref');
|
||||
$data["sendmoney_id"] = $sendmoney_id;
|
||||
$data['action'] = WRENCHBOARD_SMONEY_BKOPROC;
|
||||
$data['action_mode'] = SMONEY_PROCC_INTERSWITCH;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$this->backend_model->wrenchboard_api($data, $out);
|
||||
echo $out['status'];
|
||||
|
||||
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private function TransmitSendmoneyProcessPage($out) {
|
||||
|
||||
$myTable = "<form id='sendmoneyProcessPage" . $out['id'] . "' name='sendmoneyProcessPage" . $out['id'] . "'><table class='table table-striped table-hover table-bordered table-condensed'>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Confirmation</b></td><td>" . $out['confirmation'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Trx. Date</b></td><td>" . $out['added'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Sender</b></td><td>" . $out['sender'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Recipient</b></td><td>" . $out['recipient'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Amount</b></td><td>" . $out['amount'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Fee</b></td><td>" . $out['fee'] . "</td></tr>";
|
||||
|
||||
$myTable .="<tr><td style='width:100px;'><b></b></td><td><div id='btump" . $out['id'] . "'><input type=submit id=\"acmp" . $out['id'] . "\" onclick=\"return smoneyProcessComplete('" . $out['id'] . "')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Complete\"></div></td></tr>";
|
||||
$myTable .="</table></form> [another tabble]";
|
||||
|
||||
return $myTable;
|
||||
}
|
||||
|
||||
private function sendmoneyProcessPage($out) {
|
||||
|
||||
$myTable = "<form id='sendmoneyProcessPage" . $out['id'] . "' name='sendmoneyProcessPage" . $out['id'] . "'><table class='table table-striped table-hover table-bordered table-condensed'>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Confirmation</b></td><td>" . $out['confirmation'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Trx. Date</b></td><td>" . $out['added'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Sender</b></td><td>" . $out['sender'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Recipient</b></td><td>" . $out['recipient'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Amount</b></td><td>" . $out['amount'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Fee</b></td><td>" . $out['fee'] . "</td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Trans Code</b></td><td><input type=\"text\" class=\"form-control\" id='tcode' name='tcode'></td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b>Trans Ref</b></td><td><input type=\"text\" class=\"form-control\" id='tref' name='tref'></td></tr>";
|
||||
$myTable .="<tr><td style='width:100px;'><b></b></td><td><div id='btump" . $out['id'] . "'><input type=submit id=\"acmp" . $out['id'] . "\" onclick=\"return smoneyProcessComplete('" . $out['id'] . "')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Complete\"></div></td></tr>";
|
||||
$myTable .="</table></form>";
|
||||
|
||||
return $myTable;
|
||||
}
|
||||
|
||||
public function moneytransfer() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT * FROM money_transfer LIMIT 100";
|
||||
|
||||
$sdate = '2016-01-01';
|
||||
$edate = '2018-01-01';
|
||||
|
||||
$mysql = "SELECT m.added,mp.confirmation,me.firstname||' '||me.lastname||'<br>'||me.email AS Sender,"
|
||||
. "sr.firstname||' '||sr.lastname||'<br>ACC:'||sr.account_no||'-'||be.name AS recipient, m.initiatingamount*0.01 AS Amount,m.fee*0.01 AS Fee, "
|
||||
. "'<input type=submit onclick=\"return smoneyDetail('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Detail\">' As Detail, "
|
||||
. "'<input type=submit id=\"acc'||m.id||'\" onclick=\"return smoneyProcess('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Process\">' As Process "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN members me ON me.id=m.member_id "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "LEFT JOIN sendmoney_recipient sr ON sr.id=m.recipientid "
|
||||
. "LEFT JOIN bank_entity_codes be ON be.code=sr.bank_code "
|
||||
. "WHERE m.status =1 AND m.completed IS NULL ORDER BY m.added DESC ";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_pendingsm', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function completedtransfer() {
|
||||
|
||||
$data = array();
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT * FROM money_transfer LIMIT 100";
|
||||
|
||||
$sdate = '2016-01-01';
|
||||
$edate = '2018-01-01';
|
||||
|
||||
$mysql = "SELECT m.completed||'<br>'||m.added AS COMPLETE_ADD,mp.confirmation,me.firstname||' '||me.lastname||'<br>'||me.email AS Sender,"
|
||||
. "sr.firstname||' '||sr.lastname||'<br>ACC:'||sr.account_no||'-'||be.name AS recipient, m.initiatingamount*0.01 AS Amount,m.fee*0.01 AS Fee, "
|
||||
. "'<input type=submit onclick=\"return smoneyDetail('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Detail\">' As Detail, "
|
||||
. "'<input type=submit id=\"acc'||m.id||'\" onclick=\"return smoneyProcess('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Process\">' As Process "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN members me ON me.id=m.member_id "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "LEFT JOIN sendmoney_recipient sr ON sr.id=m.recipientid "
|
||||
. "LEFT JOIN bank_entity_codes be ON be.code=sr.bank_code "
|
||||
. "WHERE m.status =5 AND m.completed IS NOT NULL ORDER BY m.completed DESC ";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_pendingsm', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function transmittransfer() {
|
||||
$this->listPendingTransfer('view_bko_transmitsm');
|
||||
}
|
||||
|
||||
|
||||
private function listPendingTransfer($pageName) {
|
||||
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT * FROM money_transfer LIMIT 100";
|
||||
|
||||
$sdate = '2016-01-01';
|
||||
$edate = '2018-01-01';
|
||||
|
||||
$mysql = "SELECT m.added,mp.confirmation,me.firstname||' '||me.lastname||'<br>'||me.email AS Sender,"
|
||||
. "sr.firstname||' '||sr.lastname||'<br>ACC:'||sr.account_no||'-'||be.name AS recipient, m.initiatingamount*0.01 AS Amount,m.fee*0.01 AS Fee, "
|
||||
. "'<input type=submit onclick=\"return smoneyDetail('||m.id||')\" name=\"manage\" class=\"btn btn-info btn-xs\" value=\"Detail\">' As Detail, "
|
||||
. "'<input type=submit id=\"acc'||m.id||'\" onclick=\"return smoneyTransmit('||m.id||')\" name=\"manage\" class=\"btn btn-warning btn-xs\" value=\"Transmit >> \">' As Transmit "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN members me ON me.id=m.member_id "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "LEFT JOIN sendmoney_recipient sr ON sr.id=m.recipientid "
|
||||
. "LEFT JOIN bank_entity_codes be ON be.code=sr.bank_code "
|
||||
. "WHERE m.status =1 AND m.completed IS NULL ORDER BY m.added DESC ";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/' . $pageName, $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function pendingcontract() {
|
||||
$data["title"] = "Pending Offers";
|
||||
$mysql = "SELECT j.added||'<br>'||j.offer_code AS cc1,'<b>From: </b> '||m1.email||'-'||m1.firstname||' '||m1.lastname||'<br><b>To: </b> '||m2.email||'-'||m2.firstname||' '||m2.lastname AS client ,"
|
||||
. "j.job_description "
|
||||
. "FROM members_jobs_offer j "
|
||||
. "LEFT JOIN members m1 ON m1.id=j.member_id "
|
||||
. "LEFT JOIN members m2 ON m2.id=j.client_id "
|
||||
. " WHERE j.expire > now() AND j.status = 1 AND j.payment_id IS NOT NULL";
|
||||
$data['mysql'] = $mysql;
|
||||
|
||||
$this->renderbkopage($data);
|
||||
}
|
||||
|
||||
/* public function recentrefer() {
|
||||
$data["title"] = "Recent Referrer Activities";
|
||||
$mysql = "select mb.email AS from_email,m.* from members_refer_friend m left join members mb ON mb.id = m.member_id order by m.id desc limit 20";
|
||||
$data['mysql'] = $mysql;
|
||||
$this->renderbkopage($data);
|
||||
}
|
||||
*
|
||||
*/
|
||||
|
||||
public function recentrefer() {
|
||||
$data["title"] = "Recent Referrer Activities";
|
||||
//$mysql = "select m.id,mb.email AS from_email,m.status,m.member_id,m.firstname,m.lastname,m.email from members_refer_friend m left join members mb ON mb.id = m.member_id order by m.id desc limit 20";
|
||||
$mysql = "select m.id,mb.email AS from_email,m.firstname||' '||m.lastname||'<br>'||m.email AS ref_name_email,m.status from members_refer_friend m left join members mb ON mb.id = m.member_id order by m.id desc limit 200";
|
||||
$data['mysql'] = $mysql;
|
||||
$this->renderbkopage($data);
|
||||
}
|
||||
|
||||
public function referactivity() {
|
||||
$data["title"] = "Referrer Activities";
|
||||
$mysql = "select mb.email AS from_email,m.* from members_refer_friend m left join members mb ON mb.id = m.member_id order by m.id desc";
|
||||
$data['mysql'] = $mysql;
|
||||
$this->renderbkopage($data);
|
||||
}
|
||||
|
||||
public function refund_offer() {
|
||||
// $out = array();
|
||||
$out['member_id'] = 0;
|
||||
$offer_result = OFFER_EXPIRE;
|
||||
$jobOfferID = $this->input->get('link_id');
|
||||
$mysql = "SELECT member_id,offer_code FROM members_jobs_offer WHERE id = " . $jobOfferID . " AND status IN (1,2) AND payment_id IS NOT NULL";
|
||||
$query = $this->db->query($mysql);
|
||||
$out = $query->result_array();
|
||||
// print_r($out);
|
||||
// echo 'got here '.$out[0]['member_id'];
|
||||
$in = array();
|
||||
if ($out[0]['member_id'] > 0 && $jobOfferID > 0) {
|
||||
$in['offer_code'] = $out[0]['offer_code']; //
|
||||
$in['member_id'] = $out[0]['member_id'];
|
||||
$in['offer_result'] = $offer_result;
|
||||
$in['action'] = WRENCHBOARD_JOB_OFFER_CONCLUDE;
|
||||
$this->load->model('backend_model');
|
||||
|
||||
$res = $this->backend_model->wrenchboard_api($in, $out);
|
||||
if ($out["result"] == "OK") {
|
||||
switch ($offer_result) {
|
||||
|
||||
case OFFER_ACCEPT:
|
||||
// echo "You have accepted this offer and we have notified the client. Please go to <a href='/proj/active'>manage page</a> to continue ";
|
||||
break;
|
||||
|
||||
case OFFER_REJECT:
|
||||
// echo "You have rejected this offer and we have notified the client.";
|
||||
break;
|
||||
case OFFER_EXPIRE:
|
||||
echo "You have cancelled this offer and refunded the user.";
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public function expiredoffers() {
|
||||
$data["page_title"] = "Expired Offers";
|
||||
$mysql = "SELECT "
|
||||
. "'<div id=\"btu'||id||'\"><input type=submit id=\"acc'||id||'\" onclick=\"return refundOffer('||id||')\" name=\"refund\" class=\"btn btn-info btn-sm\" value=\"Refund\"></div>' As Refund "
|
||||
. ",* "
|
||||
. " FROM members_jobs_offer WHERE expire < now() AND status = 1 AND payment_id IS NOT NULL";
|
||||
|
||||
|
||||
$mysql = "SELECT j.added||'<br>'||j.offer_code AS cc1,'<b>From: </b> '||m1.email||'-'||m1.firstname||' '||m1.lastname||'<br><b>To: </b> '||m2.email||'-'||m2.firstname||' '||m2.lastname AS client ,"
|
||||
. "'<div id=\"btu'||j.id||'\"><input type=submit id=\"acc'||j.id||'\" onclick=\"return refundOffer('||j.id||')\" name=\"refund\" class=\"btn btn-info btn-sm\" value=\"Refund\"></div>' As Refund, "
|
||||
. "j.job_description "
|
||||
. "FROM members_jobs_offer j "
|
||||
. "LEFT JOIN members m1 ON m1.id=j.member_id "
|
||||
. "LEFT JOIN members m2 ON m2.id=j.client_id "
|
||||
. " WHERE j.expire < now() AND j.status = 1 AND j.payment_id IS NOT NULL";
|
||||
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->function = 'smart_htmlspecialchars';
|
||||
$data['expired_offer_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_expiredoffer', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function activecontract() {
|
||||
$data["page_title"] = "Active Contracts";
|
||||
|
||||
|
||||
$mysql = "SELECT mj.id,'<b><a href=\"#\" onclick=\"return viewJobdetail('||mj.id||')\" >'||mj.contract||'</a></b><br>'||mo.title AS thejob,'<b>Owner: </b>'||m1.firstname||' '||m1.lastname||' <br>'|| m1.email||'<br><b>Client: </b>'||m2.firstname||' '||m2.lastname||' <br>'|| m2.email AS Team1 "
|
||||
. "FROM members_jobs_contract mj "
|
||||
. "LEFT JOIN members_jobs mo ON mo.id=mj.job_id "
|
||||
. "LEFT JOIN members m1 ON m1.id=mj.member_id "
|
||||
. "LEFT JOIN members m2 ON m2.id=mj.client_id "
|
||||
. "WHERE mj.status IN (1,4) ORDER by mj.id DESC ";
|
||||
// $data['mysql'] = $mysql;
|
||||
// $this->renderbkopage($data);
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_completedjob', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function pastduecontract() {
|
||||
|
||||
$data["page_title"] = "Past Due Contracts";
|
||||
|
||||
|
||||
$mysql = "SELECT mj.id,'<b><a href=\"#\" onclick=\"return viewJobdetail('||mj.id||')\" >'||mj.contract||'</a></b><br>'||mo.title AS thejob,'<b>Owner: </b>'||m1.firstname||' '||m1.lastname||' <br>'|| m1.email||'<br><b>Client: </b>'||m2.firstname||' '||m2.lastname||' <br>'|| m2.email AS Team1 "
|
||||
. "FROM members_jobs_contract mj "
|
||||
. "LEFT JOIN members_jobs mo ON mo.id=mj.job_id "
|
||||
. "LEFT JOIN members m1 ON m1.id=mj.member_id "
|
||||
. "LEFT JOIN members m2 ON m2.id=mj.client_id "
|
||||
. "WHERE mj.status =1 AND mj.delivery_date < now() ORDER by mj.id DESC ";
|
||||
// $data['mysql'] = $mysql;
|
||||
// $this->renderbkopage($data);
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_completedjob', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function completedcontract() {
|
||||
|
||||
$data["page_title"] = "Completed Jobs";
|
||||
|
||||
$data["title"] = "Completed Contracts";
|
||||
$mysql = "SELECT mj.id,'<b><a href=\"#\" onclick=\"return viewJobdetail('||mj.id||')\" >'||mj.contract||'</a></b><br>'||mo.title AS thejob,'<b>Owner: </b>'||m1.firstname||' '||m1.lastname||' <br>'|| m1.email||'<br><b>Client: </b>'||m2.firstname||' '||m2.lastname||' <br>'|| m2.email AS Team1 "
|
||||
. "FROM members_jobs_contract mj "
|
||||
. "LEFT JOIN members_jobs mo ON mo.id=mj.job_id "
|
||||
. "LEFT JOIN members m1 ON m1.id=mj.member_id "
|
||||
. "LEFT JOIN members m2 ON m2.id=mj.client_id "
|
||||
. "WHERE mj.status =5 ORDER by mj.id DESC ";
|
||||
// $data['mysql'] = $mysql;
|
||||
// $this->renderbkopage($data);
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_completedjob', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function jobdetail() {
|
||||
$job_id = $this->input->get('job_id');
|
||||
if ($this->input->get() && $job_id != '' && $job_id > 0) {
|
||||
|
||||
// echo 'jobdetail ' . $job_id;
|
||||
|
||||
$detail_button = " '<button type=\"button\" class=\"btn btn-primary btn-xs\" data-toggle=\"modal\" data-target=\"#modal_theme_primary\">Delvery Detail<i class=\"icon-play3 position-right\"></i></button>' ";
|
||||
|
||||
$this->load->model('backend_model');
|
||||
$is_live = $this->backend_model->cfgReadChar("system.live");
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$jbx = "''thisjob''";
|
||||
$mysql = "SELECT '<b>Project ID :</b>'||mc.contract||' - <b>Name: </b>'||m.firstname||'<br><b>Title:</b>'||mc.title||'<br>'||'<b>Description: </b>'||mc.description||'<br><b>Timeline: </b> '||mc.timeline_days||' day(s) <b>Price: </b>'||mc.price*0.01||'Naira'||' <b>Expected Delivery: </b>'||mc.delivery_date AS this_job,"
|
||||
. " mc.contract AS contract_id, mc.job_detail AS job_detail "
|
||||
. "FROM members_jobs_contract mc LEFT JOIN members m ON m.id=mc.client_id WHERE mc.id=" . $job_id;
|
||||
$query = $this->db->query($mysql);
|
||||
$jbD = $query->row();
|
||||
|
||||
// $this->table->set_heading('Job', 'Client', 'Terms', 'Price', 'Manage', 'Status');
|
||||
echo $data['job_table'] = $this->table->generate($query);
|
||||
$data['this_job'] = $jbD->this_job;
|
||||
$data['contract_id'] = $jbD->contract_id;
|
||||
$data['job_detail'] = $jbD->job_detail;
|
||||
|
||||
$sqlMsg = "SELECT (CASE WHEN jc.msg_type='FILE' THEN '<a target=\"_blank\" href=\"/smedia/" . ($is_live ? "LIVE" : "TEST") . "/contract/" . $data['contract_id'] . "/'||jc.message||'\">'||jc.message||'</a>' ELSE '<b>['||m.firstname||']->'||jc.created||'</b><br>'||jc.message END) AS msg "
|
||||
. "FROM jobs_contract_message jc "
|
||||
. "LEFT JOIN members m ON m.id=jc.member_id "
|
||||
. "WHERE jc.contract='" . $data['contract_id'] . "' ORDER by jc.id ASC";
|
||||
|
||||
$query_message = $this->db->query($sqlMsg);
|
||||
$this->table->set_template($this->template_nohead);
|
||||
$this->table->set_heading('');
|
||||
echo $data['message_table'] = $this->table->generate($query_message);
|
||||
}
|
||||
}
|
||||
|
||||
public function jobcontractreport() {
|
||||
|
||||
$data["title"] = "Job and Contracts Report";
|
||||
$mysql = "SELECT * FROM members_jobs_offer";
|
||||
$data['mysql'] = $mysql;
|
||||
$this->renderbkopage($data);
|
||||
}
|
||||
|
||||
private function renderbkopage($ydata) {
|
||||
$data = array();
|
||||
$data["page_title"] = $ydata["title"];
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT * FROM money_transfer LIMIT 100";
|
||||
|
||||
$sdate = '2016-01-01';
|
||||
$edate = '2018-01-01';
|
||||
|
||||
|
||||
$mysql = $ydata['mysql'];
|
||||
$query = $this->db->query($mysql);
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_generic1', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function accountdeposit() {
|
||||
$data = array();
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
$mysql = "SELECT * FROM members";
|
||||
$query = $this->db->query($mysql);
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_accountdeposit', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function memberdetail() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,625 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
function smart_htmlspecialchars($str) {
|
||||
return htmlspecialchars_decode($str);
|
||||
/*
|
||||
if (substr($str, 0, 1) == '<')
|
||||
return $str;
|
||||
return htmlspecialchars($str);
|
||||
*/
|
||||
}
|
||||
|
||||
class Bkouser extends Bko_Controller {
|
||||
|
||||
public function index() {
|
||||
$data["username"] = "";
|
||||
$this->load->view('bko/view_bko_login', $data);
|
||||
}
|
||||
|
||||
public function logout() {
|
||||
$data['username'] = $data['password'] = '';
|
||||
$this->load->view('bko/view_bko_login', $data);
|
||||
}
|
||||
|
||||
public function dash() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function wrbwhy() {
|
||||
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
|
||||
$data["why_title"] = $data["why_detail"] = $data["why_flag"] = '';
|
||||
$data["why_flag"] = '0';
|
||||
|
||||
$this->load->model('backend_model');
|
||||
$is_live = $this->backend_model->cfgReadChar("system.live");
|
||||
//$data = array();
|
||||
|
||||
if ($_POST) {
|
||||
|
||||
$data['why_title'] = trim($this->input->post('why_title'));
|
||||
$data['why_detail'] = htmlspecialchars($this->input->post('why_detail'));
|
||||
$data['why_flag'] = $this->input->post('why_flag');
|
||||
|
||||
$xar = array();
|
||||
$query = $this->db->query("SELECT id FROM why WHERE lower(title)=lower('" . $data['why_title'] . "') ");
|
||||
if ($query->num_rows() > 0) {
|
||||
echo "Duplicate!";
|
||||
} else {
|
||||
$xar['title'] = $data['why_title'];
|
||||
$xar['msg'] = $data['why_detail'];
|
||||
$xar['flags'] = $data['why_flag'];
|
||||
$this->db->insert('why', $xar);
|
||||
}
|
||||
}
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT '<b>'||title||'</b><br>'||msg AS FQ,"
|
||||
. " '<div id=\"subdel_'||id||'\" ><input type=button onclick=\"return post_nav_find_action('||id||')\" name=\"manage\" class=\"btn btn-info btn-xs\" value=\"Edit\">"
|
||||
. " <input type=button id=\"dacc'||id||'\" onclick=\"return deleteFaq('||id||')\" name=\"delete\" class=\"btn btn-warning btn-xs\" value=\"Del\"></div>' AS option "
|
||||
. " FROM why ORDER BY id DESC";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Dates', 'Username', 'Name', 'Status', 'Verify Link', 'Action');
|
||||
$this->table->function = 'smart_htmlspecialchars';
|
||||
$data['why_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_why', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function uploads(){
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
|
||||
$data["faq_title"] = $data["faq_detail"] = $data["faq_flag"] = '';
|
||||
$data["faq_flag"] = '0';
|
||||
|
||||
$this->load->model('backend_model');
|
||||
$is_live = $this->backend_model->cfgReadChar("system.live");
|
||||
//$data = array();
|
||||
|
||||
if ($_POST) {
|
||||
|
||||
$data['faq_title'] = trim($this->input->post('faq_title'));
|
||||
$data['faq_detail'] = htmlspecialchars($this->input->post('faq_detail'));
|
||||
$data['faq_flag'] = $this->input->post('faq_flag');
|
||||
|
||||
$xar = array();
|
||||
$query = $this->db->query("SELECT id FROM faq WHERE lower(title)=lower('" . $data['faq_title'] . "') ");
|
||||
if ($query->num_rows() > 0) {
|
||||
echo "Duplicate!";
|
||||
} else {
|
||||
$xar['title'] = $data['faq_title'];
|
||||
$xar['msg'] = $data['faq_detail'];
|
||||
$xar['flags'] = $data['faq_flag'];
|
||||
$this->db->insert('faq', $xar);
|
||||
}
|
||||
}
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT '<b>'||title||'</b><br>'||msg AS FQ,"
|
||||
. " '<div id=\"subdel_'||id||'\" ><input type=button onclick=\"return post_nav_find_action('||id||')\" name=\"manage\" class=\"btn btn-info btn-xs\" value=\"Edit\">"
|
||||
. " <input type=button id=\"dacc'||id||'\" onclick=\"return deleteFaq('||id||')\" name=\"delete\" class=\"btn btn-warning btn-xs\" value=\"Del\"></div>' AS option "
|
||||
. " FROM faq ORDER BY id DESC";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Dates', 'Username', 'Name', 'Status', 'Verify Link', 'Action');
|
||||
$this->table->function = 'smart_htmlspecialchars';
|
||||
$data['faq_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_uploads', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
|
||||
}
|
||||
|
||||
|
||||
public function faq() {
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
|
||||
$data["faq_title"] = $data["faq_detail"] = $data["faq_flag"] = '';
|
||||
$data["faq_flag"] = '0';
|
||||
|
||||
$this->load->model('backend_model');
|
||||
$is_live = $this->backend_model->cfgReadChar("system.live");
|
||||
//$data = array();
|
||||
|
||||
if ($_POST) {
|
||||
|
||||
$data['faq_title'] = trim($this->input->post('faq_title'));
|
||||
$data['faq_detail'] = htmlspecialchars($this->input->post('faq_detail'));
|
||||
$data['faq_flag'] = $this->input->post('faq_flag');
|
||||
|
||||
$xar = array();
|
||||
$query = $this->db->query("SELECT id FROM faq WHERE lower(title)=lower('" . $data['faq_title'] . "') ");
|
||||
if ($query->num_rows() > 0) {
|
||||
echo "Duplicate!";
|
||||
} else {
|
||||
$xar['title'] = $data['faq_title'];
|
||||
$xar['msg'] = $data['faq_detail'];
|
||||
$xar['flags'] = $data['faq_flag'];
|
||||
$this->db->insert('faq', $xar);
|
||||
}
|
||||
}
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT '<b>'||title||'</b><br>'||msg AS FQ,"
|
||||
. " '<div id=\"subdel_'||id||'\" ><input type=button onclick=\"return post_nav_find_action('||id||')\" name=\"manage\" class=\"btn btn-info btn-xs\" value=\"Edit\">"
|
||||
. " <input type=button id=\"dacc'||id||'\" onclick=\"return deleteFaq('||id||')\" name=\"delete\" class=\"btn btn-warning btn-xs\" value=\"Del\"></div>' AS option "
|
||||
. " FROM faq ORDER BY id DESC";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Dates', 'Username', 'Name', 'Status', 'Verify Link', 'Action');
|
||||
$this->table->function = 'smart_htmlspecialchars';
|
||||
$data['faq_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_faq', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function deletefaq() {
|
||||
$faq_id = $this->input->get('faq_id');
|
||||
$mysql = "DELETE FROM faq WHERE id = " . $faq_id;
|
||||
$this->db->query($mysql);
|
||||
echo 'Deleted - ' . $faq_id;
|
||||
}
|
||||
|
||||
public function deletewhy() {
|
||||
$why_id = $this->input->get('why_id');
|
||||
$mysql = "DELETE FROM why WHERE id = " . $why_id;
|
||||
$this->db->query($mysql);
|
||||
echo 'Deleted - ' . $why_id;
|
||||
}
|
||||
|
||||
public function seluser() {
|
||||
//url: "/bkouser/seluser?proc=SEL&member_id="+link_id
|
||||
$member_id = $this->input->get('member_id');
|
||||
|
||||
$mysql = "SElECT * "
|
||||
. " FROM members WHERE id = " . $member_id;
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$row = $query->row();
|
||||
|
||||
if (isset($row)) {
|
||||
$_SESSION['bko_selected_id'] = $row->id;
|
||||
$_SESSION['bko_selected_username'] = $row->username;
|
||||
$_SESSION['bko_selected_row'] = $row;
|
||||
$_SESSION['bko_selected_memberd_id'] = $member_id;
|
||||
}
|
||||
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
$mysql = "SELECT firstname,lastname,balance,email FROM members WHERE id=" . $_SESSION['bko_selected_id'];
|
||||
$query = $this->db->query($mysql);
|
||||
$data['user_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$mysql = "SELECT m.added::date AS date,m.terminatingamount*0.01 AS amount,m.fee*0.01 as fee, "
|
||||
. "r.firstname||' '||r.lastname||'<br><b>Acc:</b>'||r.account_no||'-'||b.name AS Recitient,mp.confirmation,"
|
||||
. "CASE WHEN m.status=1 THEN 'Pending' WHEN m.status=3 THEN 'Cancelled' WHEN m.status=5 THEN 'Completed' ELSE '' END AS Status "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN sendmoney_recipient r ON r.id = m.recipientid "
|
||||
. "LEFT JOIN bank_entity_codes b ON b.code = r.bank_code "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "WHERE m.member_id =" . $_SESSION['bko_selected_id'] . " AND mp.confirmation IS NOT NULL ORDER BY m.id DESC LIMIT 20";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading('Date', 'Amount', 'Fee', 'Recipient', 'Confirmation', 'Status');
|
||||
$data['sendmoney_table'] = $this->table->generate($query);
|
||||
|
||||
$mysql = "SELECT added::date,(CASE WHEN code = 'OFDPS' THEN 'Job Offer Deposit' "
|
||||
. "WHEN code ='OFRFD' THEN 'Job Offer Refund' WHEN code='MDEPT' THEN 'Account Depoist' "
|
||||
. "WHEN code ='SMPAY' THEN 'Account Withdraw' "
|
||||
. "WHEN code ='COPAY' THEN 'Completed Task Payment' ELSE '' END) AS Description,amount*0.01 AS amount,fee*0.01 as fee,confirmation "
|
||||
. "FROM members_payments "
|
||||
. "WHERE member_id = " . $_SESSION['bko_selected_id'] . " AND status = 1 ORDER BY id DESC ";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$this->table->set_heading(array('data' => 'Date', 'style' => 'width:100px'), 'Description', array('data' => 'Amount', 'style' => 'width:100px'), array('data' => 'Fee', 'style' => 'width:70px'), array('data' => 'Confirmation', 'style' => 'width:100px'));
|
||||
$data['payment_result'] = $this->table->generate($query);
|
||||
|
||||
|
||||
echo "<b>User:</b><br>" . $data['user_table'] . "<br><b> Withdraw Last 20:</b> <br>" . $data['sendmoney_table'] . "<br><b>Payments:</b><br>" . $data['payment_result'];
|
||||
}
|
||||
|
||||
public function terms() {
|
||||
|
||||
$data = array();
|
||||
$data['page_name'] = 'terms';
|
||||
$data['page_title'] = 'Terms & Condition';
|
||||
$data['page_key'] = 'WRB_MAIN_SIGNUP_TERM';
|
||||
|
||||
if ($this->input->post()) {
|
||||
$this->savepagetext();
|
||||
}
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_fixededitor', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function about() {
|
||||
|
||||
$data = array();
|
||||
$data['page_name'] = 'about';
|
||||
$data['page_title'] = 'About us';
|
||||
$data['page_key'] = 'WRB_MAIN_ABOUT_US';
|
||||
|
||||
if ($this->input->post()) {
|
||||
$this->savepagetext();
|
||||
}
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_fixededitor', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function privacy() {
|
||||
|
||||
$data = array();
|
||||
$data['page_name'] = 'privacy';
|
||||
$data['page_title'] = 'Privacy Policy';
|
||||
$data['page_key'] = 'WRB_MAIN_PRIVACY';
|
||||
|
||||
if ($this->input->post()) {
|
||||
$this->savepagetext();
|
||||
}
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_fixededitor', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function libraryedit() {
|
||||
|
||||
$lib_id = $this->input->get('lib_id');
|
||||
if ($this->input->get('PROC') == 'EDIT' && $lib_id != '' && $lib_id > 0) {
|
||||
|
||||
echo 'Ameye';
|
||||
}
|
||||
}
|
||||
|
||||
public function library() {
|
||||
|
||||
$data = array();
|
||||
$data = $this->bkoDashData();
|
||||
$new_mode = true;
|
||||
|
||||
$data['lib_id'] = 0;
|
||||
$data["lib_title"] = $data["lib_detail"] = $data["lib_flag"] = '';
|
||||
$data["lib_flag"] = '0';
|
||||
|
||||
|
||||
$lib_id = $this->input->get('lib_id');
|
||||
if ($this->input->get('PROC') == 'EDIT' && $lib_id != '' && $lib_id > 0) {
|
||||
|
||||
$rs = $this->libraryContent($lib_id);
|
||||
$data["lib_title"] = $rs['title'];
|
||||
$data["lib_detail"] = $rs['detail'];
|
||||
$data["lib_flag"] = 0;
|
||||
$new_mode = false;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
if ($_POST) {
|
||||
$lib_id = $this->input->post('lib_id');
|
||||
|
||||
$data['lib_title'] = trim($this->input->post('lib_title'));
|
||||
$data['lib_detail'] = htmlspecialchars($this->input->post('lib_detail'));
|
||||
$data['lib_flag'] = $this->input->post('lib_flag');
|
||||
if ($lib_id == 0) {
|
||||
$xar = array();
|
||||
$query = $this->db->query("SELECT id FROM library WHERE lower(title)=lower('" . $data['lib_title'] . "') ");
|
||||
if ($query->num_rows() > 0) {
|
||||
echo "Duplicate!";
|
||||
} else {
|
||||
$xar['title'] = $data['lib_title'];
|
||||
$xar['description'] = $data['lib_title']; // for now
|
||||
$xar['detail'] = $data['lib_detail'];
|
||||
// $xar['flags'] = $data['lib_flag'];
|
||||
$this->db->insert('library', $xar);
|
||||
}
|
||||
} else {
|
||||
// updating now
|
||||
$xr = array(
|
||||
'detail' => $data['lib_detail']
|
||||
);
|
||||
$this->db->where('id', $lib_id);
|
||||
$this->db->update('library', $xr);
|
||||
}
|
||||
}
|
||||
|
||||
$data['lib_id'] = $lib_id;
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT '<b>'||title||'</b><br>'||description||'<br>'||detail AS Library,"
|
||||
. " '<a href=\"/bkouser/library?lib_id='||id||'&PROC=EDIT\">Edit</a><div id=\"subdel_'||id||'\" ><input type=button onclick=\"return post_nav_find_action('||id||')\" name=\"manage\" class=\"btn btn-info btn-xs\" value=\"Edit\">"
|
||||
. " <input type=button id=\"dacc'||id||'\" onclick=\"return deleteFaq('||id||')\" name=\"delete\" class=\"btn btn-warning btn-xs\" value=\"Del\"></div>' AS option "
|
||||
. " FROM library ORDER BY id DESC";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Dates', 'Username', 'Name', 'Status', 'Verify Link', 'Action');
|
||||
$this->table->function = 'smart_htmlspecialchars';
|
||||
$data['lib_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_library', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function deletelibrary() {
|
||||
$lib_id = $this->input->get('lib_id');
|
||||
$mysql = "DELETE FROM library WHERE id = " . $lib_id;
|
||||
$this->db->query($mysql);
|
||||
echo 'Deleted - ' . $lib_id;
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
* CREATE TABLE library (
|
||||
id SERIAL,
|
||||
title VARCHAR(150) UNIQUE NOT NULL,
|
||||
description VARCHAR(500) NOT NULL,
|
||||
detail TEXT,
|
||||
updated timestamp without time zone DEFAULT now()
|
||||
);
|
||||
ALTER TABLE ONLY library
|
||||
ADD CONSTRAINT library_id_key UNIQUE (id);
|
||||
|
||||
*/
|
||||
|
||||
public function referterms() {
|
||||
|
||||
$data = array();
|
||||
$data['page_name'] = 'referterms';
|
||||
$data['page_title'] = 'Referer Terms';
|
||||
$data['page_key'] = 'WRB_MAIN_REFER_TERM';
|
||||
|
||||
|
||||
if ($this->input->post()) {
|
||||
$this->savepagetext();
|
||||
}
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_fixededitor', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function postjob() {
|
||||
$data = array();
|
||||
$data['page_name'] = 'postjob';
|
||||
$data['page_title'] = 'Post Job Terms';
|
||||
$data['page_key'] = 'WRB_POST_JOB_TERM';
|
||||
|
||||
if ($this->input->post()) {
|
||||
$this->savepagetext();
|
||||
}
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_fixededitor', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function howitwork() {
|
||||
$data = array();
|
||||
$data['page_name'] = 'howitwork';
|
||||
$data['page_title'] = 'How it works';
|
||||
$data['page_key'] = 'WRB_MAIN_HOWIT_WORK';
|
||||
|
||||
if ($this->input->post()) {
|
||||
$this->savepagetext();
|
||||
}
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_fixededitor', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function fundaccount() {
|
||||
$data = array();
|
||||
$data['page_name'] = 'fundaccount';
|
||||
$data['page_title'] = 'Fund Account';
|
||||
$data['page_key'] = 'WRB_FUND_ACCOUNT';
|
||||
|
||||
if ($this->input->post()) {
|
||||
$this->savepagetext();
|
||||
}
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_fixededitor', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function savepagetext() {
|
||||
|
||||
$textline = $this->sql_escape_func($this->input->post('txt_detail'));
|
||||
$page_key = trim($this->input->post('page_key'));
|
||||
$finalsql = "";
|
||||
if ($page_key != '') {
|
||||
$mysql = "SELECT id FROM general_text WHERE page_key='$page_key'";
|
||||
$query = $this->db->query($mysql);
|
||||
if ($query->num_rows() == 0) {
|
||||
$finalsql = "INSERT INTO general_text (page_key,txt_detail) VALUES('$page_key',E'$textline')";
|
||||
} else {
|
||||
$row = $query->row();
|
||||
$finalsql = "UPDATE general_text SET txt_detail=E'$textline' WHERE page_key='$page_key' AND id=" . $row->id;
|
||||
}
|
||||
}
|
||||
|
||||
if ($finalsql != '') {
|
||||
$this->db->query($finalsql);
|
||||
// echo 'Saved';
|
||||
}
|
||||
}
|
||||
|
||||
public function PrepPagination($perpage, $urlSegment, $pagePath) {
|
||||
|
||||
$config = array();
|
||||
$config["base_url"] = base_url() . $pagePath;
|
||||
$config["per_page"] = $perpage;
|
||||
$config["uri_segment"] = $urlSegment;
|
||||
$config["num_links"] = 5;
|
||||
$config['full_tag_open'] = "<ul class='pagination'>";
|
||||
$config['full_tag_close'] = "</ul>";
|
||||
$config['num_tag_open'] = '<li>';
|
||||
$config['num_tag_close'] = '</li>';
|
||||
$config['cur_tag_open'] = "<li class='disabled'><li class='active'><a href='#'>";
|
||||
$config['cur_tag_close'] = "<span class='sr-only'></span></a></li>";
|
||||
$config['next_tag_open'] = "<li>";
|
||||
$config['next_tagl_close'] = "</li>";
|
||||
$config['prev_tag_open'] = "<li>";
|
||||
$config['prev_tagl_close'] = "</li>";
|
||||
$config['first_tag_open'] = "<li>";
|
||||
$config['first_tagl_close'] = "</li>";
|
||||
$config['last_tag_open'] = "<li>";
|
||||
$config['last_tagl_close'] = "</li>";
|
||||
|
||||
return $config;
|
||||
}
|
||||
|
||||
public function locate() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data['page_title'] = 'Find User';
|
||||
// $config = array();
|
||||
|
||||
$page = ($this->uri->segment(3)) ? $this->uri->segment(3) : 0;
|
||||
$page = is_numeric($page) ? $page : 0;
|
||||
|
||||
|
||||
|
||||
$config = $this->PrepPagination(10, 3, '/bkouser/locate');
|
||||
|
||||
$mysql0 = "SELECT * FROM members";
|
||||
$q = $this->db->query($mysql0);
|
||||
$config["total_rows"] = $q->num_rows();
|
||||
|
||||
$this->load->library('pagination');
|
||||
$this->pagination->initialize($config);
|
||||
$data["pagination_links"] = $this->pagination->create_links();
|
||||
|
||||
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SElECT added::date||'<br>'||loc||'<br>'||(CASE WHEN last_login::date IS NULL THEN ' ' ELSE last_login::date::text END) AS Act,"
|
||||
. " username||'<br>'||firstname||' '||lastname AS Name, "
|
||||
. " '<div id=\"sdd'||id||'\"><button id=\"sel'||id||'\" class=\"btn btn-warning btn-xs\" onclick=\"return selectMember('''||id||''');\" >Select['||id||']</button></div>' AS select "
|
||||
. " FROM members ORDER BY id DESC LIMIT " . $config["per_page"] . " OFFSET " . $page; ;
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Account', 'Created', 'Action');
|
||||
$data['member_search_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_findmembers', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function memberdetail() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_dash', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function contact() {
|
||||
// $this->load->view('bko/view_bko_header', $data);
|
||||
$data = array();
|
||||
$data['page_title'] = 'Site Contacts';
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SElECT added::date||'<br>'||loc||'<br>'||(CASE WHEN last_login::date IS NULL THEN ' ' ELSE last_login::date::text END) AS Act,"
|
||||
. " username||'<br>'||firstname||' '||lastname AS Name, "
|
||||
. " '<div id=\"sdd'||id||'\"><button id=\"sel'||id||'\" class=\"btn btn-warning btn-xs\" onclick=\"return selectMember('''||id||''');\" >Select['||id||']</button></div>' AS select "
|
||||
. " FROM members ORDER BY id DESC LIMIT 100";
|
||||
$mysql = " SELECT created||'<br>'||email||'<br>'||member_id||'<div id=\"sdd'||id||'\"><button id=\"sel'||id||'\" class=\"btn btn-warning btn-xs\" onclick=\"return selectMessage('''||id||''');\" >Select['||id||']</button></div>' AS sender,your_message FROM contacts ORDER BY id desc";
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Account', 'Created', 'Action');
|
||||
|
||||
$data['member_search_table'] = $this->table->generate($query);
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/view_bko_contact', $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
public function replymessage() {
|
||||
//url: "/bkouser/seluser?proc=SEL&member_id="+link_id
|
||||
$contact_id = $this->input->get('contact_id');
|
||||
|
||||
$mysql = "SElECT * "
|
||||
. " FROM contacts WHERE id = " . $contact_id;
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$row = $query->row();
|
||||
|
||||
if (isset($row)) {
|
||||
// echo $row->id;
|
||||
// echo $row->firstname;
|
||||
// echo $row->lastname;
|
||||
//$_SESSION['bko_selected_id'] = $row->id;
|
||||
//$_SESSION['bko_selected_username'] = $row->username;
|
||||
//$_SESSION['bko_selected_row'] = $row;
|
||||
//$_SESSION['bko_selected_memberd_id'] = $member_id;
|
||||
}
|
||||
|
||||
echo 'aaaa ' . $contact_id;
|
||||
}
|
||||
|
||||
public function resend_pending() {
|
||||
$this->load->model('backend_model');
|
||||
$link_id = $this->input->get('link_id');
|
||||
$in = array();
|
||||
$in['pending_id'] = $link_id;
|
||||
$in['action'] = WRENCHBOARD_RESEND_PENDING_LINK;
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($in, $out);
|
||||
|
||||
echo 'Sent';
|
||||
}
|
||||
|
||||
public function delete_pending() {
|
||||
$this->load->model('backend_model');
|
||||
$link_id = $this->input->get('link_id');
|
||||
$in = array();
|
||||
$in['pending_id'] = $link_id;
|
||||
$in['action'] = WRENCHBOARD_DELETE_PENDING_LINK;
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($in, $out);
|
||||
echo 'Deleted';
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
class Browse extends WRB_Controller {
|
||||
|
||||
public function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
public function index() {
|
||||
$data = array();
|
||||
|
||||
$data['page_title'] = "Login WrenchBoard";
|
||||
//$this->load->view('templates/header_boxed', $data);
|
||||
|
||||
|
||||
|
||||
$this->load->view('browse/view_browse', $data);
|
||||
$this->load->view('users/view_external_footer');
|
||||
}
|
||||
|
||||
private function browsePageData()
|
||||
{
|
||||
$mysql = "SELECT id,firstname FROM members";
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,100 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Complereset extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
//echo "ameye kvkgkg";
|
||||
$data['action_message'] = "";
|
||||
$data["message"] = "Enter your new password to reset.<br> We will send you an email to confirm reset";
|
||||
|
||||
if ($_GET) {//this is first load of page
|
||||
$data['passlink'] = $this->input->get('passlink');
|
||||
if ($this->loadLinkData($data['passlink']) == false) {
|
||||
redirect('/home'); // if link is not good - GET OUT
|
||||
}
|
||||
|
||||
$this->load->view('users/view_external_header');
|
||||
$this->load->view('users/view_cmppass', $data);
|
||||
$this->load->view('users/view_external_footer');
|
||||
} else {
|
||||
|
||||
if ($_POST) {
|
||||
$message = "";
|
||||
$data['pass_link'] = $this->input->post('passlink');
|
||||
$data['passlink'] = $this->input->post('passlink');
|
||||
$confirmnewpass = $this->input->post('confirmnewpass');
|
||||
$newpass = $this->input->post('newpass');
|
||||
|
||||
if ($this->loadLinkData($data['pass_link']) == true) {
|
||||
|
||||
if ($newpass == $confirmnewpass && strlen($confirmnewpass) >= 8) {
|
||||
// call backend now
|
||||
$data['description'] = trim($this->input->post('description'));
|
||||
$data['newpass'] = $newpass;
|
||||
|
||||
$outx = array();
|
||||
$this->load->model('backend_model');
|
||||
$data['action'] = WRENCHBOARD_ACCOUNT_SETPASSWD;
|
||||
$outx['error'] = '';
|
||||
if ($this->backend_model->wrenchboard_api($data, $outx) == PHP_API_OK) {
|
||||
$message = "<div class=\"text-left\"><div class=\"alert alert-info no-border\">" . $outx["status"] . "</div></div>";
|
||||
$message = $outx["status"];
|
||||
} else {
|
||||
$message = "<div class=\"text-left\"><div class=\"alert alert-info no-border\">" . $outx["status"] . "</div></div>";
|
||||
$message = $outx["status"];
|
||||
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$message = "Password must be same and over eight characters in length.";
|
||||
}
|
||||
} else {
|
||||
|
||||
$message = "Invalid or expired password reset link. Please restart the process.";
|
||||
}
|
||||
|
||||
$data['action_message'] = "<div class=\"text-left\"><div class=\"alert alert-info no-border\">" . $message . "</div></div>";
|
||||
|
||||
$this->load->view('users/view_external_header');
|
||||
$this->load->view('users/view_cmppass', $data);
|
||||
$this->load->view('users/view_external_footer');
|
||||
}
|
||||
}
|
||||
|
||||
private function loadLinkData($passlink) {
|
||||
$ret = false;
|
||||
|
||||
$query = $this->db->get_where('password_reset', array('pass_link' => $passlink, 'status' => 0));
|
||||
if ($query->num_rows() == 1) {
|
||||
$ret = true;
|
||||
} else {
|
||||
|
||||
}
|
||||
return $ret;
|
||||
}
|
||||
|
||||
var $actionMessage = '';
|
||||
|
||||
private function resetMemberPass($email) {
|
||||
$this->actionMessage = '';
|
||||
//$group_id = $group_id + 0; // just making sure it is number
|
||||
|
||||
|
||||
$x['email'] = $email;
|
||||
|
||||
|
||||
$x['action'] = WRENCHBOARD_ACCOUNT_RESETPASS;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($x, $out);
|
||||
if ($res == PHP_CREATED_OK) {
|
||||
$this->actionMessage = 'Group Created';
|
||||
} else {
|
||||
$this->actionMessage = 'Unable to create job group...';
|
||||
}
|
||||
return $this->actionMessage;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,154 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Confg extends Bko_Controller {
|
||||
|
||||
public function siteitems() {
|
||||
$data["title"] = "Withdraws Report";
|
||||
$mysql = "SELECT m.added::date AS date,m.terminatingamount*0.01 AS amount,m.fee*0.01 as fee, "
|
||||
. "mm.firstname||' '||mm.lastname||'<br>Email:'||mm.email AS Sender,"
|
||||
. "r.firstname||' '||r.lastname||'<br><b>Acc:</b>'||r.account_no||'-'||b.name AS Recitient,mp.confirmation,"
|
||||
. "CASE WHEN m.status=1 THEN 'Pending' WHEN m.status=3 THEN 'Cancelled' WHEN m.status=5 THEN 'Completed' ELSE '' END AS Status "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN sendmoney_recipient r ON r.id = m.recipientid "
|
||||
. " LEFT JOIN members mm ON mm.id = m.member_id "
|
||||
. "LEFT JOIN bank_entity_codes b ON b.code = r.bank_code "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "WHERE mp.confirmation IS NOT NULL ORDER BY m.id DESC LIMIT 4000";
|
||||
|
||||
// $query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Date', 'Amount', 'Fee', 'Recipient', 'Confirmation', 'Status')
|
||||
//$this->table->set_heading('Date', 'Amount','Fee','Recipient','Confirmation', 'Status');
|
||||
// $data['mysql'] = $mysql;
|
||||
// $this->renderbkoreportpage($data);
|
||||
|
||||
$data = array();
|
||||
$data['page_title'] = "Configurations";
|
||||
$this->renderAdminPage('configure/view_bko_configure', $data);
|
||||
}
|
||||
|
||||
public function selpage() {
|
||||
$data = array();
|
||||
|
||||
$data['page_id'] = trim($this->input->get('page_id'));
|
||||
|
||||
if ($data['page_id'] != '') {
|
||||
|
||||
switch ($data['page_id']) {
|
||||
|
||||
case "JOBCATEG":
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
$mysql = "SELECT * FROM skill_category ORDER BY category ASC";
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading(array('data' => 'Key', 'style' => 'width:60px'), 'Reason', array('data' => 'Action', 'style' => 'width:100px'));
|
||||
$data['skill_category_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/configure/extra/jobcaregory_form', $data);
|
||||
break;
|
||||
|
||||
case "JOBSKILLTYPE":
|
||||
|
||||
echo 'akkfkkg';
|
||||
break;
|
||||
|
||||
case "AREASON":
|
||||
case "MREASON":
|
||||
|
||||
$mysql = "SELECT * FROM reason_type WHERE rkey='" . $data['page_id'] . "'";
|
||||
$q = $this->db->query($mysql);
|
||||
$row = $q->row();
|
||||
if (isset($row)) {
|
||||
$data['reason_name'] = $row->rname;
|
||||
$data['reason_key'] = $row->rkey;
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT lkey,name,'<button onclick=\"deleteReason('||id||'.'||lkey||');\">Del</button>' FROM reason_items WHERE rkey='" . $data['page_id'] . "'"; // WHERE agent_id = " . $data['agent_id'];
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading(array('data' => 'Key', 'style' => 'width:60px'), 'Reason', array('data' => 'Action', 'style' => 'width:100px'));
|
||||
$data['reason_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/configure/extra/reason_form', $data);
|
||||
}
|
||||
break;
|
||||
case "LANGUAGE":
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT * FROM languages ORDER BY language ASC"; // WHERE agent_id = " . $data['agent_id'];
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading(array('data' => 'Key', 'style' => 'width:60px'), 'Reason', array('data' => 'Action', 'style' => 'width:100px'));
|
||||
$data['language_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/configure/extra/language_form', $data);
|
||||
break;
|
||||
case "COUNTRY":
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT * FROM country ORDER BY country ASC"; // WHERE agent_id = " . $data['agent_id'];
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading(array('data' => 'Key', 'style' => 'width:60px'), 'Reason', array('data' => 'Action', 'style' => 'width:100px'));
|
||||
$data['country_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/configure/extra/country_form', $data);
|
||||
|
||||
break;
|
||||
|
||||
case "UTRANSPRICE":
|
||||
$data["form_title"] = "User Transport Pricing";
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT * FROM country ORDER BY country ASC"; // WHERE agent_id = " . $data['agent_id'];
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading(array('data' => 'Key', 'style' => 'width:60px'), 'Reason', array('data' => 'Action', 'style' => 'width:100px'));
|
||||
$data['country_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/configure/extra/pricing_form', $data);
|
||||
|
||||
break;
|
||||
|
||||
case "ULATORPRICE":
|
||||
$data["form_title"] = "User Translator Pricing";
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT * FROM country ORDER BY country ASC"; // WHERE agent_id = " . $data['agent_id'];
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading(array('data' => 'Key', 'style' => 'width:60px'), 'Reason', array('data' => 'Action', 'style' => 'width:100px'));
|
||||
$data['country_table'] = $this->table->generate($query);
|
||||
$this->load->view('bko/configure/extra/pricing_form', $data);
|
||||
|
||||
break;
|
||||
|
||||
default:
|
||||
echo "Your favorite color is neither red, blue, nor green!";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public function addSkill() {
|
||||
$data = array();
|
||||
|
||||
$data['rkey'] = trim($this->input->get('page_id'));
|
||||
$data['skill_name'] = trim($this->input->get('skill_name'));
|
||||
|
||||
$mysql = "SELECT * FROM skill_category WHERE LOWER(category) = LOWER('" . $data['skill_name'] . "')";
|
||||
$q = $this->db->query($mysql);
|
||||
$nr = $q->num_rows();
|
||||
if ($nr > 0) {
|
||||
echo 'Duplicate Detected';
|
||||
} else {
|
||||
// echo 'Now Insert';
|
||||
$mysql = "INSERT INTO skill_category (category) VALUES('" . $data['skill_name'] . "')";
|
||||
$q = $this->db->query($mysql);
|
||||
}
|
||||
|
||||
|
||||
echo '0';
|
||||
}
|
||||
|
||||
private function renderAdminPage($page_name, $data) {
|
||||
|
||||
$this->load->view('bko/view_bko_header', $data);
|
||||
$this->load->view('bko/' . $page_name, $data);
|
||||
$this->load->view('bko/view_bko_footer', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,91 @@
|
||||
<?php
|
||||
|
||||
class Contact extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
$data['title'] = "Contact"; // Capitalize the first letter
|
||||
$data['page_title'] = "Contact WrenchBoard";
|
||||
|
||||
$message = "";
|
||||
|
||||
$email = NULL;
|
||||
$firstname = NULL;
|
||||
$lastname = NULL;
|
||||
$your_message = NULL;
|
||||
$submit = NULL;
|
||||
$data['message'] ='';
|
||||
extract($_POST);
|
||||
|
||||
if ($_POST) {
|
||||
$resp = $this->input->post('h-captcha-response');
|
||||
$secret = "0x608809f0227f7FA577E069524805cC25f5E732C0";
|
||||
$url = "https://hcaptcha.com/siteverify";
|
||||
$data = array(
|
||||
"secret" => $secret,
|
||||
"response" => $resp
|
||||
);
|
||||
$ch = curl_init();
|
||||
curl_setopt($ch,CURLOPT_URL, $url);
|
||||
curl_setopt($ch,CURLOPT_POST, count($data));
|
||||
curl_setopt($ch,CURLOPT_POSTFIELDS, http_build_query($data));
|
||||
curl_setopt($ch,CURLOPT_RETURNTRANSFER, TRUE);
|
||||
$result = curl_exec($ch);
|
||||
curl_close($ch);
|
||||
$captcha = json_decode($result,true);
|
||||
if (is_array($captcha) && array_key_exists("success",$captcha) && $captcha["success"]) {
|
||||
// Ok
|
||||
$message = '';
|
||||
} else {
|
||||
$message = 'Please verify that you are human';
|
||||
}
|
||||
|
||||
$email = $this->input->post('email');
|
||||
$firstname = $this->input->post('firstname');
|
||||
$lastname = $this->input->post('lastname');
|
||||
$your_message = $this->input->post('msg');
|
||||
|
||||
if ($firstname == '' || $lastname == '') {
|
||||
$message = 'Both first and last name are required';
|
||||
}
|
||||
|
||||
if ($your_message=='' || strlen($your_message)>500) {
|
||||
$message = 'Message is required and must be up to 500 characters long';
|
||||
}
|
||||
|
||||
if ($email=='' || !filter_var($email, FILTER_VALIDATE_EMAIL)) {
|
||||
$message = 'Invalid e-mail';
|
||||
}
|
||||
|
||||
if ($message == '') {
|
||||
$data['email'] = $email;
|
||||
$data['firstname'] = $firstname;
|
||||
$data['lastname'] = $lastname;
|
||||
$data['your_message'] = $your_message;
|
||||
$data['loc'] = $_SERVER['REMOTE_ADDR']; //'38.101.241.200';
|
||||
$data['action'] = WRENCHBOARD_SEND_CONTACTUS;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($data, $out);
|
||||
$message = "Your message was sent";
|
||||
$email = $firstname = $lastname = $your_message = "";
|
||||
} else {
|
||||
//$message = 'Invalid input';
|
||||
$your_message = substr($your_message,0,500);
|
||||
}
|
||||
$data['message'] = "<div class=\"text-left\"><div class=\"alert alert-info no-border\">" . $message . "</div></div>";
|
||||
}
|
||||
|
||||
// $data['message'] = $message;
|
||||
$data['email'] = $email;
|
||||
$data['firstname'] = $firstname;
|
||||
$data['lastname'] = $lastname;
|
||||
$data['msg'] = $your_message;
|
||||
|
||||
//print_r($data);
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_contact', $data);
|
||||
$this->load->view('users/view_external_footer', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,306 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Dash extends Users_Controller {
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
}
|
||||
}
|
||||
|
||||
public function index() {
|
||||
|
||||
$data['username'] = $_SESSION['username']; // = $this->input->post('username');
|
||||
$data['name'] = $_SESSION['name']; // = $this->input->post('username');
|
||||
$data['firstname'] = $_SESSION['firstname']; // = $ret->firstname;
|
||||
$data['lastname'] = $_SESSION['lastname']; // = $ret->lastname;
|
||||
$data['email'] = $_SESSION['email']; // = $ret->email;
|
||||
$data['member_id'] = $_SESSION['member_id']; // = $ret->email;
|
||||
// print_r($_SESSION);
|
||||
//Array ( [__ci_last_regenerate] => 1474689025 [username] => ses66181+1@gmail.com [name] => ses66181+1@gmail.com [firstname] => Olusesan [lastname] => Amey [email] => ses66181+1@gmail.com )
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
} else {
|
||||
// load the Dash model now
|
||||
$this->load->model('dash_model');
|
||||
$out = $this->dash_model->getDashData($data);
|
||||
|
||||
$data = $this->getSessionArray();
|
||||
|
||||
// print_r($out[0]);
|
||||
$data['active_task'] = $out['active_task'];
|
||||
$data['active_pass_due'] = $out['active_pass_due'];
|
||||
$data['current_balance'] = $out['current_balance'];
|
||||
$data['new_message'] = $out['new_message'];
|
||||
$data['total_jobs'] = $out['total_jobs'];
|
||||
$data['offer_dash'] = '';
|
||||
|
||||
// Review to another location
|
||||
|
||||
$mysql = "SELECT to_char(mi.added, 'YYYY-MM-DD HH24:MI') AS added,jo.offer_code,mjs.title,"
|
||||
. "m.firstname||' '||m.lastname AS Client "
|
||||
. "FROM members_offer_interest mi "
|
||||
. "LEFT JOIN members m ON m.id = mi.member_id "
|
||||
. "LEFT JOIN members_jobs_offer jo ON jo.id=mi.offer_id "
|
||||
. "LEFT JOIN members_jobs mjs ON mjs.id=jo.job_id "
|
||||
. "WHERE jo.member_id =" . $_SESSION['member_id'] . " "
|
||||
. "AND mi.status=1 AND jo.expire> now() + '-3 days' ORDER BY mi.added ASC";
|
||||
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$data["offer_interest_count"] = $query->num_rows();
|
||||
$_SESSION['offer_interest_count'] = $data["offer_interest_count"];
|
||||
|
||||
|
||||
$mysql = "SELECT '<b>Project ID:</b>'||mc.contract||'<br><b>Title:</b>'||mc.title AS Project,m.firstname||' '||m.lastname AS Client,"
|
||||
. " '<b>Timeline:</b> '||mc.timeline_days||' day(s)<br><b>Price:</b>'||mc.price*0.01 ,mc.description, "
|
||||
. " (CASE WHEN mc.status = 1 AND mc.delivery_date > now() THEN 'Active' WHEN mc.status = 1 AND mc.delivery_date <now() THEN 'Past Due' "
|
||||
. " WHEN mc.status = 4 THEN 'Review' ELSE 'Not Set' END) AS status "
|
||||
. " FROM members_jobs_contract mc LEFT JOIN members m ON m.id=mc.client_id WHERE mc.member_id = " . $_SESSION['member_id'] . " AND mc.status IN (1,2) "
|
||||
. " AND delivery_date < now()";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$data["past_duejobs_count"] = $query->num_rows();
|
||||
$_SESSION['past_duejobs_count'] = $data["past_duejobs_count"];
|
||||
//======================= move it
|
||||
/* Table Slider Data */
|
||||
|
||||
$jbx = "''/proj/thisjob''";
|
||||
$mysql = "SELECT '<b>ID:</b><a href=\"#\" onclick=\"showJobModal('''||mc.contract||''');\" >'||mc.contract||'</a><br><b>Timeline:</b>'||mc.timeline_days||' day(s)<br><b>Price:</b>'||mc.price*0.01 AS Project,"
|
||||
. " '<b>Title: </b>'||mc.title||'<br><b>Description: </b>'||mc.description AS description,"
|
||||
. " (CASE WHEN mc.status=4 THEN '<input type=submit onclick=\"return post_nav_find_action($jbx, '||mc.id||')\" name=\"manage\" class=\"btn btn-info btn-xs btn-block\" value=\"Review\">' "
|
||||
. " WHEN mc.status = 1 AND mc.delivery_date > now() THEN '<input type=submit onclick=\"return post_nav_find_action($jbx, '||mc.id||')\" name=\"manage\" class=\"btn btn-success btn-xs btn-block\" value=\"View\">' "
|
||||
. " WHEN mc.status = 1 AND mc.delivery_date <now() THEN '<span class=\"label label-flat border-danger text-danger-600\">PastDue</span>' "
|
||||
. " ELSE '<input type=submit onclick=\"return post_nav_find_action($jbx, '||mc.id||')\" name=\"manage\" class=\"btn btn-info btn-xs btn-block\" value=\"View\">' END) AS manage "
|
||||
. " FROM members_jobs_contract mc LEFT JOIN members m ON m.id=mc.client_id "
|
||||
. " WHERE mc.member_id = " . $_SESSION['member_id'] . " AND mc.status IN (1,2,4) AND mc.delivery_date > now() "
|
||||
. " OR mc.client_id =" . $_SESSION['member_id'] . " AND mc.status IN (1,2,4) AND mc.delivery_date > now() LIMIT 4";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$this->table->set_heading(array('data' => 'Job', 'style' => 'width:180px'), 'Title/Description', array('data' => '', 'style' => 'width:100px; cellpadding:0px;'));
|
||||
|
||||
$data['job_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$x = $this->dashTaskMessage();
|
||||
$data['job_message_table'] = $x['job_message_table'];
|
||||
/// End table data ===========================
|
||||
|
||||
|
||||
|
||||
/*
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
//$this->table->set_heading('Job', 'Client', 'Terms', 'Description', 'Manage', 'Status');
|
||||
$mysql = 'SELECT jo.added::date,jo.member_id,j.title,'
|
||||
. 'CASE WHEN jo.status = 1 THEN \'Pending\' ELSE \'Other\' END AS status'
|
||||
. 'FROM members_jobs_offer jo LEFT JOIN members_jobs j ON j.id = jo.job_id LIMIT 5';
|
||||
// $sqb =" ,'<button type=\"button\" class=\"btn btn-primary btn-xs\">View</button>' As View ";
|
||||
$jbx = "''jobs/viewjob''";
|
||||
$mysql = "SELECT jo.added::date,j.title,"
|
||||
. 'CASE WHEN jo.status = 1 THEN \'Pending\' ELSE \'Other\' END AS status,'
|
||||
. "'<input type=submit onclick=\"return post_nav_find_action($jbx,'''||jo.offer_code||''')\" name=\"manage\" class=\"btn btn-primary btn-xs\" value=\"View\">' AS View "
|
||||
. "FROM members_jobs_offer jo LEFT JOIN members_jobs j ON j.id = jo.job_id "
|
||||
. "WHERE jo.expire > now() AND jo.status = 1 "
|
||||
. "AND jo.client_id = " . $_SESSION['member_id'] . "LIMIT 4";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$num = $query->num_rows();
|
||||
|
||||
$data["dash_title"] = "Pending Offer(s)";
|
||||
if ($num > 0) {
|
||||
$this->table->set_heading('Added', 'Title', 'Status', '');
|
||||
$data['offer_dash'] = $this->table->generate($query);
|
||||
} else {
|
||||
$data["offer_dash"] = "<div class=\"thumb\"><img src='assets/images/notask.png' alt=\"Active Projects\"></div>";
|
||||
}
|
||||
*/
|
||||
|
||||
$ya = array();
|
||||
$ya = $this->dash_title();
|
||||
$data["dash_title"] = $ya["dash_title"];
|
||||
$data["offer_dash"] = $ya["offer_dash"];
|
||||
|
||||
$_SESSION['secure_data'] = $data; // all data needed for secure page
|
||||
// print_r($_SESSION);
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_dash', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
}
|
||||
|
||||
private function dashTaskMessage() {
|
||||
$data = array();
|
||||
/*
|
||||
wrenchboard=> select s.created,j.contract,j.title,j.id,j.status,j.delivery_date,substring(s.message,0,100) FROM members_jobs_contract j RIGHT JOIN jobs_contract_message s ON s.contract=j.contract WHERE j.member_id=3 or j.client_id = 3 AND j.status IN (1,4);
|
||||
created | contract | title | id | status | delivery_date | substring
|
||||
----------------------------+------------+-----------------------------------------------+----+--------+----------------------------+-----------------------------------------------------------------------------------------------------
|
||||
2017-05-18 11:53:20.569399 | 7BW9B9R8BB | five thousand naira | 13 | 1 | 2017-08-02 14:19:38.711257 | This is a test of ajax send message
|
||||
2017-05-18 12:03:30.685328 | 7B27RRBRB7 | 595Job Title Job Title Job Title Job Title932 | 15 | 4 | 2017-05-10 19:23:26.115394 | dldldldldldl
|
||||
2017-05-18 12:03:44.137005 | 7B27RRBRB7 | 595Job Title Job Title Job Title Job Title932 | 15 | 4 | 2017-05-10 19:23:26.115394 | This is an empty list test
|
||||
2017-05-18 12:04:00.228586 | 7B27RRBRB7 | 595Job Title Job Title Job Title Job Title932 | 15 | 4 | 2017-05-10 19:23:26.115394 | List should be populated now
|
||||
2017-05-18 20:49:12.996077 | 7BW9B9R8BB | five thousand naira | 13 | 1 | 2017-08-02 14:19:38.711257 | About PayQuic\r +
|
||||
| | | | | | PayQuic is global payments and airtime top-up company. Open for business 24/7, 365 d
|
||||
2017-06-12 10:28:32.720786 | 601BBWRW48 | 595Job Title Job Title Job Title Job Title932 | 10 | 1 | 2017-08-09 16:08:43.503739 | <table><tbody><tr><td><div><span><br>can you share your controller method and did you tried <c
|
||||
2017-06-12 10:28:41.932836 | 601BBWRW48 | 595Job Title Job Title Job Title Job Title932 | 10 | 1 | 2017-08-09 16:08:43.503739 | <table><tbody><tr><td><div><span><br>can you share your controller method and did you tried <c
|
||||
|
||||
*/
|
||||
$jbx = "''/proj/thisjob''";
|
||||
|
||||
$mysql = " SELECT s.created,j.contract,j.title,j.id,j.status,j.delivery_date,substring(s.message,0,100),"
|
||||
. " '<input type=submit onclick=\"return post_nav_find_action($jbx, '||j.id||')\" name=\"manage\" class=\"btn btn-success btn-xs btn-block\" value=\"View\">' "
|
||||
. " FROM members_jobs_contract j "
|
||||
. " RIGHT JOIN jobs_contract_message s ON s.contract=j.contract "
|
||||
. " WHERE j.member_id=" . $_SESSION['member_id'] . " OR j.client_id = " . $_SESSION['member_id'] . " AND j.status IN (1,4)";
|
||||
|
||||
$mysql = " SELECT s.created::date ||'<br>'||j.contract AS date_contract,'<b>Title:</b>'||j.title||'<br>'||substring(s.message,0,90) as title_message,"
|
||||
. " '<input type=submit onclick=\"return post_nav_find_action($jbx, '||j.id||')\" name=\"manage\" class=\"btn btn-success btn-xs btn-block\" value=\"View\">' "
|
||||
. " FROM members_jobs_contract j "
|
||||
. " RIGHT JOIN jobs_contract_message s ON s.contract=j.contract "
|
||||
. " WHERE j.member_id=" . $_SESSION['member_id'] . " AND j.delivery_date IS NOT NULL AND j.delivery_date > now() OR j.client_id = " . $_SESSION['member_id'] . " AND j.status IN (1,4) AND j.delivery_date IS NOT NULL AND j.delivery_date > now() LIMIT 5";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$this->table->set_heading(array('data' => 'Date', 'style' => 'width:180px'), 'Title/Message', array('data' => '', 'style' => 'width:100px; cellpadding:0px;'));
|
||||
|
||||
$data['job_message_table'] = $this->table->generate($query);
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
private function dash_title() {
|
||||
|
||||
$offer_found = false;
|
||||
|
||||
$data = array();
|
||||
$data['offer_dash'] = '';
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
$jbx = "''/jobs/viewjob''";
|
||||
$mysql = "SELECT jo.added::date,j.title,"
|
||||
. "'<input type=submit onclick=\"return post_nav_find_action($jbx,'''||jo.offer_code||''')\" name=\"manage\" class=\"btn btn-primary btn-xs\" value=\"View\">' AS View "
|
||||
. "FROM members_jobs_offer jo LEFT JOIN members_jobs j ON j.id = jo.job_id "
|
||||
. "WHERE jo.expire > now() AND jo.status = 1 "
|
||||
. "AND jo.client_id = " . $_SESSION['member_id'] . " LIMIT 4";
|
||||
// . 'CASE WHEN jo.status = 1 THEN \'Pending\' ELSE \'Other\' END AS status,'
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$num = $query->num_rows();
|
||||
|
||||
$data["dash_title"] = "Pending Offer(s)";
|
||||
if ($num > 0) {
|
||||
|
||||
|
||||
|
||||
// array('data' => 'Added', 'style' => 'width:80px')
|
||||
|
||||
$this->table->set_heading(array('data' => 'Added', 'style' => 'width:80px'), 'Title', array('data' => '', 'style' => 'width:80px'));
|
||||
$data['offer_dash'] = $this->table->generate($query);
|
||||
$offer_found = true;
|
||||
} else {
|
||||
$data["offer_dash"] = "<div class=\"thumb\"><img src='assets/images/notask.png' alt=\"Active Projects\"></div>";
|
||||
}
|
||||
|
||||
|
||||
if ($offer_found == false) {
|
||||
$data["dash_title"] = "<a href='/jobs/pendingoffer'>My Pending Offer(s)</a>";
|
||||
$jbx = "''/jobs/viewmyjob''";
|
||||
$mysql = "SELECT jo.added::date||'<br>'||jo.expire::date,j.title||'<br><b>To :</b>'||(CASE WHEN jo.public_view > 0 THEN '-Public View' ELSE jo.email END) AS tRec,"
|
||||
. 'CASE WHEN jo.status = 1 AND jo.public_view =0 THEN \'Pending\' WHEN jo.status = 1 AND jo.public_view >0 THEN \'Active\' ELSE \'Other\' END AS status,'
|
||||
. "'<input type=submit onclick=\"return post_nav_find_action($jbx,'''||jo.offer_code||''')\" name=\"manage\" class=\"btn btn-primary btn-xs\" value=\"View\">' AS View "
|
||||
. "FROM members_jobs_offer jo LEFT JOIN members_jobs j ON j.id = jo.job_id "
|
||||
. "WHERE jo.expire > now() AND jo.status = 1 "
|
||||
. "AND jo.member_id = " . $_SESSION['member_id'] . " ORDER BY jo.id DESC LIMIT 4";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$num = $query->num_rows();
|
||||
|
||||
if ($num > 0) {
|
||||
// array('data' => 'Status', 'style' => 'width:150px')
|
||||
//array('data' => 'Added', 'style' => 'width:150px')
|
||||
//array('data' => 'Added', 'style' => 'width:150px')
|
||||
|
||||
$this->table->set_heading(array('data' => 'Added/Expire', 'style' => 'width:120px'), 'Title/Recipient', array('data' => 'Status', 'style' => 'width:100px'), array('data' => '', 'style' => 'width:100px'));
|
||||
$data['offer_dash'] = $this->table->generate($query);
|
||||
$offer_found = true;
|
||||
}
|
||||
}
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
public function howitworks() {
|
||||
$data = $this->getSessionArray();
|
||||
|
||||
$data['page_key'] = 'WRB_MAIN_HOWIT_WORK';
|
||||
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
|
||||
|
||||
$data['txt_detail'] = str_replace("[how-it-worked-image-1]", "<img src='/assets/images/howitworks/howitworks-1.jpg' alt=''>", $data['txt_detail']);
|
||||
$data['txt_detail'] = str_replace("[how-it-worked-image-2]", "<img src='/assets/images/howitworks/howitworks-2.jpg' alt=''>", $data['txt_detail']);
|
||||
|
||||
$data['page_title'] = "How it Works";
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_howitworks', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
//echo "here-here";
|
||||
}
|
||||
|
||||
public function howfindwork() {
|
||||
$data = $this->getSessionArray();
|
||||
|
||||
$data['page_key'] = 'WRB_MAIN_HOWIT_WORK';
|
||||
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
|
||||
|
||||
$data['txt_detail'] = str_replace("[how-it-worked-image-1]", "<img src='/assets/images/howitworks/howitworks-1.jpg' alt=''>", $data['txt_detail']);
|
||||
$data['txt_detail'] = str_replace("[how-it-worked-image-2]", "<img src='/assets/images/howitworks/howitworks-2.jpg' alt=''>", $data['txt_detail']);
|
||||
|
||||
$data['page_title'] = "How to find Job";
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_howfindjob', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
//echo "here-here";
|
||||
}
|
||||
|
||||
public function howpostjob() {
|
||||
$data = $this->getSessionArray();
|
||||
|
||||
$data['page_key'] = 'WRB_MAIN_HOWIT_WORK';
|
||||
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
|
||||
|
||||
$data['txt_detail'] = str_replace("[how-it-worked-image-1]", "<img src='/assets/images/howitworks/howitworks-1.jpg' alt=''>", $data['txt_detail']);
|
||||
$data['txt_detail'] = str_replace("[how-it-worked-image-2]", "<img src='/assets/images/howitworks/howitworks-2.jpg' alt=''>", $data['txt_detail']);
|
||||
|
||||
$data['page_title'] = "How to Post Job";
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_howpostjob', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
//echo "here-here";
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
class Eoffer extends CI_Controller {
|
||||
|
||||
public function __construct() {
|
||||
parent::__construct();
|
||||
// Load library and url helper
|
||||
//$this->load->library('facebook');
|
||||
//$this->load->helper('url');
|
||||
$this->load->library(array('session', 'lib_login'));
|
||||
}
|
||||
|
||||
public function index() {
|
||||
$data["login_message"] = "";
|
||||
$data['offerID'] = $this->input->get('offerID'); // '08174596144';
|
||||
|
||||
$data['title'] = "Login"; // Capitalize the first letter
|
||||
$data['page_title'] = "Login WrenchBoard";
|
||||
//$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_login', $data);
|
||||
$this->load->view('users/view_external_footer');
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
class Faq extends WRB_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
|
||||
$data['faq_table'] = '';
|
||||
$query = $this->db->query('SELECT * FROM faq');
|
||||
|
||||
foreach ($query->result() as $row) {
|
||||
|
||||
$data['faq_table'] .= "<div class=\"panel panel-white\"> "
|
||||
. "<div class=\"panel-heading\"> "
|
||||
. " <h6 class=\"panel-title\">"
|
||||
. " <a data-toggle=\"collapse\" data-parent=\"#accordion-control\" href=\"#accordion-control-group" . $row->id . "\">" . $row->title . "</a> "
|
||||
. " </h6> "
|
||||
. " </div> "
|
||||
. " <div id=\"accordion-control-group" . $row->id . "\" class=\"panel-collapse collapse out\"> "
|
||||
. " <div class=\"panel-body\">" .htmlspecialchars_decode( $row->msg ) . " "
|
||||
. " </div>"
|
||||
. " </div> "
|
||||
. " </div>";
|
||||
}
|
||||
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_homefaq', $data);
|
||||
$this->load->view('users/view_external_footer');
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Home extends WRB_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
$this->home1('');
|
||||
}
|
||||
|
||||
public function about() {
|
||||
|
||||
$this->home2('home2/about');
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Invite extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
//echo "ameye kvkgkg";
|
||||
/* $data['sitename'] = 'home';
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_index');
|
||||
$this->load->view('users/view_external_footer');
|
||||
*/
|
||||
|
||||
//define('WRENCHBOARD_ACCOUNT_REFERLINK',11033);
|
||||
|
||||
redirect('/registration');
|
||||
}
|
||||
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,667 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Jobs extends CI_Controller {
|
||||
|
||||
var $actionMessage = '';
|
||||
var $template = array(
|
||||
'table_open' => "<table class='table table-striped table-hover table-bordered table-condensed'>",
|
||||
'thead_open' => '<thead>',
|
||||
'thead_close' => '</thead>',
|
||||
'heading_row_start' => '<tr>',
|
||||
'heading_row_end' => '</tr>',
|
||||
'heading_cell_start' => '<th>',
|
||||
'heading_cell_end' => '</th>',
|
||||
'tbody_open' => '<tbody>',
|
||||
'tbody_close' => '</tbody>',
|
||||
'row_start' => '<tr>',
|
||||
'row_end' => '</tr>',
|
||||
'cell_start' => '<td>',
|
||||
'cell_end' => '</td>',
|
||||
'row_alt_start' => '<tr>',
|
||||
'row_alt_end' => '</tr>',
|
||||
'cell_alt_start' => '<td>',
|
||||
'cell_alt_end' => '</td>',
|
||||
'table_close' => '</table>'
|
||||
);
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
}
|
||||
}
|
||||
|
||||
public function index() {
|
||||
|
||||
$data['username'] = $_SESSION['username']; // = $this->input->post('username');
|
||||
$data['name'] = $_SESSION['name']; // = $this->input->post('username');
|
||||
$data['firstname'] = $_SESSION['firstname']; // = $ret->firstname;
|
||||
$data['lastname'] = $_SESSION['lastname']; // = $ret->lastname;
|
||||
$data['email'] = $_SESSION['email']; // = $ret->email;
|
||||
// print_r($_SESSION);
|
||||
//Array ( [__ci_last_regenerate] => 1474689025 [username] => ses66181+1@gmail.com [name] => ses66181+1@gmail.com [firstname] => Olusesan [lastname] => Amey [email] => ses66181+1@gmail.com )
|
||||
//
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
} else {
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_active', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
}
|
||||
|
||||
public function active() {
|
||||
|
||||
$data['username'] = $_SESSION['username']; // = $this->input->post('username');
|
||||
$data['name'] = $_SESSION['name']; // = $this->input->post('username');
|
||||
$data['firstname'] = $_SESSION['firstname']; // = $ret->firstname;
|
||||
$data['lastname'] = $_SESSION['lastname']; // = $ret->lastname;
|
||||
$data['email'] = $_SESSION['email']; // = $ret->email;
|
||||
// print_r($_SESSION);
|
||||
//Array ( [__ci_last_regenerate] => 1474689025 [username] => ses66181+1@gmail.com [name] => ses66181+1@gmail.com [firstname] => Olusesan [lastname] => Amey [email] => ses66181+1@gmail.com )
|
||||
//
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
} else {
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_active', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
}
|
||||
|
||||
public function viewjob() {
|
||||
$data = $this->getSessionArray();
|
||||
$jobOfferID = $this->input->post('jobOfferID');
|
||||
$data['jobOfferID'] = $jobOfferID;
|
||||
if ($jobOfferID != '') {
|
||||
$this->load->model('job_model');
|
||||
$out = $this->job_model->loadJobOffer($_SESSION['member_id'], $jobOfferID);
|
||||
|
||||
// print_r($out);
|
||||
if ($out['result'] == 1) {
|
||||
|
||||
$data["added_date"] = $out["added_date"];
|
||||
$data["title"] = $out["title"];
|
||||
$data["description"] = $out["description"];
|
||||
$data["timeline_days"] = $out["timeline_days"];
|
||||
$data["price"] = $out["price"];
|
||||
$data["offer_code"] = $out["offer_code"];
|
||||
$data["job_description"] = $out["job_description"];
|
||||
$date = date_create($out["expire"]);
|
||||
$out["expire"] = date_format($date, 'Y-m-d H:i');
|
||||
$data["expire"] = $out["expire"];
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('jobs/view_viewjoboffer', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
} else {
|
||||
redirect('dash'); // go back to dash if not valid
|
||||
}
|
||||
} else {
|
||||
redirect('dash'); // go back to dash if not valid
|
||||
}
|
||||
}
|
||||
|
||||
public function market() {
|
||||
|
||||
$data = array();
|
||||
$data = $this->getSessionArray();
|
||||
$data['offer_dash'] = '';
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
|
||||
/*
|
||||
*
|
||||
* wrenchboard=> SELECT mj.title,mj.description,mj.timeline_days,mj.price,jo.job_description FROM members_jobs_offer jo LEFT JOIN members_jobs mj ON mj.id=jo.job_id WHERE mj.status=1 AND jo.status=1 LIMIT 5;
|
||||
title | description | timeline_days | price | job_description
|
||||
-----------------------------------------------+-----------------------------------------------------------------------------+---------------+-------+----------------------------------------------------------------------------------------------------------------------------------------
|
||||
595Job Title Job Title Job Title Job Title932 | Job descriptionJob descriptionJob descriptionJob descriptionJob description | 2 | 4000 | Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail
|
||||
351Job Title Job Title Job Title Job Title923 | Job descriptionJob descriptionJob descriptionJob descriptionJob description | 3 | 1000 | Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail
|
||||
595Job Title Job Title Job Title Job Title932 | Job descriptionJob descriptionJob descriptionJob descriptionJob description | 2 | 4000 | Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail
|
||||
Test the ste for erro | Yes I am test | 7 | 10000 | Yes I am test
|
||||
595Job Title Job Title Job Title Job Title932 | Job descriptionJob descriptionJob descriptionJob descriptionJob description | 2 | 4000 | Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail Job job_detail
|
||||
(5 rows)
|
||||
*
|
||||
*/
|
||||
|
||||
$data["dash_title"] = "Available Jobs & Tasks";
|
||||
|
||||
$mysql = 'SELECT jo.offer_code,mj.title,mj.description,mj.timeline_days,mj.price,jo.job_description FROM members_jobs_offer jo '
|
||||
. ' LEFT JOIN members_jobs mj ON mj.id=jo.job_id '
|
||||
. ' WHERE mj.status=1 AND jo.status=1 '
|
||||
. ' AND expire> now() AND public_view > 0';
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$num = $query->num_rows();
|
||||
|
||||
if ($num > 0) {
|
||||
$myTable = "<table class='table table-striped table-hover table-bordered table-condensed'>";
|
||||
|
||||
foreach ($query->result_array() as $row) {
|
||||
$myTable .= $this->makeMarketTableRow($row);
|
||||
}
|
||||
|
||||
$myTable .="</table>";
|
||||
// $this->table->set_heading('Added/Expire', 'Title/Recipient', 'Status', '');
|
||||
$data['market_table'] = $myTable; // $this->table->generate($query);
|
||||
// $offer_found = true;
|
||||
}
|
||||
|
||||
$_SESSION['secure_data'] = $data; // all data needed for secure page
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('jobs/view_market', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
|
||||
private function makeMarketTableRow($row) {
|
||||
return "<tr><td style='width:100px;'><b>" . $row['offer_code'] . "</b></td><td>" . $row['title'] . "</td><td style='width:100px;'><input type=submit id='submit_" . $row['offer_code'] . "' name=\"mview\" onclick=\"return EDetail('" . $row['offer_code'] . "');\" class=\"btn btn-info btn-sm\" value=\"View\"></td></tr>"
|
||||
. "<tr><td colspan = '3'><div id='" . $row['offer_code'] . "'></div></td></tr>";
|
||||
}
|
||||
|
||||
public function showinterest()
|
||||
{
|
||||
$data = $this->getSessionArray();
|
||||
$data['offer_code'] = $this->input->get('job_contract');
|
||||
$data['member_id'] = $_SESSION['member_id']; // just maing sure
|
||||
|
||||
echo 'yes I hot here';
|
||||
}
|
||||
|
||||
|
||||
public function marketdetail() {
|
||||
|
||||
|
||||
$offer_code = $this->input->get('job_contract');
|
||||
|
||||
$mysql = "SELECT jo.offer_code,mj.title,mj.description,mj.timeline_days,mj.price,jo.job_description FROM members_jobs_offer jo "
|
||||
. "LEFT JOIN members_jobs mj ON mj.id=jo.job_id "
|
||||
. " WHERE mj.status=1 AND jo.status=1 AND jo.offer_code ='".$offer_code."' ";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$num = $query->num_rows();
|
||||
|
||||
if ($num > 0) {
|
||||
$row = $query->row_array();
|
||||
$myTable = "<table class='table table-sm table-hover table-bordered table-condensed' style=' background-color: #f1fdd5;'>";
|
||||
$myTable .= $this->makeMarketDetailTableRow($row);
|
||||
$myTable .="</table>";
|
||||
}
|
||||
|
||||
echo $myTable ;
|
||||
}
|
||||
|
||||
private function makeMarketDetailTableRow($row) {
|
||||
return "<tr><td style='width:100px;'><b>Task Code</b></td><td><b>" . $row['offer_code'] . "</b></td></tr>"
|
||||
. "<tr><td><b>Title</b></td><td>" . $row['title'] . "</td></tr>"
|
||||
. "<tr><td><b>Description</b></td><td>" . $row['description'] . "</td></tr>"
|
||||
. "<tr><td><b>Detail</b></td><td>" . $row['job_description'] . "</td></tr>"
|
||||
. "<tr><td><b>Duration</b></td><td>" . $row['timeline_days'] . " day(s)</td></tr>"
|
||||
. "<tr><td><b>Price</b></td><td>" . $row['price'] * 0.01 . " Naira</td></tr>"
|
||||
. "<tr><td><b></b></td><td><input type=submit id='submit_interest_" . $row['offer_code'] . "' name=\"mview\" onclick=\"return SInterest('" . $row['offer_code'] . "');\" class=\"btn btn-success btn-sm\" value=\"Send Interest Request
|
||||
\"></td></tr>"
|
||||
. " ";
|
||||
|
||||
}
|
||||
|
||||
public function viewmyjob()
|
||||
{
|
||||
|
||||
$data = $this->getSessionArray();
|
||||
$jobOfferID = $this->input->post('jobOfferID');
|
||||
$data['jobOfferID'] = $jobOfferID;
|
||||
if ($jobOfferID != '') {
|
||||
$this->load->model('job_model');
|
||||
$out = $this->job_model->readMyloadJobOffer($_SESSION['member_id'], $jobOfferID);
|
||||
|
||||
// print_r($out);
|
||||
if ($out['result'] == 1) {
|
||||
|
||||
$data["job_sent_to"] = $out["job_sent_to"];
|
||||
|
||||
$data["added_date"] = $out["added_date"];
|
||||
$data["title"] = $out["title"];
|
||||
$data["description"] = $out["job_description"];
|
||||
$data["timeline_days"] = $out["timeline_days"];
|
||||
$data["price"] = $out["price"];
|
||||
$data["offer_code"] = $out["offer_code"];
|
||||
$data["job_description"] = $out["job_description"];
|
||||
$date = date_create($out["expire"]);
|
||||
$out["expire"] = date_format($date, 'Y-m-d H:i');
|
||||
$data["expire"] = $out["expire"];
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('jobs/view_viewmyjoboffer', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
} else {
|
||||
redirect('dash'); // go back to dash if not valid
|
||||
}
|
||||
} else {
|
||||
redirect('dash'); // go back to dash if not valid
|
||||
}
|
||||
}
|
||||
|
||||
public function pendingoffer() {
|
||||
$data = array();
|
||||
$data = $this->getSessionArray();
|
||||
$data['offer_dash'] = '';
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
$data["offer_dash"] = "<div class=\"thumb\"><img src='assets/images/notask.png' alt=\"Active Projects\"></div>";
|
||||
|
||||
$data["dash_title"] = "<a href='/jobs/pendingoffer'>My Pending Offer(s)</a>";
|
||||
$jbx = "''/jobs/viewmyjob''";
|
||||
$mysql = "SELECT jo.added::date||'<br>'||jo.expire::date,j.title||'<br><b>To :</b>'||jo.email AS tRec,"
|
||||
. 'CASE WHEN jo.status = 1 THEN \'Pending\' ELSE \'Other\' END AS status,'
|
||||
. "'<input type=submit onclick=\"return post_nav_find_action($jbx,'''||jo.offer_code||''')\" name=\"manage\" class=\"btn btn-primary btn-sm\" value=\"View\">' AS View "
|
||||
. "FROM members_jobs_offer jo LEFT JOIN members_jobs j ON j.id = jo.job_id "
|
||||
. "WHERE jo.expire > now() AND jo.status = 1 "
|
||||
. "AND jo.member_id = " . $_SESSION['member_id'] . "LIMIT 400";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$num = $query->num_rows();
|
||||
|
||||
if ($num > 0) {
|
||||
$this->table->set_heading('Added/Expire', 'Title/Recipient', 'Status', '');
|
||||
$data['offer_dash'] = $this->table->generate($query);
|
||||
$offer_found = true;
|
||||
}
|
||||
|
||||
$_SESSION['secure_data'] = $data; // all data needed for secure page
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('jobs/view_pendingoffer', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
|
||||
public function jobgrp() {
|
||||
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
return;
|
||||
}
|
||||
|
||||
$data = $this->getSessionArray();
|
||||
|
||||
$data["job_message"] = "";
|
||||
$data["group_id"] = 0;
|
||||
|
||||
if ($_POST && isset($_POST['del'])) {
|
||||
$group_id = $this->input->post('del');
|
||||
$data['job_message'] = $this->deleteMemberGroup($group_id);
|
||||
} else if ($_POST && isset($_POST['delmember'])) {
|
||||
$data["group_id"] = $this->input->post('group_id') + 0;
|
||||
$member_id = $this->input->post('delmember') + 0;
|
||||
$data['job_message'] = $this->deleteMemberGroupMember($data["group_id"], $member_id);
|
||||
} else if ($_POST && isset($_POST['group_id'])) {
|
||||
$data["group_id"] = $this->input->post('group_id') + 0;
|
||||
$data['job_message'] = $this->addMemberGroupMember($data["group_id"]);
|
||||
} else if ($_POST) {
|
||||
$group_name = trim($this->input->post('group_name'));
|
||||
|
||||
// echo 'ameye....'.$group_name ;
|
||||
$x = array();
|
||||
$x['member_id'] = $_SESSION['member_id'];
|
||||
$x['group_name'] = $group_name;
|
||||
$x['action'] = WRENCHBOARD_JOB_CREATE_GROUP;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($x, $out);
|
||||
if ($res == PHP_CREATED_OK) {
|
||||
// print_r($out);
|
||||
} else {
|
||||
$data['job_message'] = 'Unable to create job group...';
|
||||
}
|
||||
}
|
||||
|
||||
list($data['group_table'], $groups) = $this->getMembersJobGroup($data["group_id"]);
|
||||
if (count($groups) > 0) {
|
||||
if ($data["group_id"] > 0) {
|
||||
$data["group_name"] = $groups[$data["group_id"]];
|
||||
} else {
|
||||
$data["group_name"] = reset($groups);
|
||||
$data["group_id"] = key($groups);
|
||||
}
|
||||
$data['group_member_table'] = $this->addGroupMemberForm($data["group_id"]) . $this->getJobGroupMembers($data["group_id"]);
|
||||
} else {
|
||||
$data["group_id"] = 0;
|
||||
$data["group_name"] = "";
|
||||
$data["group_member_table"] = "Please add a group";
|
||||
}
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('jobs/view_jobgroup', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
|
||||
public function jobgrp_members() {
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
echo "Denied";
|
||||
return;
|
||||
}
|
||||
$group_id = $this->input->get('group_id');
|
||||
echo $this->addGroupMemberForm($group_id) . $this->getJobGroupMembers($group_id);
|
||||
}
|
||||
|
||||
private function deleteMemberGroup($group_id) {
|
||||
$this->load->model('job_model');
|
||||
return $this->job_model->deleteMemberGroup($group_id);
|
||||
}
|
||||
|
||||
private function deleteMemberGroupMember($group_id, $group_member_id) {
|
||||
$this->load->model('job_model');
|
||||
return $this->job_model->deleteMemberGroupMember($group_id, $group_member_id);
|
||||
}
|
||||
|
||||
private function addMemberGroupMember($group_id) {
|
||||
$firstname = $this->input->post('firstname');
|
||||
$lastname = $this->input->post('lastname');
|
||||
$email = $this->input->post('email');
|
||||
if ($firstname == '')
|
||||
return 'Invalid first name';
|
||||
if ($lastname == '')
|
||||
return 'Invalid last name';
|
||||
if ($email == '' || !filter_var($email, FILTER_VALIDATE_EMAIL))
|
||||
return 'Invalid_e-mail';
|
||||
$this->load->model('job_model');
|
||||
return $this->job_model->addMemberGroupMember($group_id, $firstname, $lastname, $email);
|
||||
}
|
||||
|
||||
private function getJobGroupMembers($group_id) {
|
||||
$this->load->model('job_model');
|
||||
return $this->job_model->getJobGroupMembers($group_id);
|
||||
}
|
||||
|
||||
private function getMembersJobGroup($sel) {
|
||||
$this->load->model('job_model');
|
||||
return $this->job_model->getMembersJobGroup($sel);
|
||||
}
|
||||
|
||||
private function addGroupMemberForm($group_id) {
|
||||
$this->load->model('job_model');
|
||||
return $this->job_model->addGroupMemberForm($group_id);
|
||||
}
|
||||
|
||||
public function create() {
|
||||
|
||||
$data = $this->getSessionArray();
|
||||
$mybalance = 0;
|
||||
$data['job_message'] = '';
|
||||
// print_r($_SESSION);
|
||||
|
||||
$title = NULL;
|
||||
$description = NULL;
|
||||
$job_detail = NULL;
|
||||
$timeline = NULL;
|
||||
// $timeline_days = NULL;
|
||||
$price = NULL;
|
||||
$submit = NULL;
|
||||
|
||||
extract($_POST);
|
||||
$redirected = false;
|
||||
if ($_POST) {
|
||||
$in = array();
|
||||
$in['title'] = $title;
|
||||
$in['description'] = $description;
|
||||
$in['timeline_days'] = $timeline;
|
||||
$in['job_detail'] = $job_detail;
|
||||
$in['price'] = $price * 100;
|
||||
$in['member_id'] = $_SESSION['member_id'];
|
||||
|
||||
$this->load->model('job_model');
|
||||
if ($this->job_model->verifyJobInputs($in) == true) {
|
||||
$in['action'] = WRENCHBOARD_JOB_CREATEJOB;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($in, $out);
|
||||
if ($res == PHP_CREATED_OK) {
|
||||
// print_r($out);
|
||||
if ($out['job_id'] > 0) {
|
||||
|
||||
$this->processingJob($out['job_id']);
|
||||
$redirected = true;
|
||||
}
|
||||
} else {
|
||||
$data['job_message'] = 'Unable to create job...';
|
||||
}
|
||||
} else {
|
||||
$data['job_message'] = 'Enter all required fields';
|
||||
}
|
||||
}
|
||||
|
||||
if ($redirected == false) {
|
||||
$this->load->model('dash_model');
|
||||
$out = $this->dash_model->getDashData($data);
|
||||
$data['active_task'] = $out['active_task'];
|
||||
$data['active_pass_due'] = $out['active_pass_due'];
|
||||
$data['current_balance'] = $out['current_balance'];
|
||||
$data['new_message'] = $out['new_message'];
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('jobs/view_create', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
}
|
||||
|
||||
public function processjob() {
|
||||
$jobID = $this->input->post('jobID');
|
||||
if ($jobID > 0) {
|
||||
$this->processingJob($jobID);
|
||||
// $data = $this->getSessionArray();
|
||||
} else {
|
||||
redirect('/jobs/manage');
|
||||
}
|
||||
}
|
||||
|
||||
private function processingJob($jobID) {
|
||||
// $jobID = $this->input->post('jobID');
|
||||
|
||||
|
||||
if ($jobID > 0) {
|
||||
$data = $this->getSessionArray();
|
||||
|
||||
$this->load->model('combo_model');
|
||||
$data['my_job_group'] = $this->combo_model->getUserJobGroupCombo('job_group', $_SESSION['member_id'], '');
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
$mysql = "SELECT title,description,timeline_days||' day(s)', price*0.01||'Naira' AS price, created::date"
|
||||
. " FROM members_jobs WHERE id =" . $jobID . " AND member_id = " . $_SESSION['member_id'];
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading('Title', 'Description', 'Timeline', 'Price', 'Created');
|
||||
$data['job_table'] = $this->table->generate($query);
|
||||
|
||||
$this->load->model('job_model'); // too bad I have to run again
|
||||
$jobData = $this->job_model->getJob($jobID);
|
||||
$data['job_description'] = $jobData->job_detail;
|
||||
$data['jobID'] = $jobID;
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('jobs/view_joboffer', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
} else {
|
||||
redirect('/jobs/manage');
|
||||
}
|
||||
|
||||
// echo "process job " . $jobID;
|
||||
}
|
||||
|
||||
public function viewjob_accept() {
|
||||
// echo 'home....0';
|
||||
$this->concludeOffer(OFFER_ACCEPT);
|
||||
}
|
||||
|
||||
public function viewjob_reject() {
|
||||
//echo 'home....1';
|
||||
$this->concludeOffer(OFFER_REJECT);
|
||||
}
|
||||
|
||||
public function viewjob_cancel() {
|
||||
//echo 'home....1';
|
||||
$this->concludeOffer(OFFER_CANCEL);
|
||||
}
|
||||
|
||||
private function concludeOffer($offer_result) {
|
||||
//WRENCHBOARD_JOB_OFFER_CONCLUDE
|
||||
$jobOfferID = $this->input->get('jobOfferID');
|
||||
$in = array();
|
||||
$in['offer_code'] = $jobOfferID;
|
||||
$in['member_id'] = $_SESSION['member_id'];
|
||||
$in['offer_result'] = $offer_result;
|
||||
$in['action'] = WRENCHBOARD_JOB_OFFER_CONCLUDE;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($in, $out);
|
||||
if ($out["result"] == "OK") {
|
||||
switch ($offer_result) {
|
||||
|
||||
case OFFER_ACCEPT:
|
||||
echo "You have accepted this offer and we have notified the client. Please go to <a href='/proj/active'>manage page</a> to continue ";
|
||||
break;
|
||||
|
||||
case OFFER_REJECT:
|
||||
echo "You have rejected this offer and we have notified the client.";
|
||||
break;
|
||||
case OFFER_CANCEL:
|
||||
echo "You have cancelled this offer and we have notified the recipient.";
|
||||
break;
|
||||
}
|
||||
}
|
||||
// print_r($out);
|
||||
}
|
||||
|
||||
public function processjob_individ() {
|
||||
$jobID = $this->input->get('jobID');
|
||||
$email = $this->input->get('rec_email');
|
||||
$descr = $this->input->get('jobdescription');
|
||||
if ($jobID == '' || $jobID < 1) {
|
||||
echo "Invalid job ID";
|
||||
return;
|
||||
}
|
||||
if ($email == '' || !filter_var($email, FILTER_VALIDATE_EMAIL)) {
|
||||
echo "Invalid recipient e-mail";
|
||||
return;
|
||||
}
|
||||
if ($descr == '') {
|
||||
echo "Missing job description";
|
||||
return;
|
||||
}
|
||||
$this->sendIndividualJobOffer($jobID, $email, $descr);
|
||||
}
|
||||
|
||||
public function processjob_group() {
|
||||
$jobID = $this->input->get('jobID');
|
||||
$group = $this->input->get('job_group');
|
||||
$descr = $this->input->get('jobdescription');
|
||||
if ($jobID == '' || $jobID < 1) {
|
||||
echo "Invalid job ID";
|
||||
return;
|
||||
}
|
||||
if ($group == '' || $group < 1) {
|
||||
echo "Invalid group";
|
||||
return;
|
||||
}
|
||||
if ($descr == '') {
|
||||
echo "Missing job description";
|
||||
return;
|
||||
}
|
||||
$this->sendGroupJobOffer($jobID, $group, $descr);
|
||||
}
|
||||
|
||||
private function sendIndividualJobOffer($jobID, $email, $descr) {
|
||||
// this function will handle sending offer to invidual
|
||||
$in["job_id"] = $jobID;
|
||||
$in["email"] = $email;
|
||||
$in["job_description"] = $descr;
|
||||
$in['member_id'] = $_SESSION['member_id'];
|
||||
// var_dump($in);
|
||||
|
||||
$in['action'] = WRENCHBOARD_JOB_OFFER_INDVI;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($in, $out);
|
||||
if ($res == PHP_CREATED_OK) {
|
||||
|
||||
echo "Offer sent";
|
||||
} else {
|
||||
echo "Unable to send offer";
|
||||
}
|
||||
// echo 'Individual Result';
|
||||
}
|
||||
|
||||
private function sendGroupJobOffer($jobID, $group, $descr) {
|
||||
// this function will handle the call to backend
|
||||
// to manage the sending of offer to group of people
|
||||
$in["job_id"] = $jobID;
|
||||
$in["group_id"] = $group;
|
||||
$in["job_description"] = $descr;
|
||||
$in['member_id'] = $_SESSION['member_id'];
|
||||
//var_dump($in);
|
||||
|
||||
$in['action'] = WRENCHBOARD_JOB_OFFER_GROUP;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($in, $out);
|
||||
if ($res == PHP_CREATED_OK) {
|
||||
|
||||
echo "Offer sent to group";
|
||||
} else {
|
||||
echo "Unable to send offer";
|
||||
}
|
||||
//echo 'Group Result';
|
||||
}
|
||||
|
||||
public function manage() {
|
||||
|
||||
$data = $this->getSessionArray();
|
||||
$this->load->library('table');
|
||||
|
||||
$this->table->set_template($this->template);
|
||||
$jbx = "''processjob''";
|
||||
$mysql = "SELECT title,description,timeline_days||' day(s)', price*0.01||'Naira' AS price,"
|
||||
. " created::date,'<input type=submit onclick=\"return post_nav_find_action($jbx, '||id||')\" name=\"manage\" class=\"btn btn-info btn-sm\" value=\"Offer Job\">' AS manage,"
|
||||
. "'<input type=submit onclick=\"return post_nav_del_action($jbx, '||id||')\" name=\"manage\" class=\"btn btn-warning btn-sm\" value=\"Del\">' As Del "
|
||||
. " FROM members_jobs WHERE member_id = " . $_SESSION['member_id'] . " ORDER BY id DESC";
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading('Title', 'Description', 'Timeline', 'Price', 'Created', 'Manage', 'Del.');
|
||||
$data['job_table'] = $this->table->generate($query);
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('jobs/view_manage', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
|
||||
private function getSessionArray() {
|
||||
$data['username'] = $_SESSION['username']; // = $this->input->post('username');
|
||||
$data['name'] = $_SESSION['name']; // = $this->input->post('username');
|
||||
$data['firstname'] = $_SESSION['firstname']; // = $ret->firstname;
|
||||
$data['lastname'] = $_SESSION['lastname']; // = $ret->lastname;
|
||||
$data['email'] = $_SESSION['email']; // = $ret->email;
|
||||
$data['member_id'] = $_SESSION['member_id'];
|
||||
|
||||
$this->load->model('dash_model');
|
||||
$out = $this->dash_model->getDashData($data);
|
||||
$data['active_task'] = $out['active_task'];
|
||||
$data['active_pass_due'] = $out['active_pass_due'];
|
||||
$data['current_balance'] = $out['current_balance'];
|
||||
$data['new_message'] = $out['new_message'];
|
||||
|
||||
$data = $_SESSION['secure_data'];
|
||||
$data['member_id'] = $_SESSION['member_id']; // = $ret->email;
|
||||
|
||||
$this->refreshAccountDetail($_SESSION['member_id']);
|
||||
return $data;
|
||||
}
|
||||
|
||||
private function refreshAccountDetail($member_id) {
|
||||
$this->load->model('account_model');
|
||||
$qr = $this->account_model->loadAccountData($member_id);
|
||||
$_SESSION['current_balance'] = $qr[0]['balance'];
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,167 @@
|
||||
<?php
|
||||
|
||||
class Login extends WRB_Controller {
|
||||
|
||||
public function __construct() {
|
||||
parent::__construct();
|
||||
// Load library and url helper
|
||||
//$this->load->library('facebook');
|
||||
//$this->load->helper('url');
|
||||
$this->load->library(array('session', 'lib_login'));
|
||||
}
|
||||
|
||||
public function index() {
|
||||
$data["login_message"] = "";
|
||||
$this->load->library('form_validation');
|
||||
$this->form_validation->set_rules('username', 'Username', 'required');
|
||||
$this->form_validation->set_rules('password', 'Password', 'required');
|
||||
|
||||
if ($this->form_validation->run() !== false) {
|
||||
|
||||
|
||||
$data['username'] = strtolower($this->input->post('username')); // '08174596144';
|
||||
$data['password'] = $this->input->post('password'); //'7978';
|
||||
|
||||
$data['sessionid'] = rand(10000, 99999) . "A" . rand(10000, 99999);
|
||||
$data['action'] = WRENCHBOARD_ACCOUNT_LOGIN;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($data, $out);
|
||||
$is_live = $this->backend_model->cfgReadChar("system.live");
|
||||
// print_r($out);
|
||||
if ($res == PHP_LOGIN_OK) {
|
||||
$this->load->model('account_model');
|
||||
$ret = $this->account_model->username_data($data);
|
||||
if ($res !== false) {
|
||||
$data["login_message"] = "Welcome...";
|
||||
// yes person has an account
|
||||
$_SESSION['session_id'] = $out["session"];
|
||||
$_SESSION['username'] = $this->input->post('username');
|
||||
$_SESSION['name'] = $this->input->post('username');
|
||||
$_SESSION['firstname'] = $ret->firstname;
|
||||
$_SESSION['lastname'] = $ret->lastname;
|
||||
$_SESSION['email'] = $ret->email;
|
||||
$_SESSION['member_id'] = $ret->id;
|
||||
$_SESSION['log_count'] = 0;
|
||||
$_SESSION['mesaage_count'] = 0;
|
||||
$this->findOffers($_SESSION['email']);
|
||||
$_SESSION['message_snapshot'] = $this->myMessagesSnapshot();
|
||||
$_SESSION['total_jobs'] = 0;
|
||||
if (trim($ret->profile_pic) == '') {
|
||||
// Show default picture
|
||||
$_SESSION['profile_picture'] = "../smedia/DEFAULTS/default-profile.png";
|
||||
} else {
|
||||
// show the profile picture
|
||||
$_SESSION['profile_picture'] = "../smedia/" . ($is_live ? "LIVE" : "TEST") . "/profile/" . $ret->profile_pic;
|
||||
}
|
||||
|
||||
|
||||
$this->logUser('Account login');
|
||||
$this->refreshAccountDetail($_SESSION['member_id']);
|
||||
$this->getSessionArray();
|
||||
redirect('dash');
|
||||
}
|
||||
} else {
|
||||
$data["login_message"] = "Invalid username or password";
|
||||
}
|
||||
|
||||
$res = false; // $this->login_model->verify_login($data);
|
||||
} else {
|
||||
echo validation_errors();
|
||||
}
|
||||
|
||||
|
||||
|
||||
if ($this->lib_login->is_authenticated()) {
|
||||
$fb_data = $this->lib_login->getData($this->lib_login->get_access_token());
|
||||
if (isset($fb_data['me'])) {
|
||||
$user = $fb_data['me'];
|
||||
$proceed = false;
|
||||
//$data["login_message"] = $user["id"]."/".$user["name"]."/".$user["email"]."<a href='".$this->lib_login->getLogoutUrl()."'>Logout</a>";
|
||||
$q = "SELECT * FROM members WHERE lower(email)=lower('" . $user["name"] . "') AND password IS NULL AND fb_id='" . $user["id"] . "'";
|
||||
$query = $this->db->query($q);
|
||||
if (count($query->result_array)) {
|
||||
// Account exists
|
||||
$proceed = true;
|
||||
} else {
|
||||
$q = "SELECT * FROM members WHERE lower(email)=lower('" . $user["name"] . "')";
|
||||
$query = $this->db->query($q);
|
||||
if (count($query->result_array)) {
|
||||
$data["login_message"] = "The e-mail " . $user["email"] . " is already registered. You should login with your username and password.";
|
||||
} else {
|
||||
// Create account
|
||||
$proceed = true;
|
||||
}
|
||||
}
|
||||
if ($proceed) {
|
||||
$name = (string) $user["name"];
|
||||
if (trim($name) == "")
|
||||
$name = strtok($user["email"], "@");
|
||||
$data['fb_id'] = $user["id"];
|
||||
$data['firstname'] = strtok($name, " ");
|
||||
$data['lastname'] = strtok(" ");
|
||||
$data['email'] = $user["email"];
|
||||
$data['sessionid'] = rand(10000, 99999) . "A" . rand(10000, 99999);
|
||||
$data['action'] = WRENCHBOARD_FACEBOOK_LOGIN;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($data, $out);
|
||||
if ($res == PHP_LOGIN_OK) {
|
||||
$this->load->model('account_model');
|
||||
$ret = $this->account_model->username_data($out);
|
||||
if ($res !== false) {
|
||||
$data["login_message"] = "Welcome...";
|
||||
// yes person has an account
|
||||
$_SESSION['session_id'] = $out["session"];
|
||||
$_SESSION['username'] = $ret->username;
|
||||
$_SESSION['name'] = $ret->username;
|
||||
$_SESSION['firstname'] = $ret->firstname;
|
||||
$_SESSION['lastname'] = $ret->lastname;
|
||||
$_SESSION['email'] = $ret->email;
|
||||
$_SESSION['member_id'] = $ret->id;
|
||||
$_SESSION['log_count'] = 0;
|
||||
$_SESSION['mesaage_count'] = 0;
|
||||
$this->findOffers($_SESSION['email']);
|
||||
$_SESSION['message_snapshot'] = $this->myMessagesSnapshot();
|
||||
|
||||
$this->logUser('Account login');
|
||||
$this->refreshAccountDetail($_SESSION['member_id']);
|
||||
$this->getSessionArray();
|
||||
redirect('dash');
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if ($data["login_message"] == "") {
|
||||
//$data["login_message"] = "Facebook login failed";
|
||||
}
|
||||
}
|
||||
|
||||
if( strlen( $data["login_message"]) > 0 )
|
||||
{
|
||||
$data["login_message"] = "<div class=\"text-left\"><div class=\"alert alert-danger no-border\">" . $data["login_message"] . "</div></div>";
|
||||
}
|
||||
$data['title'] = "Login"; // Capitalize the first letter
|
||||
$data['page_title'] = "Login WrenchBoard";
|
||||
//$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_login', $data);
|
||||
$this->load->view('users/view_external_footer');
|
||||
}
|
||||
|
||||
|
||||
|
||||
public function refreshAccountDetail($member_id) {
|
||||
$this->load->model('account_model');
|
||||
$qr = $this->account_model->loadAccountData($member_id);
|
||||
// print_r($qr);
|
||||
$_SESSION['current_balance'] = $qr[0]['balance'];
|
||||
$_SESSION['active_task'] = $this->account_model->loadActiveTaskCount($member_id);
|
||||
}
|
||||
|
||||
|
||||
|
||||
public function logout() {
|
||||
$this->lib_login->destroy_session();
|
||||
redirect('login', redirect);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
|
||||
class Logout extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
// delete session
|
||||
$_SESSION['username'] = ""; //$this->input->post('username');
|
||||
$_SESSION['name'] = ""; //$this->input->post('username');
|
||||
$_SESSION['firstname'] = ""; //= $ret->firstname;
|
||||
$_SESSION['lastname'] = ""; //= $ret->lastname;
|
||||
|
||||
|
||||
redirect(home);
|
||||
}
|
||||
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,143 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Mobile extends Mobile_Controller {
|
||||
|
||||
public function index() {
|
||||
$data = array();
|
||||
$this->login();
|
||||
}
|
||||
|
||||
public function login() {
|
||||
|
||||
$data = array();
|
||||
|
||||
$data["login_message"] = "";
|
||||
$this->load->library('form_validation');
|
||||
$this->form_validation->set_rules('username', 'Username', 'required');
|
||||
$this->form_validation->set_rules('password', 'Password', 'required');
|
||||
|
||||
if ($this->form_validation->run() !== false) {
|
||||
|
||||
|
||||
$data['username'] = strtolower($this->input->post('username')); // '08174596144';
|
||||
$data['password'] = $this->input->post('password'); //'7978';
|
||||
|
||||
$data['sessionid'] = rand(10000, 99999) . "A" . rand(10000, 99999);
|
||||
$data['action'] = WRENCHBOARD_ACCOUNT_LOGIN;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($data, $out);
|
||||
$is_live = $this->backend_model->cfgReadChar("system.live");
|
||||
//print_r($out);
|
||||
if ($res == PHP_LOGIN_OK) {
|
||||
$this->load->model('account_model');
|
||||
$ret = $this->account_model->username_data($data);
|
||||
|
||||
if ($res !== false) {
|
||||
$data["login_message"] = "Welcome...";
|
||||
// yes person has an account
|
||||
$_SESSION['session_id'] = $out["session"];
|
||||
$_SESSION['username'] = $this->input->post('username');
|
||||
$_SESSION['name'] = $this->input->post('username');
|
||||
$_SESSION['firstname'] = $ret->firstname;
|
||||
$_SESSION['lastname'] = $ret->lastname;
|
||||
$_SESSION['email'] = $ret->email;
|
||||
$_SESSION['member_id'] = $ret->id;
|
||||
$_SESSION['log_count'] = 0;
|
||||
$_SESSION['mesaage_count'] = 0;
|
||||
$this->findOffers($_SESSION['email']);
|
||||
$_SESSION['message_snapshot'] = $this->myMessagesSnapshot();
|
||||
$_SESSION['total_jobs'] = 0;
|
||||
if (trim($ret->profile_pic) == '') {
|
||||
// Show default picture
|
||||
$_SESSION['profile_picture'] = "../smedia/DEFAULTS/default-profile.png";
|
||||
} else {
|
||||
// show the profile picture
|
||||
$_SESSION['profile_picture'] = "../smedia/" . ($is_live ? "LIVE" : "TEST") . "/profile/" . $ret->profile_pic;
|
||||
}
|
||||
|
||||
|
||||
$this->logUser('Account login');
|
||||
$this->refreshAccountDetail($_SESSION['member_id']);
|
||||
// $this->getSessionArray();
|
||||
redirect('mobile/mobiledash');
|
||||
}
|
||||
} else {
|
||||
//$data["login_message"] = "<div class=\"alert alert-danger no-border\">Invalid username or password</div>";
|
||||
$data["login_message"] = "Invalid username or password";
|
||||
}
|
||||
|
||||
$res = false; // $this->login_model->verify_login($data);
|
||||
} else {
|
||||
echo validation_errors();
|
||||
}
|
||||
|
||||
|
||||
$this->renderMobileExtPage('mobile_index', $data);
|
||||
|
||||
// $this->home2();
|
||||
}
|
||||
|
||||
public function mobiledash() {
|
||||
$data = array();
|
||||
$this->renderMobileSecurePage('mobile_dash', $data);
|
||||
}
|
||||
|
||||
public function signup() {
|
||||
$data = array();
|
||||
|
||||
$data["signup_error"] = "";
|
||||
|
||||
$firstname = NULL;
|
||||
$country = 'NG';
|
||||
$lastname = NULL;
|
||||
$email = NULL;
|
||||
$password = NULL;
|
||||
$terms = NULL;
|
||||
$news = NULL;
|
||||
$terms = NULL;
|
||||
$submit = NULL;
|
||||
|
||||
extract($_POST);
|
||||
|
||||
|
||||
|
||||
|
||||
$this->load->model('combo_model');
|
||||
$this->combo_model->defaultComboMessage = 'Select your Country';
|
||||
$data['country_combo'] = $this->combo_model->getCountryCombo('country', $country);
|
||||
|
||||
$this->renderMobileExtPage('mobile_signup', $data);
|
||||
|
||||
// $this->home2();
|
||||
}
|
||||
|
||||
public function refreshAccountDetail($member_id) {
|
||||
$this->load->model('account_model');
|
||||
$qr = $this->account_model->loadAccountData($member_id);
|
||||
// print_r($qr);
|
||||
$_SESSION['current_balance'] = $qr[0]['balance'];
|
||||
$_SESSION['active_task'] = $this->account_model->loadActiveTaskCount($member_id);
|
||||
}
|
||||
|
||||
private function renderMobileExtPage($mobile_page_name, $data) {
|
||||
|
||||
$this->load->view('mobile/mobile_ext_header', $data);
|
||||
$this->load->view('mobile/' . $mobile_page_name, $data);
|
||||
$this->load->view('mobile/mobile_ext_footer', $data);
|
||||
}
|
||||
|
||||
private function renderMobileSecurePage22($mobile_page_name, $data) {
|
||||
$this->load->view('mobile/secure/mobile_secure_header', $data);
|
||||
$this->load->view('mobile/secure/' . $mobile_page_name, $data);
|
||||
$this->load->view('mobile/secure/mobile_secure_footer', $data);
|
||||
}
|
||||
|
||||
public function logout() {
|
||||
$data = array();
|
||||
$this->login();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
|
||||
class Outmessage extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
$data['account_email'] = ''; //$data['username'];
|
||||
$data['title'] = "Message"; //ucfirst($page); // Capitalize the first letter
|
||||
$data['page_title'] = "Verify Email.";
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_outmessage', $data);
|
||||
$this->load->view('templates/footer_boxed', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Partners extends WRB_Controller {
|
||||
|
||||
public function index() {
|
||||
/* $data['sitename'] = 'home';
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_index');
|
||||
$this->load->view('users/view_external_footer');
|
||||
* */
|
||||
|
||||
$this->agenthome();
|
||||
}
|
||||
|
||||
public function agenthome() {
|
||||
$this->load->view('agent/agent_home');
|
||||
}
|
||||
|
||||
public function login() {
|
||||
|
||||
// $this->load->view('users/view_index');
|
||||
// $this->load->view('users/view_external_footer');
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,55 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Password_recovery extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
//echo "ameye kvkgkg";
|
||||
$data['action_message'] = "";
|
||||
|
||||
|
||||
if ($_POST) {
|
||||
|
||||
$data['email'] = $this->input->post('email');
|
||||
if ($data['email'] == '') {
|
||||
$out['error'] = 'Please specify valid emal to continue';
|
||||
$data['action_message'] = "<div class=\"text-left\"><div class=\"alert alert-danger no-border\">" . $out['error'] . "</div></div>";
|
||||
} else {
|
||||
//WRENCHBOARD_ACCOUNT_RESETPASS
|
||||
|
||||
$this->resetMemberPass($data['email']);
|
||||
|
||||
$out['error'] = "If we find your email, you will receive a link to reset your password. Please use or <a href='/contact'>contact form</a> if you did not get our message after few minutes. ";
|
||||
$data['action_message'] = "<div class=\"text-left\"><div class=\"alert alert-info no-border\">" . $out['error'] . "</div></div>";
|
||||
}
|
||||
}
|
||||
$data["message"] = "Enter your account username, Email.<br> We will send you an email to reset your password";
|
||||
$this->load->view('users/view_external_header');
|
||||
$this->load->view('users/view_password_recovery', $data);
|
||||
$this->load->view('users/view_external_footer');
|
||||
}
|
||||
|
||||
var $actionMessage = '';
|
||||
|
||||
private function resetMemberPass($email) {
|
||||
$this->actionMessage = '';
|
||||
//$group_id = $group_id + 0; // just making sure it is number
|
||||
|
||||
|
||||
$x['email'] = $email;
|
||||
|
||||
|
||||
$x['action'] = WRENCHBOARD_ACCOUNT_RESETPASS;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($x, $out);
|
||||
if ($res == PHP_CREATED_OK) {
|
||||
$this->actionMessage = 'Group Created';
|
||||
} else {
|
||||
$this->actionMessage = 'Unable to create job group...';
|
||||
}
|
||||
return $this->actionMessage;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
class Paypal extends Users_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
$data = $this->getSessionArray();
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
} else {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public function retn() {
|
||||
$data = $this->getSessionArray();
|
||||
}
|
||||
|
||||
public function canc() {
|
||||
$data = $this->getSessionArray();
|
||||
|
||||
redirect('/member/addfund');
|
||||
}
|
||||
|
||||
public function ipn() {
|
||||
$data = $this->getSessionArray();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,105 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Plb extends WRB_Controller {
|
||||
|
||||
public function index() {
|
||||
$this->jobViewPage('');
|
||||
}
|
||||
|
||||
public function viewjob() {
|
||||
$offerCode = ($this->uri->segment(3)) ? $this->uri->segment(3) : 0;
|
||||
$this->jobViewPage($offerCode);
|
||||
}
|
||||
|
||||
private function jobViewPage($offerCode) {
|
||||
/* $data['sitename'] = 'home';
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_index');
|
||||
$this->load->view('users/view_external_footer');
|
||||
* */
|
||||
// $this->load->view('users/view_index');
|
||||
// $this->load->view('users/view_external_footer');
|
||||
|
||||
$data = array();
|
||||
|
||||
|
||||
$mysql = "SELECT jo.expire,jo.id AS offer_id, jo.offer_code,mj.title,mj.description,mj.timeline_days,mj.price,jo.job_description FROM members_jobs_offer jo "
|
||||
. " LEFT JOIN members_jobs mj ON mj.id=jo.job_id "
|
||||
. " WHERE mj.status=1 AND jo.status=1 "
|
||||
. " AND jo.expire> now() AND jo.offer_code='" . $offerCode . "' AND jo.public_view > 0";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$num = $query->num_rows();
|
||||
|
||||
if ($num > 0) {
|
||||
$myTable = "<table class='table table-striped table-hover table-bordered table-condensed'>";
|
||||
|
||||
foreach ($query->result_array() as $row) {
|
||||
$myTable .= $this->makeMarketTableRow($row);
|
||||
}
|
||||
|
||||
$myTable .="</table>";
|
||||
// $this->table->set_heading('Added/Expire', 'Title/Recipient', 'Status', '');
|
||||
$data['market_table'] = $myTable; // $this->table->generate($query);
|
||||
// $offer_found = true;
|
||||
} else {
|
||||
$data['market_table'] = '';
|
||||
}
|
||||
|
||||
|
||||
$mysql2 = " SELECT o.*,j.title,j.description,j.timeline_days,j.price,j FROM members_jobs_offer o "
|
||||
. " LEFT JOIN members_jobs j ON j.id =o.job_id "
|
||||
. " WHERE o.public_view =1 AND o.offer_code<>'" . $offerCode . "' AND o.expire> now() AND o.status=1 ORDER BY o.id DESC LIMIT 50";
|
||||
$query = $this->db->query($mysql2);
|
||||
$data["numof_other_jobs"] = $query->num_rows();
|
||||
$data["job_data"] = $query->result();
|
||||
|
||||
|
||||
|
||||
/*
|
||||
$mysql2 = " SELECT o.*,j.title,j.description,j.timeline_days,j.price,j FROM members_jobs_offer o "
|
||||
. " LEFT JOIN members_jobs j ON j.id =o.job_id "
|
||||
. " WHERE o.public_view =1 AND o.offer_code<>'" . $offerCode . "' AND o.expire> now() ORDER BY o.id DESC LIMIT 50";
|
||||
|
||||
|
||||
$query = $this->db->query($mysql2);
|
||||
$data["numof_other_jobs"] = $query->num_rows();
|
||||
$data["job_data"] = $query->result();
|
||||
*/
|
||||
|
||||
|
||||
$this->load->view('templates/view_header_market', $data);
|
||||
$this->load->view('site/view_market', $data);
|
||||
$this->load->view('templates/view_footer_market', $data);
|
||||
}
|
||||
|
||||
private function makeMarketTableRow($row) {
|
||||
return "<tr><td style='width:100px;'><b>" . $row['offer_code'] . "</b></td><td>" . $row['title'] . "</td><td style='width:100px;'></td></tr>"
|
||||
. "<tr><td colspan = '3'>" . $this->makeMarketDetailTableRow($row) . "</td></tr>";
|
||||
}
|
||||
|
||||
private function makeMarketDetailTableRow($row) {
|
||||
$data['interest'] = 0;
|
||||
|
||||
$mysql = "SELECT count(*) AS interest FROM members_offer_interest WHERE offer_id=" . $row['offer_id'];
|
||||
$query = $this->db->query($mysql);
|
||||
if ($query->num_rows() > 0) {
|
||||
$data = $query->row_array();
|
||||
}
|
||||
|
||||
|
||||
|
||||
return "<table class='table table-striped table-hover table-bordered table-condensed'><tr><td colspan='2' ><b> Timeline:</b>" . $row['timeline_days'] . " day(s) - <b>Budget: </b> " . $row['price'] * 0.01 . " Naira</td></tr>"
|
||||
. "<tr><td style='width:100px;'><b>Title</b></td><td>" . $row['title'] . "</td></tr>"
|
||||
. "<tr><td><b>Description</b></td><td>" . $row['description'] . "</td></tr>"
|
||||
. "<tr><td><b>Detail</b></td><td>" . $row['job_description'] . "</td></tr>"
|
||||
. "<tr><td colspan='2' >Interests : <b>" . $data['interest'] . "</b> Expire:<b> " . $row['expire'] . "</b> </td></tr>"
|
||||
. "<tr><td><b></b></td><td style='text-align:right;'><input type=submit id='submit_interest_" . $row['offer_code'] . "' name=\"mview\" onclick=\"return LoginInterest('" . $row['offer_code'] . "');\" class=\"btn btn-success btn-xs\" value=\"see more ?
|
||||
\"></td></tr>"
|
||||
. "</table> ";
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
class Privacy extends WRB_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
$data['title'] = "Terms"; // Capitalize the first letter
|
||||
$data['page_title'] = "Terms & Conditions";
|
||||
|
||||
$data['page_key'] = 'WRB_MAIN_PRIVACY';
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_terms', $data);
|
||||
$this->load->view('users/view_external_footer');
|
||||
// $this->load->view('templates/footer_boxed', $data);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,141 @@
|
||||
<?php
|
||||
|
||||
class Refer extends Users_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
$data = $this->getSessionArray();
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
} else {
|
||||
redirect('/refer/refpage');
|
||||
}
|
||||
}
|
||||
|
||||
public function refpage() {
|
||||
$data = $this->getSessionArray();
|
||||
|
||||
|
||||
if ($_SESSION['refer'] == '') {
|
||||
redirect('/refer/refagree');
|
||||
}
|
||||
|
||||
$data['ref_firstname'] = $data['ref_lastname'] = $data['ref_email'] = "";
|
||||
$data["status"] = '';
|
||||
|
||||
if ($_POST) {
|
||||
$ref_firstname = $this->input->post('ref_firstname');
|
||||
$ref_lastname = $this->input->post('ref_lastname');
|
||||
$ref_email = $this->input->post('ref_email');
|
||||
$data['ref_firstname'] = $ref_firstname;
|
||||
$data['ref_lastname'] = $ref_lastname;
|
||||
$data['ref_email'] = $ref_email;
|
||||
|
||||
$data['action'] = WRENCHBOARD_ACCOUNT_SENDREFER;
|
||||
|
||||
// print_r( $data );
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($data, $out);
|
||||
if ($res == PHP_API_OK) {
|
||||
$data['ref_firstname'] = $data['ref_lastname'] = $data['ref_email'] = "";
|
||||
$data["status"] = 'Success - ' . $out['status'];
|
||||
} else {
|
||||
$data["status"] = 'Error - ' . $out['status'];
|
||||
}
|
||||
}
|
||||
|
||||
$this->load->library('pagination');
|
||||
$config = array();
|
||||
|
||||
|
||||
$mysql = "SELECT added::date||'<br>'||firstname||' '||lastname,email as date_name,"
|
||||
. "(CASE WHEN status=1 THEN 'Pending' WHEN status=5 THEN 'Completed' ElSE '' END) As status "
|
||||
. "FROM members_refer_friend "
|
||||
. "WHERE member_id =" . $_SESSION['member_id'];
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$config["total_rows"] = $query->num_rows();
|
||||
$config["base_url"] = base_url() . "/refer/refpage";
|
||||
$config["per_page"] = 5;
|
||||
$config["uri_segment"] = 3;
|
||||
$config["num_links"] = 5;
|
||||
|
||||
$config['full_tag_open'] = "<ul class='pagination'>";
|
||||
$config['full_tag_close'] = "</ul>";
|
||||
$config['num_tag_open'] = '<li>';
|
||||
$config['num_tag_close'] = '</li>';
|
||||
$config['cur_tag_open'] = "<li class='disabled'><li class='active'><a href='#'>";
|
||||
$config['cur_tag_close'] = "<span class='sr-only'></span></a></li>";
|
||||
$config['next_tag_open'] = "<li>";
|
||||
$config['next_tagl_close'] = "</li>";
|
||||
$config['prev_tag_open'] = "<li>";
|
||||
$config['prev_tagl_close'] = "</li>";
|
||||
$config['first_tag_open'] = "<li>";
|
||||
$config['first_tagl_close'] = "</li>";
|
||||
$config['last_tag_open'] = "<li>";
|
||||
$config['last_tagl_close'] = "</li>";
|
||||
|
||||
$this->pagination->initialize($config);
|
||||
|
||||
$page = ($this->uri->segment(3)) ? $this->uri->segment(3) : 0;
|
||||
|
||||
$page = is_numeric($page) ? $page : 0;
|
||||
|
||||
$mysql = "SELECT added::date||'<br>'||firstname||' '||lastname,email as date_name,"
|
||||
. "(CASE WHEN status=1 THEN 'Pending' WHEN status=5 THEN 'Completed' ElSE '' END) As status "
|
||||
. "FROM members_refer_friend "
|
||||
. "WHERE member_id =" . $_SESSION['member_id'] . " ORDER BY id DESC LIMIT " . $config["per_page"] . " OFFSET " . $page;
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$data["links"] = $this->pagination->create_links();
|
||||
|
||||
$this->table->set_heading(array('data' => 'Added/Name', 'style' => 'width:170px'), 'Email', array('data' => 'Status', 'style' => 'width:80px'));
|
||||
|
||||
$data['refer_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$data['page_title'] ="Refer a Friend";
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_refer', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
|
||||
public function refagree() {
|
||||
$data = $this->getSessionArray();
|
||||
if ($_SESSION['refer'] != '') {
|
||||
redirect('/refer');
|
||||
}
|
||||
|
||||
|
||||
|
||||
if ($_POST) {
|
||||
$in = array();
|
||||
$in['action'] = WRENCHBOARD_ACCOUNT_TERMS;
|
||||
$in['action_item'] = ACCOUNT_AGREE_REFER;
|
||||
$in['member_id'] = $_SESSION['member_id'];
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($in, $out);
|
||||
|
||||
if ($res == PHP_API_OK) {
|
||||
redirect('/refer');
|
||||
}
|
||||
}
|
||||
|
||||
$data['page_name'] = 'referterms';
|
||||
$data['page_title'] = 'Referer Terms';
|
||||
$data['page_key'] = 'WRB_MAIN_REFER_TERM';
|
||||
|
||||
$data['txt_detail'] = $this->readFixedText( $data['page_key'] );
|
||||
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_refagree', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,90 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Registration extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
$data["signup_error"] = "";
|
||||
|
||||
$firstname = NULL;
|
||||
$country = 'NG';
|
||||
$lastname = NULL;
|
||||
$email = NULL;
|
||||
$password = NULL;
|
||||
$terms = NULL;
|
||||
$news = NULL;
|
||||
$terms = NULL;
|
||||
$submit = NULL;
|
||||
|
||||
extract($_POST);
|
||||
|
||||
$data['firstname'] = $firstname;
|
||||
$data['lastname'] = $lastname;
|
||||
$data['email'] = strtolower($email);
|
||||
$data['username'] = strtolower($email);
|
||||
$data['password'] = $password;
|
||||
$data['country'] = $country;
|
||||
$data['news'] = 1; //$news;
|
||||
$data['terms'] = $terms;
|
||||
$ip = $this->input->ip_address();
|
||||
$data['loc'] = $ip; //"38.101.241.200";
|
||||
|
||||
$this->load->model('combo_model');
|
||||
$this->combo_model->defaultComboMessage = 'Select your Country';
|
||||
$data['country_combo'] = $this->combo_model->getCountryCombo('country', $country);
|
||||
$terms_checked = '';
|
||||
// is anybody using this email already
|
||||
$this->load->model('account_model');
|
||||
$data['signup_error'] = '';
|
||||
|
||||
if ($_POST) { // post
|
||||
if ($data['terms'] == 'on') {
|
||||
$terms_checked = 'checked';
|
||||
}
|
||||
|
||||
// $data['terms'] = 1; // note terms is turned to 1
|
||||
//
|
||||
// print_r($_POST);
|
||||
if ($this->account_model->verifySignupInputs($data) == true) {
|
||||
$email_in_use = false;
|
||||
$data['terms'] = 1; // $terms is interger in backend;
|
||||
if ($this->account_model->checkUsernameDuplicate($data) > 0) {
|
||||
$email_in_use = true;
|
||||
}
|
||||
if ($email_in_use == false) {
|
||||
$data['action'] = WRENCHBOARD_ACCOUNT_PENDING;
|
||||
if ($_POST) {
|
||||
if ($firstname !== '' && $lastname !== '') {
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($data, $out);
|
||||
if ($res > 0) {
|
||||
$data['account_email'] = strtolower($email);
|
||||
redirect('outmessage', $data);
|
||||
} else {
|
||||
$data['signup_error'] = "Unable to create account";
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$data['signup_error'] = "Please use another username";
|
||||
}
|
||||
} else {
|
||||
$data['signup_error'] = "Enter all required fields";
|
||||
}
|
||||
} // if post
|
||||
$data['signup_error_style'] = '';
|
||||
if (strlen($data['signup_error']) > 0) {
|
||||
$data['signup_error_style'] = "<div class=\"text-left\"><div class=\"alert alert-danger no-border\">" . $data["signup_error"] . "</div></div>";
|
||||
}
|
||||
|
||||
|
||||
$data['terms'] = $terms_checked;
|
||||
|
||||
|
||||
// $this->load->view('users/view_registration', $data);
|
||||
// $this->load->view('users/view_external_footer', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,134 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Res extends Users_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
$data['username'] = $_SESSION['username']; // = $this->input->post('username');
|
||||
$data['name'] = $_SESSION['name']; // = $this->input->post('username');
|
||||
$data['firstname'] = $_SESSION['firstname']; // = $ret->firstname;
|
||||
$data['lastname'] = $_SESSION['lastname']; // = $ret->lastname;
|
||||
$data['email'] = $_SESSION['email']; // = $ret->email;
|
||||
// print_r($_SESSION);
|
||||
//Array ( [__ci_last_regenerate] => 1474689025 [username] => ses66181+1@gmail.com [name] => ses66181+1@gmail.com [firstname] => Olusesan [lastname] => Amey [email] => ses66181+1@gmail.com )
|
||||
//
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
} else {
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_dash', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
}
|
||||
|
||||
public function vmedia() {
|
||||
|
||||
$data = $this->getSessionArray();
|
||||
|
||||
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$this->table->set_heading('No', 'Video');
|
||||
|
||||
//$dir = getcwd() . '/smedia/media/Angularjs';
|
||||
$group = '';
|
||||
$get_group = $this->input->post('group');
|
||||
$dir = '/opt/wrenchboard/media';
|
||||
$folders_found = scandir($dir);
|
||||
for ($ii = 0; $ii < count($folders_found); $ii++) {
|
||||
if (strlen($folders_found[$ii]) > 5 && $get_group == md5($folders_found[$ii])) {
|
||||
$group = $folders_found[$ii];
|
||||
}
|
||||
}
|
||||
if ($group == '')
|
||||
redirect(home);
|
||||
$video = '';
|
||||
$get_video = $this->input->post('video');
|
||||
|
||||
$dir = '/opt/wrenchboard/media/' . $group;
|
||||
$folders_found = scandir($dir);
|
||||
$ik = 1;
|
||||
for ($ii = 0; $ii < count($folders_found); $ii++) {
|
||||
if (strlen($folders_found[$ii]) > 5) {
|
||||
//echo $get_video." / ".md5($folders_found[$ii])." / ".$folders_found[$ii]."<br>";
|
||||
if ($get_video == md5($folders_found[$ii]))
|
||||
$video = $folders_found[$ii];
|
||||
$out['folder_' . $ik] = $folders_found[$ii];
|
||||
$folderClick = '<a href="#" onclick="return loadVideo(\'' . md5($group) . '\',\'' . md5($folders_found[$ii]) . '\')">' . $folders_found[$ii] . '</a>';
|
||||
$this->table->add_row($ik, $folderClick);
|
||||
$ik++;
|
||||
}
|
||||
}
|
||||
if ($video == '')
|
||||
$video = $out['folder_1'];
|
||||
$data['video'] = '/smedia/media/' . $group . '/' . $video;
|
||||
$data['group'] = md5($group);
|
||||
$data['folders_data'] = $out;
|
||||
$data['video_table'] = $this->table->generate();
|
||||
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_viewmedia', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
|
||||
public function media() {
|
||||
|
||||
$data = $this->getSessionArray();
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$this->table->set_heading('No', 'Video');
|
||||
|
||||
//$dir = getcwd() . '/smedia/media';
|
||||
$dir = '/opt/wrenchboard/media';
|
||||
$folders_found = scandir($dir);
|
||||
$ik = 1;
|
||||
for ($ii = 0; $ii < count($folders_found); $ii++) {
|
||||
if (strlen($folders_found[$ii]) > 5) {
|
||||
$out['folder_' . $ik] = $folders_found[$ii];
|
||||
$folderClick = '<a href="#" onclick="return loadGroup(\'' . md5($folders_found[$ii]) . '\')">' . $folders_found[$ii] . '</a>';
|
||||
$this->table->add_row($ik, $folderClick);
|
||||
$ik++;
|
||||
}
|
||||
}
|
||||
|
||||
$data['folders_data'] = $out;
|
||||
$data['video_table'] = $this->table->generate();
|
||||
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_vmedia', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
|
||||
public function prints() {
|
||||
|
||||
$data = $this->getSessionArray();
|
||||
// get libary contents
|
||||
|
||||
$mysql = "SELECT '<a onclick=\"return viewLibr('||id||')\" >'||title||'</a>' FROM library";
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading('');
|
||||
$data['library_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_prints', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
|
||||
public function getlibary() {
|
||||
$library_id = $this->input->get('libary_id');
|
||||
$out = $this->libraryContent($library_id);
|
||||
// echo $this->smart_htmlspecialchars ( $out['detail'] );
|
||||
echo html_entity_decode($out['detail']);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,86 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Secmobile extends WRB_Controller {
|
||||
|
||||
public function index() {
|
||||
$this->mobiledash();
|
||||
}
|
||||
|
||||
public function mobiledash() {
|
||||
$data = array();
|
||||
$this->renderMobileSecurePage('mobile_dash', $data);
|
||||
}
|
||||
|
||||
public function active() {
|
||||
$data = array();
|
||||
$jbx = "''/proj/thisjob''";
|
||||
$mysql = "SELECT '<b>ID:</b><a href=\"#\" onclick=\"showJobModal('''||mc.contract||''');\" >'||mc.contract||'</a><br><b>Timeline:</b>'||mc.timeline_days||' day(s)<br><b>Price:</b>'||mc.price*0.01 AS Project,"
|
||||
. " '<b>Title: </b>'||mc.title||'<br><b>Description: </b>'||mc.description AS description,"
|
||||
. " (CASE WHEN mc.status=4 THEN '<input type=submit onclick=\"return post_nav_find_action($jbx, '||mc.id||')\" name=\"manage\" class=\"btn btn-info btn-xs btn-block\" value=\"Review\">' "
|
||||
. " WHEN mc.status = 1 AND mc.delivery_date > now() THEN '<input type=submit onclick=\"return post_nav_find_action($jbx, '||mc.id||')\" name=\"manage\" class=\"btn btn-success btn-xs btn-block\" value=\"View\">' "
|
||||
. " WHEN mc.status = 1 AND mc.delivery_date <now() THEN '<span class=\"label label-flat border-danger text-danger-600\">PastDue</span>' "
|
||||
. "ELSE '<input type=submit onclick=\"return post_nav_find_action($jbx, '||mc.id||')\" name=\"manage\" class=\"btn btn-info btn-xs btn-block\" value=\"View\">' END) AS manage "
|
||||
. " FROM members_jobs_contract mc LEFT JOIN members m ON m.id=mc.client_id WHERE mc.member_id = " . $_SESSION['member_id'] . " AND mc.status IN (1,2,4) OR mc.client_id =" . $_SESSION['member_id'] . " AND mc.status IN (1,2,4)"; // LIMIT " . $config["per_page"] . " OFFSET " . $page;
|
||||
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$data['activejob_table'] = $query->result();
|
||||
|
||||
|
||||
$this->renderMobileSecurePage('mobile_active_task', $data);
|
||||
}
|
||||
|
||||
public function market() {
|
||||
$data = array();
|
||||
|
||||
$data['offer_dash'] = '';
|
||||
$data["dash_title"] = "Available Jobs & Tasks";
|
||||
|
||||
$mysql = ' SELECT jo.offer_code,mj.title,mj.description,mj.timeline_days,mj.price,jo.job_description '
|
||||
. ' FROM members_jobs_offer jo '
|
||||
. ' LEFT JOIN members_jobs mj ON mj.id=jo.job_id '
|
||||
. ' WHERE mj.status=1 AND jo.status=1 '
|
||||
. ' AND expire> now() AND public_view > 0';
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$num = $query->num_rows();
|
||||
$data['job_no'] = $num;
|
||||
|
||||
if ($num > 0) {
|
||||
|
||||
$data['job_table'] = $query->result();
|
||||
} else {
|
||||
|
||||
}
|
||||
$data['page_title'] = 'Marketplace';
|
||||
$this->renderMobileSecurePage('mobile_market_task', $data);
|
||||
}
|
||||
|
||||
public function account() {
|
||||
$data = array();
|
||||
$this->renderMobileSecurePage('mobile_dash', $data);
|
||||
}
|
||||
|
||||
public function messages() {
|
||||
$data = array();
|
||||
$this->renderMobileSecurePage('mobile_dash', $data);
|
||||
}
|
||||
|
||||
public function mypage() {
|
||||
$data = array();
|
||||
$this->renderMobileSecurePage('mobile_dash', $data);
|
||||
}
|
||||
|
||||
public function manage() {
|
||||
$data = array();
|
||||
$this->renderMobileSecurePage('mobile_dash', $data);
|
||||
}
|
||||
|
||||
public function myjobs() {
|
||||
$data = array();
|
||||
$this->renderMobileSecurePage('mobile_manage_task', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,90 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Signup extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
$data["signup_error"] = "";
|
||||
|
||||
$firstname = NULL;
|
||||
$country = 'NG';
|
||||
$lastname = NULL;
|
||||
$email = NULL;
|
||||
$password = NULL;
|
||||
$terms = NULL;
|
||||
$news = NULL;
|
||||
$terms = NULL;
|
||||
$submit = NULL;
|
||||
|
||||
extract($_POST);
|
||||
|
||||
$data['firstname'] = $firstname;
|
||||
$data['lastname'] = $lastname;
|
||||
$data['email'] = strtolower($email);
|
||||
$data['username'] = strtolower($email);
|
||||
$data['password'] = $password;
|
||||
$data['country'] = $country;
|
||||
$data['news'] = 1; //$news;
|
||||
$data['terms'] = $terms;
|
||||
$ip = $this->input->ip_address();
|
||||
$data['loc'] = $ip; //"38.101.241.200";
|
||||
|
||||
$this->load->model('combo_model');
|
||||
$this->combo_model->defaultComboMessage = 'Select your Country';
|
||||
$data['country_combo'] = $this->combo_model->getCountryCombo('country', $country);
|
||||
$terms_checked = '';
|
||||
// is anybody using this email already
|
||||
$this->load->model('account_model');
|
||||
$data['signup_error'] = '';
|
||||
|
||||
if ($_POST) { // post
|
||||
if ($data['terms'] == 'on') {
|
||||
$terms_checked = 'checked';
|
||||
}
|
||||
|
||||
// $data['terms'] = 1; // note terms is turned to 1
|
||||
//
|
||||
// print_r($_POST);
|
||||
if ($this->account_model->verifySignupInputs($data) == true) {
|
||||
$email_in_use = false;
|
||||
$data['terms'] = 1; // $terms is interger in backend;
|
||||
if ($this->account_model->checkUsernameDuplicate($data) > 0) {
|
||||
$email_in_use = true;
|
||||
}
|
||||
if ($email_in_use == false) {
|
||||
$data['action'] = WRENCHBOARD_ACCOUNT_PENDING;
|
||||
if ($_POST) {
|
||||
if ($firstname !== '' && $lastname !== '') {
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($data, $out);
|
||||
if ($res > 0) {
|
||||
$data['account_email'] = strtolower($email);
|
||||
redirect('outmessage', $data);
|
||||
} else {
|
||||
$data['signup_error'] = "Unable to create account";
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$data['signup_error'] = "Please use another username";
|
||||
}
|
||||
} else {
|
||||
$data['signup_error'] = "Enter all required fields";
|
||||
}
|
||||
} // if post
|
||||
$data['signup_error_style'] = '';
|
||||
if (strlen($data['signup_error']) > 0) {
|
||||
$data['signup_error_style'] = "<div class=\"text-left\"><div class=\"alert alert-danger no-border\">" . $data["signup_error"] . "</div></div>";
|
||||
}
|
||||
|
||||
|
||||
$data['terms'] = $terms_checked;
|
||||
|
||||
|
||||
$this->load->view('users/view_registration', $data);
|
||||
$this->load->view('users/view_external_footer', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Site extends WRB_Controller {
|
||||
|
||||
public function index() {
|
||||
/* $data['sitename'] = 'home';
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_index');
|
||||
$this->load->view('users/view_external_footer');
|
||||
* */
|
||||
|
||||
$this->home1();
|
||||
}
|
||||
|
||||
public function registration() {
|
||||
$this->load->view('users/view_registration');
|
||||
}
|
||||
|
||||
public function login() {
|
||||
|
||||
// $this->load->view('users/view_index');
|
||||
// $this->load->view('users/view_external_footer');
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,56 @@
|
||||
<?php
|
||||
|
||||
class Smedia extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
$this->serve_file('');
|
||||
}
|
||||
|
||||
private function serve_file($filename) {
|
||||
if ($filename=='' || !file_exists($filename)) {
|
||||
$filename = 'assets/images/accessdenied.png';
|
||||
}
|
||||
// Any additional path checks should go here
|
||||
// TODO: realpath check to /opt/wrenchboard
|
||||
header('Content-type: ' . mime_content_type($filename));
|
||||
readfile($filename);
|
||||
}
|
||||
|
||||
public function DEFAULTS() {
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
$this->serve_file('');
|
||||
return;
|
||||
}
|
||||
//var_dump($_SERVER);
|
||||
$filename = str_replace("/smedia/","/opt/wrenchboard/",$_SERVER["SCRIPT_URL"]);
|
||||
//echo $filename;
|
||||
$this->serve_file($filename);
|
||||
}
|
||||
|
||||
public function LIVE() {
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
$this->serve_file('');
|
||||
return;
|
||||
}
|
||||
$filename = str_replace("/smedia/","/opt/wrenchboard/",$_SERVER["SCRIPT_URL"]);
|
||||
$this->serve_file($filename);
|
||||
}
|
||||
|
||||
public function media() {
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
$this->serve_file('');
|
||||
return;
|
||||
}
|
||||
$filename = str_replace("/smedia/","/opt/wrenchboard/",$_SERVER["SCRIPT_URL"]);
|
||||
$this->serve_file($filename);
|
||||
}
|
||||
|
||||
public function TEST() {
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
$this->serve_file('');
|
||||
return;
|
||||
}
|
||||
$filename = str_replace("/smedia/","/opt/wrenchboard/",$_SERVER["SCRIPT_URL"]);
|
||||
$this->serve_file($filename);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
class Terms extends WRB_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
$data['title'] = "Terms"; // Capitalize the first letter
|
||||
$data['page_title'] = "Terms & Conditions";
|
||||
|
||||
$data['page_key'] = 'WRB_MAIN_SIGNUP_TERM';
|
||||
$data['txt_detail'] = $this->readFixedText($data['page_key']);
|
||||
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_terms', $data);
|
||||
$this->load->view('users/view_external_footer');
|
||||
// $this->load->view('templates/footer_boxed', $data);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class User extends CI_Controller {
|
||||
|
||||
public function index()
|
||||
{
|
||||
// echo "ameye kvkgkg";
|
||||
$this->load->view('users/view_index');
|
||||
}
|
||||
|
||||
public function registration(){
|
||||
$this->load->view('users/view_registration');
|
||||
}
|
||||
|
||||
public function login()
|
||||
{
|
||||
$submit = NULL;
|
||||
extract($_POST);
|
||||
if ($submit)
|
||||
{
|
||||
|
||||
redirect('member');
|
||||
}
|
||||
// redirect('member');
|
||||
$this->load->view('users/view_index');
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,51 @@
|
||||
<?php
|
||||
|
||||
class Vemail extends CI_Controller {
|
||||
|
||||
public function index() {
|
||||
|
||||
//http://oameye.works.wrenchboard.com/vemail?vlnk=WRENCHB-872626432-43593472-432449792
|
||||
|
||||
$vlnk = NULL;
|
||||
$data['title'] = "Verify Email"; // Capitalize the first letter
|
||||
$data['page_title'] = "About WrenchBoard";
|
||||
$data['email'] = "ameye@chiefsoft.com";
|
||||
|
||||
extract($_GET);
|
||||
if (trim($vlnk) !== '') {
|
||||
$data['vlink'] = trim($vlnk);
|
||||
$this->load->model('account_model');
|
||||
$ret = $this->account_model->verify_link($data);
|
||||
if ($ret !== false) {
|
||||
$data['email'] = $ret->email;
|
||||
if ($ret->status == 1) {
|
||||
// let us work on the back end now
|
||||
// CONSTRUCT THE ACCOUNT NOW
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$data['action'] = WRENCHBOARD_ACCOUNT_CREATEACC;
|
||||
$data['verify_link'] = trim($vlnk);
|
||||
$data['username'] = $ret->username;
|
||||
$res1 = $this->backend_model->wrenchboard_api($data, $out);
|
||||
if ($res1 > 0) {
|
||||
$this->load->view('users/view_vemail', $data);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
// make sure status is set to 5 : complete
|
||||
}
|
||||
// call backend to create the account now
|
||||
// print_r($ret);
|
||||
} else {
|
||||
|
||||
}
|
||||
}
|
||||
// IF YOU GET HERE - ERROR PAGE
|
||||
// $this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('users/view_error', $data);
|
||||
// $this->load->view('templates/footer_boxed', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Welcome extends CI_Controller {
|
||||
|
||||
/**
|
||||
* Index Page for this controller.
|
||||
*
|
||||
* Maps to the following URL
|
||||
* http://example.com/index.php/welcome
|
||||
* - or -
|
||||
* http://example.com/index.php/welcome/index
|
||||
* - or -
|
||||
* Since this controller is set as the default controller in
|
||||
* config/routes.php, it's displayed at http://example.com/
|
||||
*
|
||||
* So any other public methods not prefixed with an underscore will
|
||||
* map to /index.php/welcome/<method_name>
|
||||
* @see https://codeigniter.com/user_guide/general/urls.html
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
$this->load->view('welcome_message');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Wrb404 extends CI_Controller {
|
||||
|
||||
public function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
public function index() {
|
||||
//echo 'Ameye';
|
||||
$this->output->set_status_header('404');
|
||||
$data['content'] = 'error_4042'; // View name
|
||||
|
||||
|
||||
$this->load->view('templates/header_boxed', $data);
|
||||
$this->load->view('errors/cli/error_wrb_404', $data); //loading in my template
|
||||
$this->load->view('users/view_external_footer');
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
class secureUserPage {
|
||||
|
||||
function __construct() {
|
||||
if (!isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
} else {
|
||||
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view('users/view_active', $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,320 @@
|
||||
<?php
|
||||
|
||||
class WRB_Controller extends CI_Controller {
|
||||
|
||||
var $template = array(
|
||||
'table_open' => "<table class='table table-sm table-striped table-hover table-bordered table-condensed'>",
|
||||
'thead_open' => '<thead class=\'bg-indigo\'>',
|
||||
'thead_close' => '</thead>',
|
||||
'heading_row_start' => '<tr>',
|
||||
'heading_row_end' => '</tr>',
|
||||
'heading_cell_start' => '<th>',
|
||||
'heading_cell_end' => '</th>',
|
||||
'tbody_open' => '<tbody>',
|
||||
'tbody_close' => '</tbody>',
|
||||
'row_start' => '<tr>',
|
||||
'row_end' => '</tr>',
|
||||
'cell_start' => '<td>',
|
||||
'cell_end' => '</td>',
|
||||
'row_alt_start' => '<tr>',
|
||||
'row_alt_end' => '</tr>',
|
||||
'cell_alt_start' => '<td>',
|
||||
'cell_alt_end' => '</td>',
|
||||
'table_close' => '</table>'
|
||||
);
|
||||
var $template_nohead = array(
|
||||
'table_open' => "<table class='table table-striped table-hover table-bordered table-condensed'>",
|
||||
'thead_open' => '<thead>',
|
||||
'thead_close' => '</thead>',
|
||||
'heading_row_start' => '<tr>',
|
||||
'heading_row_end' => '</tr>',
|
||||
'heading_cell_start' => '<th>',
|
||||
'heading_cell_end' => '</th>',
|
||||
'tbody_open' => '<tbody>',
|
||||
'tbody_close' => '</tbody>',
|
||||
'row_start' => '<tr>',
|
||||
'row_end' => '</tr>',
|
||||
'cell_start' => '<td>',
|
||||
'cell_end' => '</td>',
|
||||
'row_alt_start' => '<tr>',
|
||||
'row_alt_end' => '</tr>',
|
||||
'cell_alt_start' => '<td>',
|
||||
'cell_alt_end' => '</td>',
|
||||
'table_close' => '</table>'
|
||||
);
|
||||
public $data = array();
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
|
||||
$this->load->library(array('session', 'lib_login'));
|
||||
}
|
||||
|
||||
public function wrenchboard_api($in, $out) {
|
||||
$this->load->model('backend_model');
|
||||
// $out = array();
|
||||
return $this->backend_model->wrenchboard_api($in, $out);
|
||||
}
|
||||
|
||||
protected function smart_htmlspecialchars($str) {
|
||||
if (substr($str, 0, 1) == '<')
|
||||
return $str;
|
||||
return htmlspecialchars($str);
|
||||
}
|
||||
|
||||
protected function getSessionArray() {
|
||||
$data['username'] = $_SESSION['username']; // = $this->input->post('username');
|
||||
$data['name'] = $_SESSION['name']; // = $this->input->post('username');
|
||||
$data['firstname'] = $_SESSION['firstname']; // = $ret->firstname;
|
||||
$data['lastname'] = $_SESSION['lastname']; // = $ret->lastname;
|
||||
$data['email'] = $_SESSION['email']; // = $ret->email;
|
||||
$data['member_id'] = $_SESSION['member_id'];
|
||||
|
||||
$this->load->model('dash_model');
|
||||
$out = $this->dash_model->getDashData($data);
|
||||
$data['active_task'] = $out['active_task'];
|
||||
$data['active_pass_due'] = $out['active_pass_due'];
|
||||
$data['current_balance'] = $out['current_balance'];
|
||||
$data['new_message'] = $out['new_message'];
|
||||
$_SESSION["active_offers_count"] = $out['active_offers_count'];
|
||||
|
||||
$data = $_SESSION['secure_data'];
|
||||
$data['member_id'] = $_SESSION['member_id']; // = $ret->email;
|
||||
|
||||
$this->refreshAccountDetail($_SESSION['member_id']);
|
||||
return $data;
|
||||
}
|
||||
|
||||
protected function logUser($mlog) {
|
||||
//
|
||||
$data['action'] = WRENCHBOARD_LOG_MEMBER;
|
||||
$data['mlog'] = $mlog;
|
||||
$data['member_id'] = $_SESSION['member_id'];
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($data, $out);
|
||||
|
||||
$this->load->model('userlog_model');
|
||||
$xy["member_id"] = $_SESSION['member_id'];
|
||||
$_SESSION['member_log'] = $this->userlog_model->loadUserLog($xy);
|
||||
// print_r($out);
|
||||
}
|
||||
protected function myMessagesSnapshot() {
|
||||
|
||||
$str = "<li class='media'>
|
||||
<div class='media-left'>
|
||||
<img src='/assets/images/placeholder.jpg' class='img-circle img-sm' alt=''>
|
||||
</div>
|
||||
|
||||
<div class='media-body'>
|
||||
<a href='#' class='media-heading'>
|
||||
<span class='text-semibold'>System</span>
|
||||
<span class='media-annotation pull-right'>00:00</span>
|
||||
</a>
|
||||
|
||||
<span class='text-muted'>You have no pending messages</span>
|
||||
</div>
|
||||
</li>";
|
||||
|
||||
|
||||
return $str;
|
||||
/*
|
||||
<li class="media">
|
||||
<div class="media-left">
|
||||
<img src="/assets/images/placeholder.jpg" class="img-circle img-sm" alt="">
|
||||
<span class="badge bg-danger-400 media-badge">5</span>
|
||||
</div>
|
||||
|
||||
<div class="media-body">
|
||||
<a href="#" class="media-heading">
|
||||
<span class="text-semibold">James Alexander</span>
|
||||
<span class="media-annotation pull-right">04:58</span>
|
||||
</a>
|
||||
|
||||
<span class="text-muted">who knows, maybe that would be the best thing for me...</span>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<li class="media">
|
||||
<div class="media-left">
|
||||
<img src="/assets/images/placeholder.jpg" class="img-circle img-sm" alt="">
|
||||
<span class="badge bg-danger-400 media-badge">4</span>
|
||||
</div>
|
||||
|
||||
<div class="media-body">
|
||||
<a href="#" class="media-heading">
|
||||
<span class="text-semibold">Margo Baker</span>
|
||||
<span class="media-annotation pull-right">12:16</span>
|
||||
</a>
|
||||
|
||||
<span class="text-muted">That was something he was unable to do because...</span>
|
||||
</div>
|
||||
</li>
|
||||
*
|
||||
*/
|
||||
}
|
||||
|
||||
|
||||
protected function sql_escape_func($inp) {
|
||||
if (is_array($inp)) {
|
||||
return array_map(__METHOD__, $inp);
|
||||
}
|
||||
|
||||
|
||||
if (!empty($inp) && is_string($inp)) {
|
||||
return str_replace(array('\\', "\0", "\n", "\r", "'", '"', "\x1a"), array('\\\\', '\\0', '\\n', '\\r', "\\'", '\\"', '\\Z'), $inp);
|
||||
}
|
||||
|
||||
return $inp;
|
||||
}
|
||||
|
||||
protected function findOffers($email) {
|
||||
$this->load->model('offers_model');
|
||||
$this->offers_model->attachOffers($email);
|
||||
}
|
||||
|
||||
protected function home1($pagename='') {
|
||||
$data['sitename'] = 'home';
|
||||
$res = $this->getExtJobList();
|
||||
|
||||
$data['market_data'] = $res;
|
||||
|
||||
$data['why_list'] = $this->getExtWhyList();
|
||||
|
||||
|
||||
//$this->load->view('templates/header_boxed', $data);
|
||||
//
|
||||
$this->load->view('home/view_index1', $data);
|
||||
|
||||
|
||||
//$this->load->view('users/view_external_footer');
|
||||
}
|
||||
|
||||
protected function home2($pagename = '') {
|
||||
$data['sitename'] = 'home';
|
||||
$res = $this->getExtJobList();
|
||||
|
||||
$data['market_data'] = $res;
|
||||
|
||||
$data['why_list'] = $this->getExtWhyList();
|
||||
|
||||
$this->load->view('home2/header', $data);
|
||||
if ($pagename == '') {
|
||||
$this->load->view('home2/view_index2', $data);
|
||||
} else {
|
||||
$this->load->view($pagename, $data);
|
||||
}
|
||||
$this->load->view('home2/footer', $data);
|
||||
}
|
||||
|
||||
protected function readFixedText($text_key) {
|
||||
|
||||
$page_key = trim($text_key);
|
||||
$finaltxt = "";
|
||||
if ($page_key != '') {
|
||||
$mysql = "SELECT * FROM general_text WHERE page_key='$page_key'";
|
||||
$query = $this->db->query($mysql);
|
||||
if ($query->num_rows() == 0) {
|
||||
$finaltxt = "";
|
||||
} else {
|
||||
$row = $query->row();
|
||||
$finaltxt = $row->txt_detail;
|
||||
}
|
||||
}
|
||||
|
||||
return $finaltxt;
|
||||
}
|
||||
|
||||
protected function libraryContent($content_id) {
|
||||
$out = array();
|
||||
|
||||
$query = $this->db->query("SELECT * FROM library WHERE id = " . $content_id);
|
||||
if ($query->num_rows() > 0) {
|
||||
$row = $query->row();
|
||||
|
||||
$out['title'] = $row->title;
|
||||
$out['description'] = $row->description;
|
||||
$out['detail'] = $row->detail;
|
||||
}
|
||||
return $out;
|
||||
}
|
||||
|
||||
protected function getExtJobList() {
|
||||
|
||||
$mysql = "SELECT j.title,j.description,m.job_id,m.expire "
|
||||
. "FROM members_jobs_offer m "
|
||||
. "LEFT JOIN members_jobs j ON j.id=m.job_id "
|
||||
. "WHERE m.status = 1 AND m.client_id=0 "
|
||||
. "AND m.expire IS NOT NULL "
|
||||
. "AND m.public_view = 1 "
|
||||
. "ORDER BY m.expire DESC LIMIT 6";
|
||||
$query = $this->db->query($mysql);
|
||||
return $query->result();
|
||||
}
|
||||
|
||||
protected function getExtWhyList() {
|
||||
|
||||
$mysql = "SELECT * FROM why ORDER BY flags DESC";
|
||||
$query = $this->db->query($mysql);
|
||||
return $query->result();
|
||||
}
|
||||
|
||||
protected function getClientJobStats($client_id) {
|
||||
$out = array();
|
||||
$out['total_jobs_completed'] = $out['total_jobs_active'] = $data['total_jobs_uncompleted'] = 0;
|
||||
$out['total_pending_offers'] = 0;
|
||||
|
||||
$mysql = " SELECT count(*) AS total_jobs_completed FROM members_jobs_contract WHERE client_id =$client_id AND status = 5";
|
||||
$q = $this->db->query($mysql);
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['total_jobs_completed'] = $q->row()->total_jobs_completed;
|
||||
}
|
||||
|
||||
|
||||
$mysql = " SELECT count(*) AS total_jobs_active FROM members_jobs_contract WHERE client_id =$client_id AND status IN (1,2)";
|
||||
$q = $this->db->query($mysql);
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['total_jobs_active'] = $q->row()->total_jobs_active;
|
||||
}
|
||||
|
||||
|
||||
$mysql = " SELECT count(*) AS total_jobs_uncompleted FROM members_jobs_contract WHERE client_id =$client_id AND status NOT IN (1,2,5)";
|
||||
$q = $this->db->query($mysql);
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['total_jobs_uncompleted'] = $q->row()->total_jobs_uncompleted;
|
||||
}
|
||||
|
||||
$mysql = " SELECT count(*) AS total_pending_offers FROM members_jobs_offer WHERE client_id =$client_id AND status=1";
|
||||
$q = $this->db->query($mysql);
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['total_pending_offers'] = $q->row()->total_pending_offers;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
return $out; //['escrow_c_offer'] + $out['escrow_balance'];
|
||||
}
|
||||
|
||||
protected function renderMobileSecurePage($mobile_page_name, $data) {
|
||||
$this->load->view('mobile/secure/mobile_secure_header', $data);
|
||||
$this->load->view('mobile/secure/' . $mobile_page_name, $data);
|
||||
$this->load->view('mobile/secure/mobile_secure_footer', $data);
|
||||
}
|
||||
|
||||
/*
|
||||
* wrenchboard=> \d library
|
||||
Table "public.library"
|
||||
Column | Type | Modifiers
|
||||
-------------+-----------------------------+------------------------------------------------------
|
||||
id | integer | not null default nextval('library_id_seq'::regclass)
|
||||
title | character varying(150) | not null
|
||||
description | character varying(500) | not null
|
||||
detail | text |
|
||||
updated | timestamp without time zone | default now()
|
||||
Indexes:
|
||||
"library_id_key" UNIQUE CONSTRAINT, btree (id)
|
||||
"library_title_key" UNIQUE CONSTRAINT, btree (title)
|
||||
|
||||
*/
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,173 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Bko_Controller extends WRB_Controller {
|
||||
|
||||
var $template = array(
|
||||
'table_open' => "<table class='table table-striped table-hover table-bordered table-condensed'>",
|
||||
'thead_open' => '<thead class=\'bg-indigo\'>',
|
||||
'thead_close' => '</thead>',
|
||||
'heading_row_start' => '<tr>',
|
||||
'heading_row_end' => '</tr>',
|
||||
'heading_cell_start' => '<th>',
|
||||
'heading_cell_end' => '</th>',
|
||||
'tbody_open' => '<tbody>',
|
||||
'tbody_close' => '</tbody>',
|
||||
'row_start' => '<tr>',
|
||||
'row_end' => '</tr>',
|
||||
'cell_start' => '<td>',
|
||||
'cell_end' => '</td>',
|
||||
'row_alt_start' => '<tr>',
|
||||
'row_alt_end' => '</tr>',
|
||||
'cell_alt_start' => '<td>',
|
||||
'cell_alt_end' => '</td>',
|
||||
'table_close' => '</table>'
|
||||
);
|
||||
public $data = array();
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
if (!isset($_SESSION['bko_username']) or $_SESSION['bko_username'] == '') {
|
||||
redirect(home);
|
||||
}
|
||||
|
||||
//print_r($_SESSION);
|
||||
}
|
||||
|
||||
// protected
|
||||
|
||||
protected function bkoDashData() {
|
||||
$this->load->model('backend_model');
|
||||
$is_live = $this->backend_model->cfgReadChar("system.live");
|
||||
$data = array();
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT '<b>ADDED:</b>'||added::date||'<br><b>EXPIRE:</b>'||expire::date||'<br>'||username||'<br><b>Name:</b>'||firstname||' '||lastname AS signup,"
|
||||
. " (CASE WHEN status=1 THEN '<div id=\"btu'||id||'\"><button id=\"acc'||id||'\" class=\"btn btn-info btn-xs\" onclick=\"return resendLink('''||id||''');\" >Resend</button></div>' ELSE ' ' END) AS action ,"
|
||||
. " (CASE WHEN status=1 THEN '<div id=\"dtu'||id||'\"><button id=\"del'||id||'\" class=\"btn btn-warning btn-xs\" onclick=\"return deleteLink('''||id||''');\" >Del</button></div>' ELSE ' ' END) AS Del "
|
||||
. " FROM members_pending WHERE expire> now() AND status = 1"
|
||||
. " ORDER BY id desc limit 5";
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Dates', 'Username', 'Name', 'Action');
|
||||
$this->table->set_heading(array('data' => 'Date/Email/Name', 'style' => 'width:180px'), array('data' => 'RES', 'style' => 'width:20px; cellpadding:0px;'), array('data' => 'Del', 'style' => 'width:20px; cellpadding:0px;'));
|
||||
|
||||
$data['pending_dash_table'] = $this->table->generate($query);
|
||||
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SElECT added::date||'<br>'||loc AS dates,email||'<br>'||firstname||' '||lastname AS Name FROM members ORDER BY id DESC LIMIT 7";
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Account', 'Created', 'Action');
|
||||
$this->table->set_heading(array('data' => 'Date/LOC', 'style' => 'width:140px'), 'Email/Name');
|
||||
|
||||
$data['signup_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
// PUBIC active JOB table
|
||||
$mysql = "SELECT jo.expire,jo.id AS offer_id, jo.offer_code,mj.title,mj.description,mj.timeline_days,mj.price,jo.job_description FROM members_jobs_offer jo "
|
||||
. " LEFT JOIN members_jobs mj ON mj.id=jo.job_id "
|
||||
. " WHERE mj.status=1 AND jo.status=1 "
|
||||
. " AND jo.expire> now() AND jo.public_view > 0";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading(array('data' => 'Date/LOC', 'style' => 'width:140px'), 'Email/Name');
|
||||
|
||||
$data['active_publicjob_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
|
||||
// Active Jobs
|
||||
$jbx = "";
|
||||
|
||||
$mysql = "SELECT '<b>Project ID:</b>'||mc.contract||'<br><b>Title:</b>'||mc.title AS Project,m.firstname||' '||m.lastname||'<br>'||m.email AS Client,"
|
||||
. " '<b>Timeline:</b> '||mc.timeline_days||' day(s)<br><b>Price:</b>'||mc.price*0.01 AS terms ,mc.description||'<br><b>Delivery Date :</b>'||mc.delivery_date As Description,"
|
||||
. " '<input type=submit onclick=\"return post_nav_find_action($jbx, '||mc.id||')\" name=\"manage\" class=\"btn btn-info btn-xs\" value=\"Manage\">' AS manage,mc.status "
|
||||
. "FROM members_jobs_contract mc LEFT JOIN members m ON m.id=mc.client_id LIMIT 10"; // WHERE mc.member_id = " . $_SESSION['member_id']." OR mc.client_id =". $_SESSION['member_id'];
|
||||
|
||||
$mysql = "SELECT '<b>'||mj.contract||'</b><br>'||mo.title AS thejob,'<b>Owner: </b>'||m1.firstname||' '||m1.lastname||' <br>'|| m1.email||'<br><b>Client: </b>'||m2.firstname||' '||m2.lastname||' <br>'|| m2.email AS Team1 "
|
||||
. "FROM members_jobs_contract mj "
|
||||
. "LEFT JOIN members_jobs mo ON mo.id=mj.job_id "
|
||||
. "LEFT JOIN members m1 ON m1.id=mj.member_id "
|
||||
. "LEFT JOIN members m2 ON m2.id=mj.client_id "
|
||||
. "WHERE mj.status IN (1,2) AND mj.delivery_date > now() ORDER by mj.id DESC LIMIT 5 ";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
//$this->table->set_heading('Job', 'Client', 'Terms', 'Description', 'Manage', 'Status');
|
||||
$this->table->set_heading(array('data' => 'Task', 'style' => 'width:180px'), 'Members');
|
||||
$data['job_active_dash_table'] = $this->table->generate($query);
|
||||
|
||||
$mysql = "SELECT '<b>'||mj.contract||'</b><br>'||mo.title AS thejob,'<b>Owner: </b>'||m1.firstname||' '||m1.lastname||' <br>'|| m1.email||'<br><b>Client: </b>'||m2.firstname||' '||m2.lastname||' <br>'|| m2.email AS Team1 "
|
||||
. "FROM members_jobs_contract mj "
|
||||
. "LEFT JOIN members_jobs mo ON mo.id=mj.job_id "
|
||||
. "LEFT JOIN members m1 ON m1.id=mj.member_id "
|
||||
. "LEFT JOIN members m2 ON m2.id=mj.client_id "
|
||||
. "WHERE mj.status IN (1,2) AND mj.delivery_date < now() ORDER by mj.id DESC LIMIT 5 ";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading(array('data' => 'Task', 'style' => 'width:180px'), 'Members');
|
||||
$data['job_pastdue_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
$mysql = "SELECT '<b>Added: </b>'||m.added::date ||'<br><b>Amount: </b>'||m.terminatingamount*0.01||'<br><b>Fee: </b>'|| m.fee*0.01 as trans, "
|
||||
. "r.firstname||' '||r.lastname||'<br><b>Acc:</b>'||r.account_no||'-'||b.name||'<br><b>Confirm: </b>'||mp.confirmation AS Recitient,"
|
||||
. "CASE WHEN m.status=1 THEN 'Pending' WHEN m.status=3 THEN 'Cancelled' WHEN m.status=5 THEN 'Completed' ELSE '' END AS Status "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN sendmoney_recipient r ON r.id = m.recipientid "
|
||||
. "LEFT JOIN bank_entity_codes b ON b.code = r.bank_code "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "WHERE mp.confirmation IS NOT NULL ORDER BY m.id DESC LIMIT 4";
|
||||
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading('Trans', 'Target', 'Status');
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
|
||||
$mysql = "SELECT created,'From: <b>'||email||'</b><br>'|| ( CASE WHEN status=1 THEn '<input type=submit id=\"dacc'||id||'\" onclick=\"return replyMessage('||id||')\" name=\"reply\" class=\"btn btn-info btn-xs\" value=\"Reply\">' ELSE '' END )||'<br>'||your_message AS your_message "
|
||||
. " FROM contacts order by id desc lIMIT 6";
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading(array('data' => 'Added', 'style' => 'width:110px'), 'Message');
|
||||
$data['contact_dash_table'] = $this->table->generate($query);
|
||||
|
||||
$data['members_dash_online'] = 0;
|
||||
|
||||
// Jobs Messages
|
||||
$sqlMsg = "SELECT created, (CASE WHEN msg_type='FILE' THEN '<a target=\"_blank\" href=\"/smedia/" . ($is_live ? "LIVE" : "TEST") . "/contract/'||contract||'/'||message||'\">'||message||'</a>' "
|
||||
. "ELSE '<b>'||created||'</b><br>'||message END) as msg FROM jobs_contract_message ORDER BY id DESC LIMIT 10"; // WHERE contract='".$data['contract_id']."'";
|
||||
// Jobs Messages
|
||||
$sqlMsg = "SELECT j.created, (CASE WHEN j.msg_type='FILE' THEN '<a target=\"_blank\" href=\"/smedia/" . ($is_live ? "LIVE" : "TEST") . "/contract/'||j.contract||'/'||j.message||'\">'||j.message||'</a>' "
|
||||
. "ELSE '<b>['||m.firstname||'-'||m.username||']->'||j.created||'</b><br>'||j.message END) as msg FROM jobs_contract_message j LEFT JOIN members m ON m.id=j.member_id ORDER BY j.id DESC LIMIT 10"; // WHERE contract='".$data['contract_id']."'";
|
||||
$query_message = $this->db->query($sqlMsg);
|
||||
//$this->table->set_heading('');
|
||||
$this->table->set_heading(array('data' => 'Added', 'style' => 'width:110px'), 'Activity Message');
|
||||
$data['message_dash_table'] = $this->table->generate($query_message);
|
||||
|
||||
|
||||
$data['total_members'] = 0;
|
||||
$data['total_balance'] = 0;
|
||||
$data['total_active_jobs'] = 0;
|
||||
|
||||
|
||||
|
||||
$mysql = "SELECT count(id) AS total_members FROM members WHERE status =1";
|
||||
$query = $this->db->query($mysql);
|
||||
$row = $query->row_array();
|
||||
$data['total_members'] = $row['total_members'];
|
||||
|
||||
$mysql = "SELECT sum(balance)AS total_balance FROM members WHERE status =1";
|
||||
$query = $this->db->query($mysql);
|
||||
$row = $query->row_array();
|
||||
$data['total_balance'] = $row['total_balance'];
|
||||
|
||||
$mysql = "SELECT count(id) AS total_active_jobs FROM members_jobs_contract WHERE status IN (1,2)";
|
||||
$query = $this->db->query($mysql);
|
||||
$row = $query->row_array();
|
||||
$data['total_active_jobs'] = $row['total_active_jobs'];
|
||||
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
class Mobile_Controller extends WRB_Controller {
|
||||
|
||||
public $data = array();
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
|
||||
|
||||
//$this->renderMobileExtPage('mobile_index', $data);
|
||||
$this->load->model('mobile_detect');
|
||||
|
||||
$phoneH = $this->mobile_detect->getMobileHeaders();
|
||||
$imb = $this->mobile_detect->isMobile();
|
||||
|
||||
$mob_strict = false;
|
||||
|
||||
if ($mob_strict == true) {
|
||||
if ($img == false) {
|
||||
redirect('/');
|
||||
} else {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,189 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Bkomember_Controller extends Bko_Controller {
|
||||
|
||||
var $template = array(
|
||||
'table_open' => "<table class='table table-striped table-hover table-bordered table-condensed'>",
|
||||
'thead_open' => '<thead class=\'bg-indigo\'>',
|
||||
'thead_close' => '</thead>',
|
||||
'heading_row_start' => '<tr>',
|
||||
'heading_row_end' => '</tr>',
|
||||
'heading_cell_start' => '<th>',
|
||||
'heading_cell_end' => '</th>',
|
||||
'tbody_open' => '<tbody>',
|
||||
'tbody_close' => '</tbody>',
|
||||
'row_start' => '<tr>',
|
||||
'row_end' => '</tr>',
|
||||
'cell_start' => '<td>',
|
||||
'cell_end' => '</td>',
|
||||
'row_alt_start' => '<tr>',
|
||||
'row_alt_end' => '</tr>',
|
||||
'cell_alt_start' => '<td>',
|
||||
'cell_alt_end' => '</td>',
|
||||
'table_close' => '</table>'
|
||||
);
|
||||
|
||||
public $data = array();
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
if (!isset($_SESSION['bko_selected_id']) or $_SESSION['bko_selected_id'] == '' or $_SESSION['bko_selected_id'] <= 0 ) {
|
||||
redirect('/bkouser/locate');
|
||||
}
|
||||
}
|
||||
|
||||
// protected
|
||||
|
||||
|
||||
|
||||
protected function bkoUserDashData($member_id) {
|
||||
$this->load->model('backend_model');
|
||||
$is_live = $this->backend_model->cfgReadChar("system.live");
|
||||
$data = array();
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
|
||||
|
||||
$short_limit = 10;
|
||||
|
||||
// MY JOBS
|
||||
$mysql = "SELECT created,title FROM members_jobs WHERE member_id = $member_id ORDER BY id DESC limit $short_limit";
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading(array('data' => 'Date', 'style' => 'width:110px'), 'Title');
|
||||
$data['member_job_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
// MY CONTRACTS
|
||||
$mysql = "SELECT created,title,status,client_id FROM members_jobs_contract WHERE member_id = $member_id ORDER BY id DESC LIMIT $short_limit";
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading(array('data' => 'Date', 'style' => 'width:110px'), 'Title', array('data' => 'ST', 'style' => 'width:40px'), 'client');
|
||||
$data['member_contract_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
// Jobs Messages
|
||||
$sqlMsg = " SELECT j.created, (CASE WHEN j.msg_type='FILE' THEN '<a target=\"_blank\" href=\"/smedia/" . ($is_live ? "LIVE" : "TEST") . "/contract/'||j.contract||'/'||j.message||'\">'||j.message||'</a>' "
|
||||
. " ELSE '<b>['||m.firstname||'-'||m.username||']->'||j.created||'</b><br>'||j.message END) as msg "
|
||||
. " FROM jobs_contract_message j LEFT JOIN members m ON m.id=j.member_id "
|
||||
. " WHERE j.member_id = $member_id ORDER BY j.id DESC LIMIT $short_limit";
|
||||
|
||||
$query_message = $this->db->query($sqlMsg);
|
||||
//$this->table->set_heading('');
|
||||
$this->table->set_heading(array('data' => 'Added', 'style' => 'width:110px'), 'Activity Message');
|
||||
$data['message_dash_table'] = $this->table->generate($query_message);
|
||||
|
||||
|
||||
|
||||
// Active Jobs
|
||||
$mysql = "SELECT '<b>'||mj.contract||'</b><br>'||mo.title AS thejob,'<b>Owner: </b>'||m1.firstname||' '||m1.lastname||' <br>'|| m1.email||'<br><b>Client: </b>'||m2.firstname||' '||m2.lastname||' <br>'|| m2.email AS Team1 "
|
||||
. "FROM members_jobs_contract mj "
|
||||
. "LEFT JOIN members_jobs mo ON mo.id=mj.job_id "
|
||||
. "LEFT JOIN members m1 ON m1.id=mj.member_id "
|
||||
. "LEFT JOIN members m2 ON m2.id=mj.client_id "
|
||||
. "WHERE mj.status IN (1,2) AND mj.delivery_date > now() AND mj.member_id = $member_id ORDER by mj.id DESC LIMIT $short_limit ";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading('Task', array('data' => 'Members', 'style' => 'width:150px'));
|
||||
$data['job_active_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
// PAST DUE JOBS
|
||||
$mysql = "SELECT '<b>'||mj.contract||'</b><br>'||mo.title AS thejob,'<b>Owner: </b>'||m1.firstname||' '||m1.lastname||' <br>'|| m1.email||'<br><b>Client: </b>'||m2.firstname||' '||m2.lastname||' <br>'|| m2.email AS Team1 "
|
||||
. "FROM members_jobs_contract mj "
|
||||
. "LEFT JOIN members_jobs mo ON mo.id=mj.job_id "
|
||||
. "LEFT JOIN members m1 ON m1.id=mj.member_id "
|
||||
. "LEFT JOIN members m2 ON m2.id=mj.client_id "
|
||||
. "WHERE mj.status IN (1,2) AND mj.delivery_date < now() AND mj.member_id = $member_id ORDER by mj.id DESC LIMIT $short_limit ";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading('Task', array('data' => 'Members', 'style' => 'width:150px'));
|
||||
$data['job_pastdue_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
|
||||
|
||||
$jbx = "";
|
||||
|
||||
$mysql = "SELECT '<b>ADDED:</b>'||added::date||'<br><b>EXPIRE:</b>'||expire::date As Dates,username||'<br><b>Name:</b>'||firstname||' '||lastname AS signup,"
|
||||
. " (CASE WHEN status=1 THEN '<div id=\"btu'||id||'\"><button id=\"acc'||id||'\" class=\"btn btn-info btn-xs\" onclick=\"return resendLink('''||id||''');\" >Resend</button></div>' ELSE ' ' END) AS action ,"
|
||||
. " (CASE WHEN status=1 THEN '<div id=\"dtu'||id||'\"><button id=\"del'||id||'\" class=\"btn btn-warning btn-xs\" onclick=\"return deleteLink('''||id||''');\" >Del</button></div>' ELSE ' ' END) AS Del "
|
||||
. " FROM members_pending WHERE expire> now() AND status = 1"
|
||||
. " ORDER BY id desc limit 5";
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Dates', 'Username', 'Name', 'Action');
|
||||
$this->table->set_heading(array('data' => 'Date', 'style' => 'width:180px'), 'Email/Name', array('data' => 'RES', 'style' => 'width:40px; cellpadding:0px;'), array('data' => 'Del', 'style' => 'width:40px; cellpadding:0px;'));
|
||||
|
||||
$data['pending_dash_table'] = $this->table->generate($query);
|
||||
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SElECT added::date||'<br>'||loc AS dates,email||'<br>'||firstname||' '||lastname AS Name FROM members ORDER BY id DESC LIMIT 7";
|
||||
$query = $this->db->query($mysql);
|
||||
// $this->table->set_heading('Account', 'Created', 'Action');
|
||||
$this->table->set_heading(array('data' => 'Date/LOC', 'style' => 'width:140px'), 'Email/Name');
|
||||
|
||||
$data['signup_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$mysql = "SELECT '<b>Added: </b>'||m.added::date ||'<br><b>Amount: </b>'||m.terminatingamount*0.01||'<br><b>Fee: </b>'|| m.fee*0.01 as trans, "
|
||||
. "r.firstname||' '||r.lastname||'<br><b>Acc:</b>'||r.account_no||'-'||b.name||'<br><b>Confirm: </b>'||mp.confirmation AS Recitient,"
|
||||
. "CASE WHEN m.status=1 THEN 'Pending' WHEN m.status=3 THEN 'Cancelled' WHEN m.status=5 THEN 'Completed' ELSE '' END AS Status "
|
||||
. "FROM money_transfer m "
|
||||
. "LEFT JOIN sendmoney_recipient r ON r.id = m.recipientid "
|
||||
. "LEFT JOIN bank_entity_codes b ON b.code = r.bank_code "
|
||||
. "LEFT JOIN members_payments mp ON mp.what_sendmoney = m.id "
|
||||
. "WHERE mp.confirmation IS NOT NULL ORDER BY m.id DESC LIMIT 4";
|
||||
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading('Trans', 'Target', 'Status');
|
||||
$data['sendmoney_dash_table'] = $this->table->generate($query);
|
||||
|
||||
|
||||
|
||||
$mysql = "SELECT created,'From: <b>'||email||'</b><br>'|| ( CASE WHEN status=1 THEn '<input type=submit id=\"dacc'||id||'\" onclick=\"return replyMessage('||id||')\" name=\"reply\" class=\"btn btn-info btn-xs\" value=\"Reply\">' ELSE '' END )||'<br>'||your_message AS your_message "
|
||||
. " FROM contacts order by id desc lIMIT 6";
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading(array('data' => 'Added', 'style' => 'width:110px'), 'Message');
|
||||
$data['contact_dash_table'] = $this->table->generate($query);
|
||||
|
||||
$data['members_dash_online'] = 0;
|
||||
|
||||
|
||||
|
||||
|
||||
$data['total_members'] = 0;
|
||||
$data['total_balance'] = 0;
|
||||
$data['total_active_jobs'] = 0;
|
||||
|
||||
|
||||
|
||||
$mysql = "SELECT count(id) AS total_members FROM members WHERE status =1";
|
||||
$query = $this->db->query($mysql);
|
||||
$row = $query->row_array();
|
||||
$data['total_members'] = $row['total_members'];
|
||||
|
||||
$mysql = "SELECT sum(balance)AS total_balance FROM members WHERE status =1";
|
||||
$query = $this->db->query($mysql);
|
||||
$row = $query->row_array();
|
||||
$data['total_balance'] = $row['total_balance'];
|
||||
|
||||
$mysql = "SELECT count(id) AS total_active_jobs FROM members_jobs_contract WHERE status IN (1,2)";
|
||||
$query = $this->db->query($mysql);
|
||||
$row = $query->row_array();
|
||||
$data['total_active_jobs'] = $row['total_active_jobs'];
|
||||
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,407 @@
|
||||
<?php defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
require_once 'vendor/facebook/php-sdk-v4/src/Facebook/autoload.php';
|
||||
|
||||
/**
|
||||
* Facebook PHP SDK for CodeIgniter 3
|
||||
*
|
||||
* Library wrapper for Facebook PHP SDK. Check user login status, publish to feed
|
||||
* and more with easy to use CodeIgniter syntax.
|
||||
*
|
||||
* This library requires the Facebook PHP SDK to be installed with Composer, and that CodeIgniter
|
||||
* config is set to autoload the vendor folder. More information in the CodeIgniter user guide at
|
||||
* http://www.codeigniter.com/userguide3/general/autoloader.html?highlight=composer
|
||||
*
|
||||
* It also requires CodeIgniter session library to be correctly configured.
|
||||
*
|
||||
* @package CodeIgniter
|
||||
* @category Libraries
|
||||
* @author Mattias Hedman
|
||||
* @license MIT
|
||||
* @link https://github.com/darkwhispering/facebook-sdk-codeigniter
|
||||
* @version 3.0.0
|
||||
*/
|
||||
use Facebook\Facebook as FB;
|
||||
use Facebook\Authentication\AccessToken;
|
||||
use Facebook\Exceptions\FacebookResponseException;
|
||||
use Facebook\Exceptions\FacebookSDKException;
|
||||
use Facebook\FacebookBatchResponse;
|
||||
use Facebook\Helpers\FacebookCanvasHelper;
|
||||
use Facebook\Helpers\FacebookJavaScriptHelper;
|
||||
use Facebook\Helpers\FacebookPageTabHelper;
|
||||
use Facebook\Helpers\FacebookRedirectLoginHelper;
|
||||
Class Facebook
|
||||
{
|
||||
const UPLOAD_TYPE_VIDEO = 'video';
|
||||
const UPLOAD_TYPE_IMAGE = 'image';
|
||||
/**
|
||||
* @var FB
|
||||
*/
|
||||
private $fb;
|
||||
/**
|
||||
* @var FacebookRedirectLoginHelper|FacebookCanvasHelper|FacebookJavaScriptHelper|FacebookPageTabHelper
|
||||
*/
|
||||
private $helper;
|
||||
/**
|
||||
* @var array
|
||||
*/
|
||||
private $batch_request_pool = [];
|
||||
/**
|
||||
* Facebook constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
// Load config
|
||||
$this->load->config('facebook');
|
||||
// Load required libraries and helpers
|
||||
$this->load->library('session');
|
||||
$this->load->helper('url');
|
||||
if (!isset($this->fb))
|
||||
{
|
||||
$this->fb = new FB([
|
||||
'app_id' => $this->config->item('facebook_app_id'),
|
||||
'app_secret' => $this->config->item('facebook_app_secret'),
|
||||
'default_graph_version' => $this->config->item('facebook_graph_version')
|
||||
]);
|
||||
}
|
||||
// Load correct helper depending on login type
|
||||
// set in the config file
|
||||
switch ($this->config->item('facebook_login_type'))
|
||||
{
|
||||
case 'js':
|
||||
$this->helper = $this->fb->getJavaScriptHelper();
|
||||
break;
|
||||
case 'canvas':
|
||||
$this->helper = $this->fb->getCanvasHelper();
|
||||
break;
|
||||
case 'page_tab':
|
||||
$this->helper = $this->fb->getPageTabHelper();
|
||||
break;
|
||||
case 'web':
|
||||
$this->helper = $this->fb->getRedirectLoginHelper();
|
||||
break;
|
||||
}
|
||||
if ($this->config->item('facebook_auth_on_load') === TRUE)
|
||||
{
|
||||
// Try and authenticate the user right away (aka, get valid access token)
|
||||
$this->authenticate();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* @return FB
|
||||
*/
|
||||
public function object()
|
||||
{
|
||||
return $this->fb;
|
||||
}
|
||||
/**
|
||||
* Check if user are logged in by checking if we have a Facebook
|
||||
* session active.
|
||||
*
|
||||
* @return mixed|boolean
|
||||
*/
|
||||
public function is_authenticated()
|
||||
{
|
||||
$access_token = $this->authenticate();
|
||||
if (isset($access_token))
|
||||
{
|
||||
return $access_token;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
/**
|
||||
* Do Graph request
|
||||
*
|
||||
* @param $method
|
||||
* @param $endpoint
|
||||
* @param array $params
|
||||
* @param null $access_token
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function request($method, $endpoint, $params = [], $access_token = null)
|
||||
{
|
||||
try
|
||||
{
|
||||
$response = $this->fb->{strtolower($method)}($endpoint, $params, $access_token);
|
||||
return $response->getDecodedBody();
|
||||
}
|
||||
catch(FacebookResponseException $e)
|
||||
{
|
||||
return $this->logError($e->getCode(), $e->getMessage());
|
||||
}
|
||||
catch (FacebookSDKException $e)
|
||||
{
|
||||
return $this->logError($e->getCode(), $e->getMessage());
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Upload image or video to user profile
|
||||
*
|
||||
* @param $path_to_file
|
||||
* @param array $params
|
||||
* @param string $type
|
||||
* @param null $access_token
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function user_upload_request($path_to_file, $params = [], $type = self::UPLOAD_TYPE_IMAGE, $access_token = null)
|
||||
{
|
||||
if ($type === self::UPLOAD_TYPE_IMAGE)
|
||||
{
|
||||
$data = ['source' => $this->fb->fileToUpload($path_to_file)] + $params;
|
||||
$endpoint = '/me/photos';
|
||||
}
|
||||
elseif ($type === self::UPLOAD_TYPE_VIDEO)
|
||||
{
|
||||
$data = ['source' => $this->fb->videoToUpload($path_to_file)] + $params;
|
||||
$endpoint = '/me/videos';
|
||||
}
|
||||
else
|
||||
{
|
||||
return $this->logError(400, 'Invalid upload type');
|
||||
}
|
||||
try
|
||||
{
|
||||
$response = $this->fb->post($endpoint, $data, $access_token);
|
||||
return $response->getDecodedBody();
|
||||
}
|
||||
catch(FacebookSDKException $e)
|
||||
{
|
||||
return $this->logError($e->getCode(), $e->getMessage());
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Add request to batch
|
||||
*
|
||||
* @param $key
|
||||
* @param $method
|
||||
* @param $endpoint
|
||||
* @param array $params
|
||||
* @param null $access_token
|
||||
*/
|
||||
public function add_to_batch_pool($key, $method, $endpoint, $params = [], $access_token = null)
|
||||
{
|
||||
$this->batch_request_pool = array_merge(
|
||||
$this->batch_request_pool,
|
||||
[$key => $this->fb->request($method, $endpoint, $params, $access_token)]
|
||||
);
|
||||
}
|
||||
/**
|
||||
* Remove request from batch
|
||||
*
|
||||
* @param $key
|
||||
*/
|
||||
public function remove_from_batch_pool($key)
|
||||
{
|
||||
if (isset($this->batch_request_pool[$key]))
|
||||
{
|
||||
unset($this->batch_request_pool[$key]);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Send all request in the batch pool
|
||||
*
|
||||
* @return array|FacebookBatchResponse
|
||||
*/
|
||||
public function send_batch_pool()
|
||||
{
|
||||
try
|
||||
{
|
||||
$responses = $this->fb->sendBatchRequest($this->batch_request_pool);
|
||||
$this->batch_request_pool = [];
|
||||
$data = [];
|
||||
foreach ($responses as $key => $response)
|
||||
{
|
||||
$data[$key] = $response->getDecodedBody();
|
||||
}
|
||||
return $data;
|
||||
}
|
||||
catch(FacebookResponseException $e)
|
||||
{
|
||||
return $this->logError($e->getCode(), $e->getMessage());
|
||||
}
|
||||
catch(FacebookSDKException $e)
|
||||
{
|
||||
return $this->logError($e->getCode(), $e->getMessage());
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Generate Facebook login url for Facebook Redirect Login (web)
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function login_url()
|
||||
{
|
||||
// Login type must be web, else return empty string
|
||||
if ($this->config->item('facebook_login_type') != 'web')
|
||||
{
|
||||
return '';
|
||||
}
|
||||
return $this->helper->getLoginUrl(
|
||||
base_url() . $this->config->item('facebook_login_redirect_url'),
|
||||
$this->config->item('facebook_permissions')
|
||||
);
|
||||
}
|
||||
/**
|
||||
* Generate Facebook login url for Facebook Redirect Login (web)
|
||||
*
|
||||
* @return string
|
||||
* @throws FacebookSDKException
|
||||
*/
|
||||
public function logout_url()
|
||||
{
|
||||
// Login type must be web, else return empty string
|
||||
if ($this->config->item('facebook_login_type') != 'web')
|
||||
{
|
||||
return '';
|
||||
}
|
||||
// Create logout url
|
||||
return $this->helper->getLogoutUrl(
|
||||
$this->get_access_token(),
|
||||
base_url() . $this->config->item('facebook_logout_redirect_url')
|
||||
);
|
||||
}
|
||||
/**
|
||||
* Destroy our local Facebook session
|
||||
*/
|
||||
public function destroy_session()
|
||||
{
|
||||
$this->session->unset_userdata('fb_access_token');
|
||||
}
|
||||
/**
|
||||
* Get a new access token from Facebook
|
||||
*
|
||||
* @return array|AccessToken|null|object|void
|
||||
*/
|
||||
private function authenticate()
|
||||
{
|
||||
$access_token = $this->get_access_token();
|
||||
if ($access_token && $this->get_expire_time() > (time() + 30) || $access_token && !$this->get_expire_time())
|
||||
{
|
||||
$this->fb->setDefaultAccessToken($access_token);
|
||||
return $access_token;
|
||||
}
|
||||
// If we did not have a stored access token or if it has expired, try get a new access token
|
||||
if (!$access_token)
|
||||
{
|
||||
try
|
||||
{
|
||||
$access_token = $this->helper->getAccessToken();
|
||||
}
|
||||
catch (FacebookSDKException $e)
|
||||
{
|
||||
$this->logError($e->getCode(), $e->getMessage());
|
||||
return null;
|
||||
}
|
||||
// If we got a session we need to exchange it for a long lived session.
|
||||
if (isset($access_token))
|
||||
{
|
||||
$access_token = $this->long_lived_token($access_token);
|
||||
$this->set_expire_time($access_token->getExpiresAt());
|
||||
$this->set_access_token($access_token);
|
||||
$this->fb->setDefaultAccessToken($access_token);
|
||||
return $access_token;
|
||||
}
|
||||
}
|
||||
// Collect errors if any when using web redirect based login
|
||||
if ($this->config->item('facebook_login_type') === 'web')
|
||||
{
|
||||
if ($this->helper->getError())
|
||||
{
|
||||
// Collect error data
|
||||
$error = array(
|
||||
'error' => $this->helper->getError(),
|
||||
'error_code' => $this->helper->getErrorCode(),
|
||||
'error_reason' => $this->helper->getErrorReason(),
|
||||
'error_description' => $this->helper->getErrorDescription()
|
||||
);
|
||||
return $error;
|
||||
}
|
||||
}
|
||||
return $access_token;
|
||||
}
|
||||
/**
|
||||
* Exchange short lived token for a long lived token
|
||||
*
|
||||
* @param AccessToken $access_token
|
||||
*
|
||||
* @return AccessToken|null
|
||||
*/
|
||||
private function long_lived_token(AccessToken $access_token)
|
||||
{
|
||||
if (!$access_token->isLongLived())
|
||||
{
|
||||
$oauth2_client = $this->fb->getOAuth2Client();
|
||||
try
|
||||
{
|
||||
return $oauth2_client->getLongLivedAccessToken($access_token);
|
||||
}
|
||||
catch (FacebookSDKException $e)
|
||||
{
|
||||
$this->logError($e->getCode(), $e->getMessage());
|
||||
return null;
|
||||
}
|
||||
}
|
||||
return $access_token;
|
||||
}
|
||||
/**
|
||||
* Get stored access token
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
private function get_access_token()
|
||||
{
|
||||
return $this->session->userdata('fb_access_token');
|
||||
}
|
||||
/**
|
||||
* Store access token
|
||||
*
|
||||
* @param AccessToken $access_token
|
||||
*/
|
||||
private function set_access_token(AccessToken $access_token)
|
||||
{
|
||||
$this->session->set_userdata('fb_access_token', $access_token->getValue());
|
||||
}
|
||||
/**
|
||||
* @return mixed
|
||||
*/
|
||||
private function get_expire_time()
|
||||
{
|
||||
return $this->session->userdata('fb_expire');
|
||||
}
|
||||
/**
|
||||
* @param DateTime $time
|
||||
*/
|
||||
private function set_expire_time(DateTime $time = null)
|
||||
{
|
||||
if ($time) {
|
||||
$this->session->set_userdata('fb_expire', $time->getTimestamp());
|
||||
}
|
||||
}
|
||||
/**
|
||||
* @param $code
|
||||
* @param $message
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
private function logError($code, $message)
|
||||
{
|
||||
log_message('error', '[FACEBOOK PHP SDK] code: ' . $code.' | message: '.$message);
|
||||
return ['error' => $code, 'message' => $message];
|
||||
}
|
||||
/**
|
||||
* Enables the use of CI super-global without having to define an extra variable.
|
||||
* I can't remember where I first saw this, so thank you if you are the original author.
|
||||
*
|
||||
* Borrowed from the Ion Auth library (http://benedmunds.com/ion_auth/)
|
||||
*
|
||||
* @param $var
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function __get($var)
|
||||
{
|
||||
return get_instance()->$var;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,348 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
require_once 'vendor/autoload.php';
|
||||
|
||||
# Imports the Google Cloud client library
|
||||
use Google\Cloud\Storage\StorageClient;
|
||||
|
||||
class GoogleStorage {
|
||||
|
||||
private $storage;
|
||||
private $projectId;
|
||||
private $authFile;
|
||||
public $prefix = 'adminsavvy';
|
||||
|
||||
public function __construct() {
|
||||
}
|
||||
|
||||
public function Init($projectId, $authFile) {
|
||||
// Your Google Cloud Platform project ID
|
||||
$this->projectId = $projectId; // 'float-app-224118';
|
||||
// The file path to credentials JSON
|
||||
$this->authFile = $authFile; // './float-app-224118-52ef1783d2c5.json';
|
||||
// Instantiates a client
|
||||
$this->storage = new StorageClient([
|
||||
'projectId' => $projectId,
|
||||
'keyFile' => json_decode(file_get_contents($authFile), true)
|
||||
]);
|
||||
}
|
||||
/*
|
||||
* @type array $keyFile The contents of the service account credentials
|
||||
* .json file retrieved from the Google Developer's Console.
|
||||
* Ex: `json_decode(file_get_contents($path), true)`.
|
||||
* @type string $keyFilePath The full path to your service account
|
||||
* credentials .json file retrieved from the Google Developers
|
||||
* Console.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Create a Cloud Storage Bucket.
|
||||
*
|
||||
* @param Google\Cloud\Storage\StorageClient $storage Google storage service client
|
||||
* @param string $bucketName name of the bucket to create.
|
||||
* @param string $options options for the new bucket.
|
||||
*
|
||||
* @return Google\Cloud\Storage\Bucket the newly created bucket.
|
||||
*/
|
||||
public function CreateBucket($bucketName) {
|
||||
// Creates the new bucket
|
||||
$bucket = $this->storage->createBucket($bucketName);
|
||||
//echo 'Bucket ' . $bucket->name() . ' created.';
|
||||
return $bucket;
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete a Cloud Storage Bucket.
|
||||
*
|
||||
* @param Google\Cloud\Storage\StorageClient $storage Google storage service client
|
||||
* @param string $bucketName the name of the bucket to delete.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
function DeleteBucket($bucketName)
|
||||
{
|
||||
$this->storage = new StorageClient();
|
||||
$bucket = $this->storage->bucket($bucketName);
|
||||
$bucket->delete();
|
||||
printf('Bucket deleted: %s' . PHP_EOL, $bucket->name());
|
||||
}
|
||||
|
||||
/**
|
||||
* Upload a file.
|
||||
*
|
||||
* @param Google\Cloud\Storage\StorageClient $storage Google storage service client
|
||||
* @param string $bucketName the name of your Google Cloud bucket.
|
||||
* @param string $objectName the name of the object.
|
||||
* @param string $source the path to the file to upload.
|
||||
*
|
||||
* @return Psr\Http\Message\StreamInterface
|
||||
*/
|
||||
function UploadObject($bucketName, $objectName, $source)
|
||||
{
|
||||
$file = fopen($source, 'r');
|
||||
$bucket = $this->storage->bucket($bucketName);
|
||||
$object = $bucket->upload($file, [
|
||||
'name' => $objectName
|
||||
]);
|
||||
printf('Uploaded %s to gs://%s/%s' . PHP_EOL, basename($source), $bucketName, $objectName);
|
||||
return $object;
|
||||
}
|
||||
|
||||
/**
|
||||
* Download an object from Cloud Storage and return it as a BLOB.
|
||||
*
|
||||
* @param Google\Cloud\Storage\StorageClient $storage Google storage service client
|
||||
* @param string $bucketName the name of your Google Cloud bucket.
|
||||
* @param string $objectName the name of your Google Cloud object.
|
||||
*
|
||||
* @return BLOB
|
||||
*/
|
||||
function DownloadObject($bucketName, $objectName)
|
||||
{
|
||||
$bucket = $this->storage->bucket($bucketName);
|
||||
$object = $bucket->object($objectName);
|
||||
$stream = $object->downloadAsStream();
|
||||
return $stream->getContents();
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete an object.
|
||||
*
|
||||
* @param Google\Cloud\Storage\StorageClient $storage Google storage service client
|
||||
* @param string $bucketName the name of your Cloud Storage bucket.
|
||||
* @param string $objectName the name of your Cloud Storage object.
|
||||
* @param array $options
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
function DeleteObject($bucketName, $objectName, $options = [])
|
||||
{
|
||||
$bucket = $this->storage->bucket($bucketName);
|
||||
$object = $bucket->object($objectName);
|
||||
$object->delete();
|
||||
printf('Deleted gs://%s/%s' . PHP_EOL, $bucketName, $objectName);
|
||||
}
|
||||
|
||||
/**
|
||||
* Make an object publically accessible.
|
||||
*
|
||||
* @param Google\Cloud\Storage\StorageClient $storage Google storage service client
|
||||
* @param string $bucketName the name of your Cloud Storage bucket.
|
||||
* @param string $objectName the name of your Cloud Storage object.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
function MakePublic($bucketName, $objectName)
|
||||
{
|
||||
$bucket = $this->storage->bucket($bucketName);
|
||||
$object = $bucket->object($objectName);
|
||||
$object->update(['acl' => []], ['predefinedAcl' => 'PUBLICREAD']);
|
||||
printf('gs://%s/%s is now public' . PHP_EOL, $bucketName, $objectName);
|
||||
}
|
||||
|
||||
/**
|
||||
* List object metadata.
|
||||
*
|
||||
* @param Google\Cloud\Storage\StorageClient $storage Google storage service client
|
||||
* @param string $bucketName the name of your Cloud Storage bucket.
|
||||
* @param string $objectName the name of your Cloud Storage object.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
function ObjectMetadata($bucketName, $objectName)
|
||||
{
|
||||
$bucket = $this->storage->bucket($bucketName);
|
||||
$object = $bucket->object($objectName);
|
||||
$info = $object->info();
|
||||
printf('Blob: %s' . PHP_EOL, $info['name']);
|
||||
printf('Bucket: %s' . PHP_EOL, $info['bucket']);
|
||||
printf('Storage class: %s' . PHP_EOL, $info['storageClass']);
|
||||
printf('ID: %s' . PHP_EOL, $info['id']);
|
||||
printf('Size: %s' . PHP_EOL, $info['size']);
|
||||
printf('Updated: %s' . PHP_EOL, $info['updated']);
|
||||
printf('Generation: %s' . PHP_EOL, $info['generation']);
|
||||
printf('Metageneration: %s' . PHP_EOL, $info['metageneration']);
|
||||
printf('Etag: %s' . PHP_EOL, $info['etag']);
|
||||
printf('Crc32c: %s' . PHP_EOL, $info['crc32c']);
|
||||
printf('MD5 Hash: %s' . PHP_EOL, $info['md5Hash']);
|
||||
printf('Content-type: %s' . PHP_EOL, $info['contentType']);
|
||||
printf("Temporary hold: " . (isset($info['temporaryHold']) ? "enabled" : "disabled") . PHP_EOL);
|
||||
printf("Event-based hold: " . (isset($info['eventBasedHold']) ? "enabled" : "disabled") . PHP_EOL);
|
||||
if (isset($info['retentionExpirationTime'])) {
|
||||
printf("retentionExpirationTime: " . $info['retentionExpirationTime'] . PHP_EOL);
|
||||
}
|
||||
if (isset($info['metadata'])) {
|
||||
printf('Metadata: %s', print_r($info['metadata'], true));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* List all Cloud Storage buckets for the current project.
|
||||
*
|
||||
* @param Google\Cloud\Storage\StorageClient $storage Google storage service client
|
||||
* @return void
|
||||
*/
|
||||
function ListBuckets()
|
||||
{
|
||||
$buckets = array();
|
||||
foreach ($this->storage->buckets() as $bucket) {
|
||||
//printf('Bucket: %s' . PHP_EOL, $bucket->name());
|
||||
$buckets[$bucket->name()] = $bucket;
|
||||
}
|
||||
return $buckets;
|
||||
}
|
||||
|
||||
/**
|
||||
* List Cloud Storage bucket objects.
|
||||
* https://cloud.google.com/storage/docs/listing-objects
|
||||
*
|
||||
* @param Google\Cloud\Storage\StorageClient $storage Google storage service client
|
||||
* @param string $bucketName the name of your Cloud Storage bucket.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
function ListObjects($bucketName)
|
||||
{
|
||||
$objects = array();
|
||||
$bucket = $this->storage->bucket($bucketName);
|
||||
foreach ($bucket->objects() as $object) {
|
||||
//printf('Object: %s' . PHP_EOL, $object->name());
|
||||
$objects[$object->name()] = $object;
|
||||
}
|
||||
return $objects;
|
||||
}
|
||||
|
||||
/**
|
||||
* List Cloud Storage bucket objects.
|
||||
* https://cloud.google.com/storage/docs/listing-objects
|
||||
*
|
||||
* @param Google\Cloud\Storage\StorageClient $storage Google storage service client
|
||||
* @param string $bucketName the name of your Cloud Storage bucket.
|
||||
* @param string $objectName the name of your Cloud Storage object.
|
||||
* @param string $responseType Response content-type for the object URL
|
||||
* @param integer $duration Number of seconds before the signature expires
|
||||
* @param string $method Optional HTTP verb for URL
|
||||
*
|
||||
* @return string Signed google storage URL
|
||||
*/
|
||||
function SignedUrl($bucketName, $objectName, $responseType, $duration = 60, $method = 'GET')
|
||||
{
|
||||
$bucket = $this->storage->bucket($bucketName);
|
||||
$object = $bucket->object($objectName);
|
||||
$url = $object->signedUrl(
|
||||
new \DateTime('+ ' . $duration . ' seconds'),
|
||||
array(
|
||||
'method' => $method,
|
||||
'responseType' => $responseType,
|
||||
'allowPost' => $method=='POST'
|
||||
));
|
||||
return $url;
|
||||
}
|
||||
/*
|
||||
'method' => 'GET',
|
||||
'cname' => self::DEFAULT_DOWNLOAD_URL,
|
||||
'contentMd5' => null,
|
||||
'contentType' => null,
|
||||
'headers' => [],
|
||||
'saveAsName' => null,
|
||||
'responseDisposition' => null,
|
||||
'responseType' => null,
|
||||
'keyFile' => null,
|
||||
'keyFilePath' => null,
|
||||
'allowPost' => false,
|
||||
'forceOpenssl' => false
|
||||
*/
|
||||
private function BaseEncode($num, $alphabet) {
|
||||
$base_count = strlen($alphabet);
|
||||
$encoded = '';
|
||||
while ($num >= $base_count) {
|
||||
$div = $num/$base_count;
|
||||
$mod = ($num-($base_count*intval($div)));
|
||||
$encoded = $alphabet[$mod] . $encoded;
|
||||
$num = intval($div);
|
||||
}
|
||||
if ($num) $encoded = $alphabet[$num] . $encoded;
|
||||
return $encoded;
|
||||
}
|
||||
|
||||
private function BaseDecode($num, $alphabet) {
|
||||
$decoded = 0;
|
||||
$multi = 1;
|
||||
while (strlen($num) > 0) {
|
||||
$digit = $num[strlen($num)-1];
|
||||
$decoded += $multi * strpos($alphabet, $digit);
|
||||
$multi = $multi * strlen($alphabet);
|
||||
$num = substr($num, 0, -1);
|
||||
}
|
||||
return $decoded;
|
||||
}
|
||||
|
||||
public function UniqueId() {
|
||||
// 123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ
|
||||
$alphabet = "pRFsNvKifkJtA5Umy9QSD8PTYcZH23dCeWg6aqVXwnr7jxuGMLhE4zBob1";
|
||||
return $this->BaseEncode(
|
||||
filter_var(microtime(),FILTER_SANITIZE_NUMBER_INT),
|
||||
$alphabet);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
//*
|
||||
// run with GOOGLE_STORAGE_TEST=1 php -f GoogleStorage.php
|
||||
if (isset($_SERVER['GOOGLE_STORAGE_TEST']) && $_SERVER['GOOGLE_STORAGE_TEST']==1) {
|
||||
// Create bucket 'adminsavvy-card-images' and list buckets
|
||||
//TestGoogleStorage(1,1,0,0,0,0,0,0);
|
||||
// Upload 'singapore.jpg' file to 'adminsavvy-card-images' bucket and make the object public
|
||||
//TestGoogleStorage(0,0,1,1,0,0,0,0);
|
||||
// Download 'singapore.jpg' object from 'adminsavvy-card-images' bucket
|
||||
//TestGoogleStorage(0,0,0,0,0,0,1,0);
|
||||
// List buckets, List objects in 'adminsavvy-card-images' bucket, get 'singapore.jpg' object metadata, get signed URL
|
||||
TestGoogleStorage(0,1,0,0,1,1,0,1);
|
||||
}
|
||||
//*/
|
||||
/*
|
||||
* Run the test suite for above defined function
|
||||
*
|
||||
* @param integer $testCreateBucket 1 to run the create bucket test
|
||||
* @param integer $testListBuckets 1 to run the list buckets test
|
||||
* @param integer $testUploadObject 1 to run the upload object test
|
||||
* @param integer $testMakePublic 1 to run the make public test
|
||||
* @param integer $testListObjects 1 to run the list objects test
|
||||
* @param integer $testObjectMetadata 1 to run the object metadata test
|
||||
* @param integer $testDownloadObject 1 to run the download object test
|
||||
* @param integer $testSignedUrl 1 to run the signed URL test
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
function TestGoogleStorage(
|
||||
$testCreateBucket,
|
||||
$testListBuckets,
|
||||
$testUploadObject,
|
||||
$testMakePublic,
|
||||
$testListObjects,
|
||||
$testObjectMetadata,
|
||||
$testDownloadObject,
|
||||
$testSignedUrl) {
|
||||
// Your Google Cloud Platform project ID
|
||||
$projectId = 'float-app-224118';
|
||||
// The name for the new bucket
|
||||
$bucketName = 'adminsavvy-card-images';
|
||||
// The file path to upload
|
||||
$filePath = '/home/savvy/savvy/savvyoauth2/public/test/singapore.jpg';
|
||||
// The file path to credentials JSON
|
||||
$authFile = '/home/savvy/savvy/savvyoauth2/public/include/float-app-224118-52ef1783d2c5.json';
|
||||
|
||||
// Instantiates a client
|
||||
$storage = new GoogleStorage($projectId, $authFile);
|
||||
|
||||
if ($testCreateBucket) var_dump($storage->CreateBucket($bucketName));
|
||||
if ($testListBuckets) $storage->ListBuckets();
|
||||
if ($testUploadObject) var_dump($storage->UploadObject($bucketName, basename($filePath), $filePath));
|
||||
if ($testMakePublic) $storage->MakePublic($bucketName, basename($filePath));
|
||||
if ($testListObjects) $storage->ListObjects($bucketName);
|
||||
if ($testObjectMetadata) $storage->ObjectMetadata($bucketName, basename($filePath));
|
||||
if ($testDownloadObject) file_put_contents('test.jpg',$storage->DownloadObject($bucketName, basename($filePath)));
|
||||
if ($testSignedUrl) var_dump($storage->SignedUrl($bucketName, basename($filePath), mime_content_type($filePath), 864000));
|
||||
}
|
||||
@@ -0,0 +1,217 @@
|
||||
<?php if (! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
/**
|
||||
* Name: Facebook Login Library
|
||||
*
|
||||
* Author: appleboy
|
||||
*
|
||||
*/
|
||||
require 'vendor/autoload.php';
|
||||
//require_once 'vendor/facebook/php-sdk-v4/src/Facebook/autoload.php';
|
||||
use Facebook\Facebook;
|
||||
use Facebook\FacebookRequestException;
|
||||
use Facebook\FacebookRedirectLoginHelper;
|
||||
class Lib_login
|
||||
{
|
||||
/**
|
||||
* CodeIgniter global
|
||||
*
|
||||
* @var string
|
||||
**/
|
||||
protected $ci;
|
||||
/**
|
||||
* @var FB
|
||||
*/
|
||||
private $fb;
|
||||
|
||||
private $helper;
|
||||
private $facebook_default_scope;
|
||||
private $facebook_login_url;
|
||||
private $facebook_logout_url;
|
||||
|
||||
/**
|
||||
* __construct
|
||||
*
|
||||
* @return void
|
||||
* @author Ben
|
||||
**/
|
||||
public function __construct()
|
||||
{
|
||||
if (!session_id()) {
|
||||
session_start();
|
||||
}
|
||||
$this->ci =& get_instance();
|
||||
$this->ci->load->library('session');
|
||||
$this->ci->config->load('facebook');
|
||||
$this->ci->load->helper('url');
|
||||
if (! isset($_SESSION)) {
|
||||
session_start();
|
||||
}
|
||||
$this->facebook_default_scope = explode(',', $this->ci->config->item("facebook_default_scope"));
|
||||
$facebook_app_id = $this->ci->config->item("facebook_app_id");
|
||||
$facebook_app_secret = $this->ci->config->item("facebook_app_secret");
|
||||
$this->facebook_login_url = base_url() . $this->ci->config->item("facebook_login_redirect_url").'/';
|
||||
$this->facebook_logout_url = base_url() . $this->ci->config->item("facebook_logout_redirect_url").'/';
|
||||
// init app with app id and secret
|
||||
$this->fb = new Facebook([
|
||||
'app_id' => $facebook_app_id, // Replace {app-id} with your app id
|
||||
'app_secret' => $facebook_app_secret,
|
||||
'default_graph_version' => 'v2.2',
|
||||
]);
|
||||
$this->helper = $this->fb->getRedirectLoginHelper();
|
||||
}
|
||||
|
||||
/**
|
||||
* @return FB
|
||||
*/
|
||||
public function object()
|
||||
{
|
||||
return $this->fb;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if user are logged in by checking if we have a Facebook
|
||||
* session active.
|
||||
*
|
||||
* @return mixed|boolean
|
||||
*/
|
||||
public function is_authenticated()
|
||||
{
|
||||
$access_token = $this->authenticate();
|
||||
if (isset($access_token))
|
||||
{
|
||||
return $access_token;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Destroy our local Facebook session
|
||||
*/
|
||||
public function destroy_session()
|
||||
{
|
||||
$this->session->unset_userdata('fb_access_token');
|
||||
}
|
||||
|
||||
public function getLoginUrl() {
|
||||
return $this->helper->getLoginUrl($this->facebook_login_url, $this->facebook_default_scope);
|
||||
}
|
||||
|
||||
public function getLogoutUrl() {
|
||||
return $this->helper->getLogoutUrl($this->get_access_token(), $this->facebook_logout_url);
|
||||
}
|
||||
|
||||
public function get_access_token() {
|
||||
return $this->session->userdata('fb_access_token');
|
||||
}
|
||||
|
||||
/**
|
||||
* @return mixed
|
||||
*/
|
||||
private function get_expire_time()
|
||||
{
|
||||
return $this->session->userdata('fb_expire');
|
||||
}
|
||||
/**
|
||||
* @param DateTime $time
|
||||
*/
|
||||
private function set_expire_time(DateTime $time = null)
|
||||
{
|
||||
if ($time) {
|
||||
$this->session->set_userdata('fb_expire', $time->getTimestamp());
|
||||
}
|
||||
}
|
||||
|
||||
public function authenticate()
|
||||
{
|
||||
$accessToken = $this->get_access_token();
|
||||
if ($accessToken && $this->get_expire_time() > (time() + 30) || $accessToken && !$this->get_expire_time())
|
||||
{
|
||||
$this->fb->setDefaultAccessToken($accessToken);
|
||||
return $accessToken;
|
||||
}
|
||||
// If we did not have a stored access token or if it has expired, try get a new access token
|
||||
try {
|
||||
$accessToken = $this->helper->getAccessToken($this->facebook_login_url);
|
||||
} catch(Facebook\Exceptions\FacebookResponseException $e) {
|
||||
// When Graph returns an error
|
||||
return $this->constructResult(NULL, 'Graph returned an error: ' . $e->getMessage());
|
||||
} catch(Facebook\Exceptions\FacebookSDKException $e) {
|
||||
// When validation fails or other local issues
|
||||
return $this->constructResult(NULL, 'Facebook SDK returned an error: ' . $e->getMessage());
|
||||
}
|
||||
|
||||
if (! isset($accessToken)) {
|
||||
if ($this->helper->getError()) {
|
||||
/*header('HTTP/1.0 401 Unauthorized');
|
||||
echo "Error: " . $helper->getError() . "\n";
|
||||
echo "Error Code: " . $helper->getErrorCode() . "\n";
|
||||
echo "Error Reason: " . $helper->getErrorReason() . "\n";
|
||||
echo "Error Description: " . $helper->getErrorDescription() . "\n";
|
||||
*/
|
||||
return $this->constructResult(NULL, 'Unauthorized: '.$this->helper->getErrorDescription());
|
||||
} else {
|
||||
return $this->constructResult(NULL, 'Bad request');
|
||||
}
|
||||
}
|
||||
// The OAuth 2.0 client handler helps us manage access tokens
|
||||
$oAuth2Client = $this->fb->getOAuth2Client();
|
||||
// Get the access token metadata from /debug_token
|
||||
///$tokenMetadata = $oAuth2Client->debugToken($accessToken);
|
||||
|
||||
if (! $accessToken->isLongLived()) {
|
||||
// Exchanges a short-lived access token for a long-lived one
|
||||
try {
|
||||
$accessToken = $oAuth2Client->getLongLivedAccessToken($accessToken);
|
||||
$this->set_expire_time($accessToken->getExpiresAt());
|
||||
$this->set_access_token($accessToken);
|
||||
$this->fb->setDefaultAccessToken($accessToken);
|
||||
} catch (Facebook\Exceptions\FacebookSDKException $e) {
|
||||
return $this->constructResult(NULL, "<p>Error getting long-lived access token: " . $this->helper->getMessage() . "</p>\n\n");
|
||||
}
|
||||
//var_dump($accessToken->getValue());
|
||||
}
|
||||
$_SESSION['fb_access_token'] = (string) $accessToken;
|
||||
|
||||
return $accessToken;
|
||||
}
|
||||
|
||||
public function getData($accessToken) {
|
||||
$user = NULL;
|
||||
try {
|
||||
// Returns a `Facebook\FacebookResponse` object
|
||||
if ($accessToken!="") {
|
||||
$response = $this->fb->get('/me?fields=id,name,email', $accessToken);
|
||||
$user = $response->getGraphUser();
|
||||
}
|
||||
} catch(Facebook\Exceptions\FacebookResponseException $e) {
|
||||
return $this->constructResult(NULL,'Graph returned an error: ' . $e->getMessage());
|
||||
} catch(Facebook\Exceptions\FacebookSDKException $e) {
|
||||
return $this->constructResult(NULL,'Facebook SDK returned an error: ' . $e->getMessage());
|
||||
}
|
||||
return $this->constructResult($user, NULL);
|
||||
}
|
||||
|
||||
private function constructResult($me,$error) {
|
||||
$fb_data = array(
|
||||
'me' => $me,
|
||||
'error' => $error
|
||||
);
|
||||
$this->ci->session->set_userdata('fb_data', $fb_data);
|
||||
return $fb_data;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enables the use of CI super-global without having to define an extra variable.
|
||||
* I can't remember where I first saw this, so thank you if you are the original author.
|
||||
*
|
||||
* Borrowed from the Ion Auth library (http://benedmunds.com/ion_auth/)
|
||||
*
|
||||
* @param $var
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function __get($var)
|
||||
{
|
||||
return get_instance()->$var;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
class Mobile_Controller extends WRB_Controller {
|
||||
|
||||
public $data = array();
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
|
||||
|
||||
//$this->renderMobileExtPage('mobile_index', $data);
|
||||
$this->load->model('mobile_model');
|
||||
|
||||
// $phoneH = $this->mobile_model->getMobileHeaders();
|
||||
$imb = $this->mobile_model->isMobile();
|
||||
//echo "hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh=". $imb;
|
||||
$mob_strict = true;
|
||||
|
||||
if ($mob_strict == true) {
|
||||
if ($imb !=1) {
|
||||
// redirect('/');
|
||||
} else {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,87 @@
|
||||
<?php
|
||||
|
||||
class Users_Controller extends WRB_Controller {
|
||||
|
||||
|
||||
public $data = array();
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
|
||||
// you dont have bussines here if you are not in session
|
||||
if (!isset($_SESSION['session_id']) or ! isset($_SESSION['username']) or $_SESSION['username'] == '') {
|
||||
redirect(home);
|
||||
}
|
||||
|
||||
$out = array();
|
||||
$in = array();
|
||||
$this->load->model('backend_model');
|
||||
$in["action"] = WRENCHBOARD_SESSION_VERIFY;
|
||||
$in['sessionid'] = $_SESSION['session_id'];
|
||||
$in['member_id'] = $_SESSION['member_id'];
|
||||
$res = $this->backend_model->wrenchboard_api($in, $out);
|
||||
if ($res != PHP_API_OK) {
|
||||
redirect(home);
|
||||
}
|
||||
$this->data = $this->getSessionArray();
|
||||
}
|
||||
|
||||
public function getSessionArray() {
|
||||
$data["current_date"] = date('l jS \of F Y h:i:s A');
|
||||
$data['username'] = $_SESSION['username']; // = $this->input->post('username');
|
||||
$data['name'] = $_SESSION['name']; // = $this->input->post('username');
|
||||
$data['firstname'] = $_SESSION['firstname']; // = $ret->firstname;
|
||||
$data['lastname'] = $_SESSION['lastname']; // = $ret->lastname;
|
||||
$data['email'] = $_SESSION['email']; // = $ret->email;
|
||||
$data['member_id'] = $_SESSION['member_id'];
|
||||
|
||||
$this->load->model('dash_model');
|
||||
$out = $this->dash_model->getDashData($data);
|
||||
$data['active_task'] = $out['active_task'];
|
||||
$data['active_pass_due'] = $out['active_pass_due'];
|
||||
$data['current_balance'] = $out['current_balance'];
|
||||
$data['new_message'] = $out['new_message'];
|
||||
$data['escrow_balance'] = $out['escrow_balance'];
|
||||
$data['description'] = $out["description"];
|
||||
|
||||
//$data = $_SESSION['secure_data'];
|
||||
$data['member_id'] = $_SESSION['member_id']; // = $ret->email;
|
||||
$_SESSION["active_offers_count"] = $out['active_offers_count'];
|
||||
$_SESSION["offers_interest_count"] = $out["offers_interest_count"];
|
||||
$_SESSION['new_message'] = $out["new_message"];
|
||||
|
||||
$this->refreshAccountDetail($_SESSION['member_id']);
|
||||
return $data;
|
||||
}
|
||||
|
||||
private function refreshAccountDetail($member_id) {
|
||||
$this->load->model('account_model');
|
||||
$qr = $this->account_model->loadAccountData($member_id);
|
||||
// print_r($qr);
|
||||
$_SESSION['current_balance'] = $qr[0]['balance'];
|
||||
$_SESSION['active_task'] = $this->account_model->loadActiveTaskCount($member_id);
|
||||
$_SESSION['state'] = $qr[0]['state'];
|
||||
$_SESSION['city'] = $qr[0]['city'];
|
||||
$_SESSION['country'] = $qr[0]['country'];
|
||||
$_SESSION['post_jobs'] = $qr[0]['post_jobs'];
|
||||
$_SESSION['refer'] = $qr[0]['refer'];
|
||||
|
||||
$in = array();
|
||||
$in['action'] = WRENCHBOARD_SESSION_VERIFY;
|
||||
$in['sessionid'] = $_SESSION['session_id'];
|
||||
$in['member_id'] = $_SESSION['member_id'];
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($in, $out);
|
||||
if ($res != PHP_API_OK) {
|
||||
redirect(home);
|
||||
}
|
||||
}
|
||||
|
||||
protected function RenderUserPage($page_name, $data) {
|
||||
$this->load->view('users/view_header_user', $data);
|
||||
$this->load->view($page_name, $data);
|
||||
$this->load->view('users/view_footer_user', $data);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,101 @@
|
||||
<?php
|
||||
|
||||
class Account_model extends CI_Model {
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function verify_link($data) {
|
||||
$q = $this
|
||||
->db
|
||||
->where('verify_link', $data['vlink'])
|
||||
->limit(1)
|
||||
->get('members_pending');
|
||||
|
||||
|
||||
// print_r($q->row());
|
||||
//echo "--AAA--" . $q->num_rows();
|
||||
|
||||
if ($q->num_rows() > 0) {
|
||||
// echo '<pre>';
|
||||
// print_r($q->row());
|
||||
// echo '</pre>';
|
||||
return $q->row();
|
||||
} else {
|
||||
|
||||
//echo '<pre>';
|
||||
// echo "No rows " . $this->db->last_query();
|
||||
//print_r($data);
|
||||
//echo '</pre>';
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public function verifySignupInputs($data) {
|
||||
$ret = false;
|
||||
if (trim($data['firstname']) != '' && trim($data['lastname']) != '' && trim($data['email']) != '' && trim($data['username']) != '' && trim($data['password']) != '' && trim($data['country']) != '' && isset($data['terms']) && $data['terms'] == 'on') {
|
||||
$ret = true;
|
||||
}
|
||||
return $ret;
|
||||
}
|
||||
|
||||
public function checkUsernameDuplicate($data) {
|
||||
$q = $this
|
||||
->db
|
||||
->where('username', $data['username'])
|
||||
->limit(1)
|
||||
->get('members');
|
||||
|
||||
$q2 = $this
|
||||
->db
|
||||
->where('username', $data['username'])
|
||||
->limit(10)
|
||||
->get('members_pending');
|
||||
|
||||
return $q->num_rows() + $q2->num_rows();
|
||||
}
|
||||
|
||||
public function username_data($data) {
|
||||
$q = $this
|
||||
->db
|
||||
->where('username', $data['username'])
|
||||
->limit(1)
|
||||
->get('members');
|
||||
|
||||
if ($q->num_rows() > 0) {
|
||||
return $q->row();
|
||||
} else {
|
||||
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public function loadAccountData($member_id) {
|
||||
$q = $this
|
||||
->db
|
||||
->where('id', $member_id)
|
||||
->limit(1)
|
||||
->get('members');
|
||||
|
||||
if ($q->num_rows() > 0) {
|
||||
// return $q->row();
|
||||
return $q->result_array();
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public function loadActiveTaskCount($member_id) {
|
||||
$num = 0;
|
||||
$mysql = "SELECT id FROM members_jobs_contract WHERE client_id = $member_id AND status IN (1,2) "
|
||||
. "UNION "
|
||||
. "SELECT id FROM members_jobs_contract WHERE member_id = $member_id AND status IN (1,2) ";
|
||||
|
||||
$query = $this->db->query($mysql);
|
||||
$num = $query->num_rows();
|
||||
return $num;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
<?php
|
||||
|
||||
class Backend_model extends CI_Model {
|
||||
|
||||
var $thisUser = 'oameye';
|
||||
var $USER = '';
|
||||
var $wrenchboard;
|
||||
|
||||
function __construct() {
|
||||
|
||||
$this->USER = $_SERVER['SCRIPT_FILENAME'];
|
||||
$this->USER = str_replace('/home', '', $this->USER);
|
||||
$this->USER = strtok($this->USER, '/');
|
||||
if ($this->USER == 'opt') {
|
||||
$this->USER = 'root';
|
||||
}
|
||||
$this->thisUser = $this->USER;
|
||||
}
|
||||
|
||||
public function wrenchboard_api($in, $out = array()) {
|
||||
$this->wrenchboard_load();
|
||||
$ret = $this->wrenchboard->wrenchboard_api($in, $out);
|
||||
return $ret;
|
||||
}
|
||||
|
||||
public function cfgReadChar($str) {
|
||||
$this->wrenchboard_load();
|
||||
$ret = $this->wrenchboard->cfgReadChar($str);
|
||||
return $ret;
|
||||
}
|
||||
|
||||
private function wrenchboard_load() {
|
||||
// $this->$USER = $_SERVER['SCRIPT_FILENAME'];
|
||||
$wrenchboard_class = 'wrenchboard_api_' . $this->USER . '\\WrenchBoard';
|
||||
if (!is_object($this->wrenchboard)) {
|
||||
$this->wrenchboard = new $wrenchboard_class();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,159 @@
|
||||
<?php
|
||||
|
||||
class Combo_model extends CI_Model {
|
||||
|
||||
var $optCons = '';
|
||||
var $currentStyle = 'form-control select';
|
||||
var $readOnlyMode = false;
|
||||
var $defaultComboMessage = 'Select...';
|
||||
var $showDefaultSelect = true;
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function getJobPostDuration($option_name, $duration)
|
||||
{
|
||||
$this->defaultComboMessage ='Select duration of post';
|
||||
$cmbstr ="";
|
||||
for ($ii = 2; $ii <= 10; $ii++) {
|
||||
|
||||
$cmbstr .= "<option value='$ii'>$ii day(s)</option>";
|
||||
}
|
||||
|
||||
for ($ii = 2; $ii <= 5; $ii++) {
|
||||
$days_c = $ii*7;
|
||||
$cmbstr .= "<option value='$days_c'>$ii Weeks</option>";
|
||||
}
|
||||
return $this->comboFrame($option_name, $cmbstr);
|
||||
}
|
||||
public function getUserJobGroupCombo($option_name, $member_id, $curVal) {
|
||||
|
||||
// $sql = "SELECT id,group_name FROM members_job_group WHERE member_id = $member_id AND status = 1 ORDER BY group_name ASC ";
|
||||
$sql = "SELECT m.id,m.group_name, m.group_name||' ['||count(g.group_id)||' members]' AS member_group_count "
|
||||
. "FROM members_job_group m "
|
||||
. "LEFT JOIN members_job_groupmember g ON g.group_id = m.id "
|
||||
. "WHERE m.member_id = $member_id "
|
||||
. "AND m.status = 1 GROUP BY m.id,m.group_name ORDER BY m.group_name ASC";
|
||||
|
||||
$q = $this->db->query($sql);
|
||||
$option_value = $this->optionValueObject($q->result(), "id", "member_group_count", $curVal);
|
||||
return $this->comboFrame($option_name, $option_value);
|
||||
}
|
||||
|
||||
public function getUserRecipientCombo($option_name, $member_id, $curVal) {
|
||||
|
||||
$sql = "SELECT b.id,b.firstname||' '||b.lastname||' '||b.account_no||' '||k.name AS recipient "
|
||||
. "FROM sendmoney_recipient b "
|
||||
. "LEFT JOIN bank_entity_codes k ON k.code=b.bank_code "
|
||||
. "WHERE b.member_id = $member_id AND b.status=1";
|
||||
|
||||
$q = $this->db->query($sql);
|
||||
$option_value = $this->optionValueObject($q->result(), "id", "recipient", $curVal);
|
||||
return $this->comboFrame($option_name, $option_value);
|
||||
}
|
||||
|
||||
public function getAccountTypeCombo($option_name, $curVal) {
|
||||
$q = $this
|
||||
->db
|
||||
->where('status', 1)
|
||||
->order_by('type_name', 'ASC')
|
||||
->get('account_types');
|
||||
|
||||
$option_value = $this->optionValueObject($q->result(), "type_value", "type_name", $curVal);
|
||||
|
||||
return $this->comboFrame($option_name, $option_value);
|
||||
}
|
||||
|
||||
public function getGeneralSkillCombo($option_name, $curVal) {
|
||||
$this->showDefaultSelect = false;
|
||||
$q = $this
|
||||
->db
|
||||
->where('status', 1)
|
||||
->order_by('lorder', 'DESC')
|
||||
->get('skill_category');
|
||||
$option_value = $this->optionValueObject($q->result(), "id", "category", $curVal);
|
||||
|
||||
return $this->comboFrame($option_name, $option_value);
|
||||
}
|
||||
|
||||
public function getUserNewSkillCombo($option_name, $curVal, $category_id, $member_id) {
|
||||
$q = $this
|
||||
->db
|
||||
->where('status', 1)
|
||||
->where('category_id', $category_id)
|
||||
->order_by('lorder', 'DESC')
|
||||
->get('skill_types');
|
||||
$option_value = $this->optionValueObject($q->result(), "id", "skill", $curVal);
|
||||
|
||||
return $this->comboFrame($option_name, $option_value);
|
||||
}
|
||||
|
||||
public function setReadOnly($bl) {
|
||||
$this->readOnlyMode = $bl;
|
||||
}
|
||||
|
||||
public function getCountryCombo($option_name, $curVal) {
|
||||
$q = $this
|
||||
->db
|
||||
->where('status', 1)
|
||||
->order_by('country', 'ASC')
|
||||
->get('country');
|
||||
|
||||
$option_value = $this->optionValueObject($q->result(), "code", "country", $curVal);
|
||||
|
||||
return $this->comboFrame($option_name, $option_value);
|
||||
}
|
||||
|
||||
public function getBankCombo($option_name, $curVal) {
|
||||
/*
|
||||
wrenchboard=> Select code,name from bank_entity_codes WHERE country ='NG' ORDER BY name ASC;
|
||||
code | name
|
||||
------+------------------------------------------------
|
||||
044 | Access Bank
|
||||
014 | Afri Bank
|
||||
023 | Citi Bank
|
||||
063 | Diamond Bank
|
||||
050 | Ecobank
|
||||
040 | Equitorial Trust Bank
|
||||
*/
|
||||
|
||||
$q = $this
|
||||
->db
|
||||
->where('status', 1)
|
||||
->order_by('name', 'ASC')
|
||||
->get('bank_entity_codes');
|
||||
|
||||
$option_value = $this->optionValueObject($q->result(), "code", "name", $curVal);
|
||||
|
||||
return $this->comboFrame($option_name, $option_value);
|
||||
}
|
||||
|
||||
|
||||
private function optionValueObject($sdStd, $val, $valname, $curVal) {
|
||||
$this->optCons = '';
|
||||
if ($this->showDefaultSelect == true) {
|
||||
$this->optCons .= "<option value=''>" . $this->defaultComboMessage . "</option>";
|
||||
}
|
||||
|
||||
|
||||
foreach ($sdStd as $row) {
|
||||
$selV = '';
|
||||
if ($curVal == $row->$val) {
|
||||
$selV = " selected ";
|
||||
}
|
||||
$this->optCons .= "<option value='" . $row->$val . "' " . $selV . ">" . $row->$valname . "</option>";
|
||||
}
|
||||
return $this->optCons;
|
||||
}
|
||||
|
||||
private function comboFrame($option_name, $option_value) {
|
||||
$addReaOnly = "";
|
||||
if ($this->readOnlyMode == true) {
|
||||
$addReaOnly = " disabled ";
|
||||
}
|
||||
|
||||
return $cmb = "<select data-placeholder='".$this->defaultComboMessage."' class='" . $this->currentStyle . "' name='$option_name' $addReaOnly >$option_value</select>";
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
class Contact_model extends CI_Model {
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function addContractMessage($data)
|
||||
{
|
||||
/*
|
||||
$in['title'] = $title;
|
||||
$in['description'] = $description;
|
||||
$in['timeline_days'] = $timeline;
|
||||
$in['job_detail'] = $job_detail;
|
||||
$in['price'] = $price;
|
||||
$in['member_id'] = $_SESSION['member_id'];
|
||||
*/
|
||||
$ret = false;
|
||||
if ( trim( $data['title']) !='' && trim($data['description']) !='' && trim($data['timeline_days']) !='' && trim($data['price']) !='' && trim($data['member_id']) > 0 )
|
||||
{
|
||||
$ret = true;
|
||||
}
|
||||
return $ret;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
|
||||
class Country_model extends CI_Model {
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function loadCountry($data) {
|
||||
$q = $this
|
||||
->db
|
||||
->where('status', $data['status'])
|
||||
->order_by('country', 'ASC')
|
||||
->get('country');
|
||||
|
||||
// $this->db->order_by('name', 'ASC');
|
||||
|
||||
return $q->result();
|
||||
}
|
||||
//$this->db->order_by('title', 'DESC');
|
||||
}
|
||||
@@ -0,0 +1,132 @@
|
||||
<?php
|
||||
|
||||
class Dash_model extends CI_Model {
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function getDashData($data) {
|
||||
$out = array();
|
||||
$out['active_task'] = 0;
|
||||
$out['active_pass_due'] = 0;
|
||||
|
||||
$out['current_balance'] = 0;
|
||||
$out['new_message'] = 0;
|
||||
$out['total_jobs'] = 0;
|
||||
|
||||
$q = $this
|
||||
->db
|
||||
->where('id', $data['member_id'])
|
||||
->limit(1)
|
||||
->get('members');
|
||||
|
||||
if ($q->num_rows() > 0) {
|
||||
$out = $q->result_array();
|
||||
|
||||
$out['current_balance'] = $out[0]['balance']; //pay attention to row 1
|
||||
$out['new_message'] = 0;
|
||||
$out['active_task'] = 0;
|
||||
$out['active_pass_due'] = 0;
|
||||
$out['total_jobs'] = 0;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
$y = $this->getNewMessageCount($data['member_id']);
|
||||
$out['new_message'] = $y['new_message'];
|
||||
|
||||
$y = $this->getEscrowBalance($data['member_id']);
|
||||
$out['escrow_balance'] = $y['escrow_balance'] + $y['escrow_c_offer'];
|
||||
|
||||
$y = $this->getPeningOfferCount($data['member_id']);
|
||||
$out['active_offers_count'] = $y['active_offers_count'];
|
||||
|
||||
$z = $this->getOfferInterestCount($data['member_id']);
|
||||
$out["offers_interest_count"] = $z['offers_interest_count'];
|
||||
|
||||
$k = $this->getAccountDetail($data['member_id']);
|
||||
$out["description"] = $k['description'];
|
||||
|
||||
|
||||
|
||||
return $out;
|
||||
}
|
||||
|
||||
public function getNewMessageCount($member_id) {
|
||||
$out = array();
|
||||
$out['new_message'] =0;
|
||||
$mysql = " SELECT count(id) AS new_message FROM members_messages WHERE member_id =$member_id AND reply IS NULL AND added > now() +'-2 day(s)' ";
|
||||
$q = $this->db->query($mysql);
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['new_message'] = $q->row()->new_message;
|
||||
}
|
||||
return $out;
|
||||
}
|
||||
|
||||
public function getEscrowBalance($member_id) {
|
||||
$out = array();
|
||||
$out['escrow_balance'] = $out['escrow_c_offer'] = 0;
|
||||
$mysql = "SELECT sum(jb.price) AS escrow_offer FROM members_jobs_offer j LEFT JOIN members_jobs jb ON jb.id=j.job_id WHERE j.status = 1 AND client_id> 0 AND j.member_id = " . $member_id;
|
||||
$q = $this->db->query($mysql);
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['escrow_balance'] = $q->row()->escrow_offer;
|
||||
}
|
||||
|
||||
$mysql = "SELECT sum(j.price) AS escrow_c_offer FROM members_jobs_contract j WHERE j.status IN(1,2) AND j.member_id = " . $member_id;
|
||||
$q2 = $this->db->query($mysql);
|
||||
if ($q2->num_rows() > 0) {
|
||||
$out['escrow_c_offer'] = $q2->row()->escrow_c_offer;
|
||||
}
|
||||
|
||||
|
||||
return $out; //['escrow_c_offer'] + $out['escrow_balance'];
|
||||
}
|
||||
|
||||
public function getAccountDetail($member_id) {
|
||||
$out['description'] = "";
|
||||
|
||||
$mysql = "SELECT * FROM members_detail WHERE member_id = " . $member_id;
|
||||
$q = $this->db->query($mysql);
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['description'] = $q->row()->description;
|
||||
}
|
||||
return $out;
|
||||
}
|
||||
|
||||
|
||||
public function getOfferInterestCount($member_id) {
|
||||
$out['active_offers_count'] = 0;
|
||||
$mysql = " SELECT count(mi.id) AS offers_interest_count"
|
||||
. " FROM members_offer_interest mi "
|
||||
. " LEFT JOIN members_jobs_offer jo ON jo.id=mi.offer_id "
|
||||
. " WHERE mi.status=1 AND jo.expire> now() "
|
||||
. " AND mi.member_id = " . $member_id;
|
||||
$q = $this->db->query($mysql);
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['offers_interest_count'] = $q->row()->offers_interest_count;
|
||||
}
|
||||
return $out;
|
||||
}
|
||||
|
||||
/*
|
||||
select * from members_offer_interest order by id desc;
|
||||
id | member_id | offer_id | status | added
|
||||
----+-----------+----------+--------+----------------------------
|
||||
56 | 18 | 71 | 1 | 2017-06-22 09:36:25.576627
|
||||
55 | 23 | 71 | 1 | 2017-06-22 09:36:08.856582
|
||||
|
||||
*/
|
||||
|
||||
public function getPeningOfferCount($member_id) {
|
||||
$out['active_offers_count'] = 0;
|
||||
$mysql = " SELECT count(id) AS active_offers_count FROM members_jobs_offer WHERE status=1 AND expire> now() AND member_id = " . $member_id;
|
||||
$q = $this->db->query($mysql);
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['active_offers_count'] = $q->row()->active_offers_count;
|
||||
}
|
||||
return $out;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
class Faq_model extends CI_Model {
|
||||
|
||||
var $optCons = '';
|
||||
var $currentStyle = 'form-control select';
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function attachOffers($email) {
|
||||
$emailTrim = trim($email);
|
||||
$mysql = "SELECT id AS member_id FROM members WHERE username = '$emailTrim' LIMIT 1 ";
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$num = $query->num_rows();
|
||||
if ($num == 1) {
|
||||
|
||||
// $out = $query->result_array();
|
||||
// print_r($out);
|
||||
$mysqlU = " UPDATE members_jobs_offer SET client_id ='". $query->row()->member_id ."' WHERE client_id = 0 AND email='$emailTrim' AND expire> now()";
|
||||
$this->db->query($mysqlU);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,198 @@
|
||||
<?php
|
||||
|
||||
class Job_model extends CI_Model {
|
||||
var $actionMessage = '';
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function deleteMemberGroup($group_id) {
|
||||
$this->actionMessage = '';
|
||||
$x['member_id'] = $_SESSION['member_id'];
|
||||
$x['group_id'] = $group_id;
|
||||
|
||||
$x['action'] = WRENCHBOARD_JOB_DELETE_GROUP;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($x, $out);
|
||||
if ($res == PHP_CREATED_OK) {
|
||||
$this->actionMessage = "Group Deleted";
|
||||
} else {
|
||||
$this->actionMessage = 'Unable to delete group...';
|
||||
}
|
||||
return $this->actionMessage;
|
||||
}
|
||||
|
||||
public function deleteMemberGroupMember($group_id, $group_member_id) {
|
||||
$this->actionMessage = '';
|
||||
$x['member_id'] = $_SESSION['member_id'];
|
||||
$x['group_id'] = $group_id;
|
||||
$x['group_member_id'] = $group_member_id;
|
||||
$x['action'] = WRENCHBOARD_JOB_DELETE_GROUPMEMBER;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($x, $out);
|
||||
if ($res == PHP_CREATED_OK) {
|
||||
$this->actionMessage = "Group Deleted";
|
||||
} else {
|
||||
$this->actionMessage = 'Unable to delete group...';
|
||||
}
|
||||
return $this->actionMessage;
|
||||
}
|
||||
|
||||
public function addMemberGroupMember($group_id, $firstname, $lastname, $email) {
|
||||
$this->actionMessage = '';
|
||||
//$group_id = $group_id + 0; // just making sure it is number
|
||||
|
||||
$x['member_id'] = $_SESSION['member_id'];
|
||||
$x['group_id'] = $group_id;
|
||||
$x['firstname'] = $firstname;
|
||||
$x['lastname'] = $lastname;
|
||||
$x['email'] = $email;
|
||||
|
||||
|
||||
$x['action'] = WRENCHBOARD_JOB_GROUP_MEMBER;
|
||||
$this->load->model('backend_model');
|
||||
$out = array();
|
||||
$res = $this->backend_model->wrenchboard_api($x, $out);
|
||||
if ($res == PHP_CREATED_OK) {
|
||||
$this->actionMessage = 'Group Created';
|
||||
} else {
|
||||
$this->actionMessage = 'Unable to create job group...';
|
||||
}
|
||||
return $this->actionMessage;
|
||||
}
|
||||
|
||||
var $tableJobMember = '';
|
||||
|
||||
public function getJobGroupMembers($group_id) {
|
||||
$this->tableJobMember = '';
|
||||
|
||||
$this->load->library('table');
|
||||
$this->table->set_template($this->template);
|
||||
$mysql = "SELECT firstname,lastname,email,'<button type=\"button\" class=\"btn btn-danger btn-sm btn-xs\" onclick=''deleteJobGroupMember('||id||',${group_id},\"'||firstname||' '||lastname||'\")''>X</button>' FROM members_job_groupmember WHERE member_id = " . $_SESSION['member_id'] . " AND group_id = " . $group_id . " AND status = 1";
|
||||
$query = $this->db->query($mysql);
|
||||
$this->table->set_heading('Firstname', 'Lastname', 'Email', '');
|
||||
$this->tableJobMember = $this->table->generate($query);
|
||||
return $this->tableJobMember;
|
||||
}
|
||||
|
||||
var $tableStr = '';
|
||||
|
||||
public function getMembersJobGroup($sel) {
|
||||
$this->tableStr = '';
|
||||
$groups = array();
|
||||
$mysql = "SELECT id,group_name FROM members_job_group WHERE member_id = " . $_SESSION['member_id'] . " AND status = 1 ORDER BY group_name ASC";
|
||||
$query = $this->db->query($mysql);
|
||||
$this->tableStr = '<table class=\'table table-striped table-hover table-bordered table-condensed\' style=\'border-spacing: 1px; padding: 0px; border-collapse: separate;\' >';
|
||||
$i = 0;
|
||||
foreach ($query->result() as $row) {
|
||||
$this->tableStr .="<tr><td style='width:10px;'><input type=\"radio\" name=\"unstyled-radio-left\" value=\"" . $row->id . "\" onchange=\"jobGroupChanged(this,'".str_replace("'","\\'",stripslashes($row->group_name))."')\"".(($sel==$row->id || ($sel<1 && $i==0))?"checked":"")."></td><td>" . $row->group_name . "</td><td><button class=\"btn btn-danger btn-sm btn-xs\" type=\"button\" onclick=\"deleteJobGroup(".$row->id.",'".str_replace("'","\\'",stripslashes($row->group_name))."')\">X</button></td></tr>";
|
||||
$groups[$row->id] = $row->group_name;
|
||||
$i++;
|
||||
}
|
||||
$this->tableStr .= '</table>';
|
||||
return array($this->tableStr,$groups);
|
||||
}
|
||||
|
||||
public function addGroupMemberForm($group_id) {
|
||||
|
||||
$str = "<form method='post' name='addgrpmem' action='?'>
|
||||
<input type='hidden' name='group_id' value='${group_id}'>
|
||||
<table class='table table-striped table-hover table-nobordered table-condensed'>
|
||||
<tr>
|
||||
<td><input type='text' class='form-control' name='firstname' placeholder='Firstname...'></td>
|
||||
<td><input type='text' class='form-control' name='lastname' placeholder='Lastname...'></td>
|
||||
<td><input type='text' class='form-control' name='email' placeholder='Email...'></td>
|
||||
<td><button type='submit' class='btn btn-primary btn-sm'>Add</button></td></tr>
|
||||
<tr>
|
||||
</table>
|
||||
</form>
|
||||
<hr size=1>";
|
||||
|
||||
return $str;
|
||||
}
|
||||
|
||||
public function loadJobOffer($member_id, $offer_code) {
|
||||
$out = array();
|
||||
$out['result'] = 0;
|
||||
$mysql = "SELECT jo.added::date AS added_date,j.title,j.description, j.timeline_days, j.price*0.01 AS price,jo.offer_code,jo.job_description,jo.expire "
|
||||
. "FROM members_jobs_offer jo LEFT JOIN members_jobs j ON j.id = jo.job_id "
|
||||
. "WHERE jo.expire > now() AND jo.status = 1 "
|
||||
. "AND jo.client_id = " . $member_id . " AND jo.offer_code='" . $offer_code . "' ";
|
||||
$q = $this->db->query($mysql);
|
||||
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['added_date'] = $q->row()->added_date;
|
||||
$out['title'] = $q->row()->title;
|
||||
$out['description'] = $q->row()->description;
|
||||
$out['timeline_days'] = $q->row()->timeline_days;
|
||||
$out['price'] = $q->row()->price;
|
||||
$out['offer_code'] = $q->row()->offer_code;
|
||||
$out['job_description'] = $q->row()->job_description;
|
||||
$out['expire'] = $q->row()->expire;
|
||||
$out['result'] = 1;
|
||||
} else {
|
||||
|
||||
}
|
||||
return $out;
|
||||
}
|
||||
|
||||
public function readMyloadJobOffer($member_id, $offer_code) {
|
||||
$out = array();
|
||||
$out['result'] = 0;
|
||||
$mysql = "SELECT jo.added::date AS added_date,j.title,j.description, j.timeline_days, j.price*0.01 AS price,jo.offer_code,jo.job_description,jo.expire,(CASE WHEN jo.public_view > 0 THEN 'Public View' ELSE jo.email END ) AS job_sent_to "
|
||||
. "FROM members_jobs_offer jo LEFT JOIN members_jobs j ON j.id = jo.job_id "
|
||||
. "WHERE jo.expire > now() AND jo.status = 1 "
|
||||
. "AND jo.member_id = " . $member_id . " AND jo.offer_code='" . $offer_code . "' ";
|
||||
$q = $this->db->query($mysql);
|
||||
|
||||
if ($q->num_rows() > 0) {
|
||||
$out['job_sent_to'] = $q->row()->job_sent_to;
|
||||
$out['added_date'] = $q->row()->added_date;
|
||||
$out['title'] = $q->row()->title;
|
||||
$out['description'] = $q->row()->description;
|
||||
$out['timeline_days'] = $q->row()->timeline_days;
|
||||
$out['price'] = $q->row()->price;
|
||||
$out['offer_code'] = $q->row()->offer_code;
|
||||
$out['job_description'] = $q->row()->job_description;
|
||||
$out['expire'] = $q->row()->expire;
|
||||
$out['result'] = 1;
|
||||
} else {
|
||||
|
||||
}
|
||||
return $out;
|
||||
}
|
||||
|
||||
public function verifyJobInputs($data) {
|
||||
/*
|
||||
$in['title'] = $title;
|
||||
$in['description'] = $description;
|
||||
$in['timeline_days'] = $timeline;
|
||||
$in['job_detail'] = $job_detail;
|
||||
$in['price'] = $price;
|
||||
$in['member_id'] = $_SESSION['member_id'];
|
||||
*/
|
||||
$ret = false;
|
||||
if (trim($data['title']) != '' && trim($data['description']) != '' && trim($data['timeline_days']) != '' && trim($data['price']) != '' && trim($data['member_id']) > 0) {
|
||||
$ret = true;
|
||||
}
|
||||
return $ret;
|
||||
}
|
||||
|
||||
public function getJob($job_id) {
|
||||
|
||||
$q = $this
|
||||
->db
|
||||
->where('id', $job_id)
|
||||
->limit(1)
|
||||
->get('members_jobs');
|
||||
|
||||
if ($q->num_rows() > 0) {
|
||||
return $q->row();
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
|
||||
require_once('Mobile_Detect.php');
|
||||
|
||||
class Mobile_model extends CI_Model {
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function isMobile() {
|
||||
|
||||
$detect = new Mobile_Detect;
|
||||
return $detect->isTablet();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
<?php
|
||||
|
||||
class Offers_model extends CI_Model {
|
||||
|
||||
var $optCons = '';
|
||||
var $currentStyle = 'form-control select';
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function attachOffers($email) {
|
||||
$emailTrim = trim($email);
|
||||
$mysql = "SELECT id AS member_id FROM members WHERE username = '$emailTrim' LIMIT 1 ";
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$num = $query->num_rows();
|
||||
if ($num == 1) {
|
||||
|
||||
// $out = $query->result_array();
|
||||
// print_r($out);
|
||||
$mysqlU = " UPDATE members_jobs_offer SET client_id ='". $query->row()->member_id ."' WHERE client_id = 0 AND email='$emailTrim' AND expire> now()";
|
||||
$this->db->query($mysqlU);
|
||||
}
|
||||
}
|
||||
|
||||
// NOT completed --
|
||||
public function getUserPendingOffers($member_id) {
|
||||
|
||||
$out = array();
|
||||
$error_state = false;
|
||||
$out['error'] = '';
|
||||
|
||||
$sqlOffer ="SELECT o.*,j.title,j.description,j.timeline_days,j.price FROM members_jobs_offer o LEFT JOIN members_jobs j ON j.id =o.job_id";
|
||||
|
||||
return $out;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
|
||||
class Recipient_model extends CI_Model {
|
||||
|
||||
var $optCons = '';
|
||||
var $currentStyle = 'form-control select';
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function verifyNewRecipientInfo($data, $member_id) {
|
||||
|
||||
$out = array();
|
||||
$error_state = false;
|
||||
$out['error'] = '';
|
||||
|
||||
if ($data['country'] == '' || $data['firstname'] == '' || $data['lastname'] == '' || $data['state'] == '' || $data['city'] == '') {
|
||||
$out['error'] .="All feilds required<br>";
|
||||
$error_state = true;
|
||||
}
|
||||
|
||||
|
||||
if ($error_state == false) {
|
||||
|
||||
if ($data['account_no'] == '' || $data['account_no_repeat'] == '') {
|
||||
$out['error'] .="Invalid Account Number<br>";
|
||||
$error_state = true;
|
||||
} else {
|
||||
if ($data['account_no'] != $data['account_no_repeat']) {
|
||||
$out['error'] .="Account numbers did not match<br>";
|
||||
$error_state = true;
|
||||
}
|
||||
}
|
||||
|
||||
if ($data['banks'] == '') {
|
||||
$out['error'] .="Select Bank Name<br>";
|
||||
$error_state = true;
|
||||
}
|
||||
|
||||
if (trim($data['account_type']) == '') {
|
||||
$out['error'] .="Select Account Type<br>";
|
||||
$error_state = true;
|
||||
}
|
||||
}
|
||||
|
||||
$out['error_state'] = $error_state;
|
||||
|
||||
|
||||
// print_r($data);
|
||||
return $out;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
* $data['country_combo'] = $this->combo_model->getCountryCombo('country', $data['country']);
|
||||
$data['bank_combo'] = $this->combo_model->getBankCombo('banks', $data['banks']);
|
||||
$data['account_type'] = $this->combo_model->getAccountTypeCombo('account_type', $data['account_type']);
|
||||
|
||||
* $data['firstname'] = $data['lastname'] = $data['account_no'] = $data['account_no_repeat'] = '';
|
||||
$data['state'] = $data['city'] = '';
|
||||
|
||||
*/
|
||||
@@ -0,0 +1,109 @@
|
||||
<?php
|
||||
|
||||
class Userlog_model extends CI_Model {
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function loadUserLog($data) {
|
||||
$res = '';
|
||||
$q = $this
|
||||
->db
|
||||
->where('member_id', $data['member_id'])
|
||||
->order_by('created', 'DESC')
|
||||
->limit(10)
|
||||
->get('members_log');
|
||||
|
||||
|
||||
if ($q->num_rows() > 0) {
|
||||
foreach ($q->result() as $row) {
|
||||
|
||||
$res .="<li class='media'><div class='media-left'>
|
||||
<a href='#' class='btn border-primary text-primary btn-flat btn-rounded btn-icon btn-sm'><i class='icon-git-pull-request'></i></a>
|
||||
</div>
|
||||
<div class='media-body'>
|
||||
".$row->mlog."<div class=\"media-annotation\"> ".$row->created."</div>
|
||||
</div>
|
||||
</li>";
|
||||
|
||||
// echo $row->title;
|
||||
}
|
||||
} else {
|
||||
$res = $this->no_log();
|
||||
}
|
||||
return $res;
|
||||
// return $q->result();
|
||||
}
|
||||
|
||||
private function no_log() {
|
||||
return ''
|
||||
. '<li class="media">
|
||||
<div class="media-left">
|
||||
<i class="icon-git-pull-request"></i>
|
||||
</div>
|
||||
|
||||
<div class="media-body">
|
||||
You do not have any log...
|
||||
</div>
|
||||
</li>';
|
||||
}
|
||||
|
||||
/*
|
||||
*
|
||||
* <li class="media">
|
||||
<div class="media-left">
|
||||
<a href="#" class="btn border-primary text-primary btn-flat btn-rounded btn-icon btn-sm"><i class="icon-git-pull-request"></i></a>
|
||||
</div>
|
||||
|
||||
<div class="media-body">
|
||||
Drop the IE <a href="#">specific hacks</a> for temporal inputs
|
||||
<div class="media-annotation">4 minutes ago</div>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<li class="media">
|
||||
<div class="media-left">
|
||||
<a href="#" class="btn border-warning text-warning btn-flat btn-rounded btn-icon btn-sm"><i class="icon-git-commit"></i></a>
|
||||
</div>
|
||||
|
||||
<div class="media-body">
|
||||
Add full font overrides for popovers and tooltips
|
||||
<div class="media-annotation">36 minutes ago</div>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<li class="media">
|
||||
<div class="media-left">
|
||||
<a href="#" class="btn border-info text-info btn-flat btn-rounded btn-icon btn-sm"><i class="icon-git-branch"></i></a>
|
||||
</div>
|
||||
|
||||
<div class="media-body">
|
||||
<a href="#">Chris Arney</a> created a new <span class="text-semibold">Design</span> branch
|
||||
<div class="media-annotation">2 hours ago</div>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<li class="media">
|
||||
<div class="media-left">
|
||||
<a href="#" class="btn border-success text-success btn-flat btn-rounded btn-icon btn-sm"><i class="icon-git-merge"></i></a>
|
||||
</div>
|
||||
|
||||
<div class="media-body">
|
||||
<a href="#">Eugene Kopyov</a> merged <span class="text-semibold">Master</span> and <span class="text-semibold">Dev</span> branches
|
||||
<div class="media-annotation">Dec 18, 18:36</div>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<li class="media">
|
||||
<div class="media-left">
|
||||
<a href="#" class="btn border-primary text-primary btn-flat btn-rounded btn-icon btn-sm"><i class="icon-git-pull-request"></i></a>
|
||||
</div>
|
||||
|
||||
<div class="media-body">
|
||||
Have Carousel ignore keyboard events
|
||||
<div class="media-annotation">Dec 12, 05:46</div>
|
||||
</div>
|
||||
</li>
|
||||
*/
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Vendored
+11
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,92 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
?><!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Welcome to CodeIgniter</title>
|
||||
|
||||
<style type="text/css">
|
||||
|
||||
::selection { background-color: #E13300; color: white; }
|
||||
::-moz-selection { background-color: #E13300; color: white; }
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
margin: 40px;
|
||||
font: 13px/20px normal Helvetica, Arial, sans-serif;
|
||||
color: #4F5155;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #003399;
|
||||
background-color: transparent;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #444;
|
||||
background-color: transparent;
|
||||
border-bottom: 1px solid #D0D0D0;
|
||||
font-size: 19px;
|
||||
font-weight: normal;
|
||||
margin: 0 0 14px 0;
|
||||
padding: 14px 15px 10px 15px;
|
||||
}
|
||||
|
||||
code {
|
||||
font-family: Consolas, Monaco, Courier New, Courier, monospace;
|
||||
font-size: 12px;
|
||||
background-color: #f9f9f9;
|
||||
border: 1px solid #D0D0D0;
|
||||
color: #002166;
|
||||
display: block;
|
||||
margin: 14px 0 14px 0;
|
||||
padding: 12px 10px 12px 10px;
|
||||
}
|
||||
|
||||
#body {
|
||||
margin: 0 15px 0 15px;
|
||||
}
|
||||
|
||||
p.footer {
|
||||
text-align: right;
|
||||
font-size: 11px;
|
||||
border-top: 1px solid #D0D0D0;
|
||||
line-height: 32px;
|
||||
padding: 0 10px 0 10px;
|
||||
margin: 20px 0 0 0;
|
||||
}
|
||||
|
||||
#container {
|
||||
margin: 10px;
|
||||
border: 1px solid #D0D0D0;
|
||||
box-shadow: 0 0 8px #D0D0D0;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
<table><tr>
|
||||
<td><a href="about">About</a></td><td>Contact</td>
|
||||
</tr></table>
|
||||
<h1>Welcome to about Page!</h1>
|
||||
|
||||
<div id="body">
|
||||
<p>The page you are looking at is being generated dynamically by CodeIgniter.</p>
|
||||
|
||||
<p>If you would like to edit this page you'll find it located at:</p>
|
||||
<code>application/views/welcome_message.php</code>
|
||||
|
||||
<p>The corresponding controller for this page is found at:</p>
|
||||
<code>application/controllers/Welcome.php</code>
|
||||
|
||||
<p>If you are exploring CodeIgniter for the very first time, you should start by reading the <a href="user_guide/">User Guide</a>.</p>
|
||||
</div>
|
||||
|
||||
<p class="footer">Page rendered in <strong>{elapsed_time}</strong> seconds. <?php echo (ENVIRONMENT === 'development') ? 'CodeIgniter Version <strong>' . CI_VERSION . '</strong>' : '' ?></p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,417 @@
|
||||
<!doctype html>
|
||||
|
||||
<html class="no-js" lang="en">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta charset="utf-8">
|
||||
|
||||
<!-- Page Title Here -->
|
||||
<title>WrenchBoard</title>
|
||||
|
||||
<!-- Page Description Here -->
|
||||
<meta name="description" content="A responsive coming soon template, un template HTML pour une page en cours de construction">
|
||||
|
||||
<!-- Disable screen scaling-->
|
||||
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1, maximum-scale=1, user-scalable=0">
|
||||
|
||||
<!-- Place favicon.ico and apple-touch-icon(s) in the root directory -->
|
||||
|
||||
<!-- Initializer -->
|
||||
<link rel="stylesheet" href="/passet/css/normalize.css">
|
||||
|
||||
<!-- Web fonts and Web Icons -->
|
||||
<link rel="stylesheet" href="/passet/css/pageloader.css">
|
||||
<link rel="stylesheet" href="/passet/fonts/opensans/stylesheet.css">
|
||||
<link rel="stylesheet" href="/passet/fonts/asap/stylesheet.css">
|
||||
<link rel="stylesheet" href="/passet/css/ionicons.min.css">
|
||||
|
||||
<!-- Vendor CSS style -->
|
||||
<link rel="stylesheet" href="/passet/css/foundation.min.css">
|
||||
<link rel="stylesheet" href="/passet/js/vendor/jquery.fullPage.css">
|
||||
<link rel="stylesheet" href="/passet/js/vegas/vegas.min.css">
|
||||
|
||||
<!-- Main CSS files -->
|
||||
<link rel="stylesheet" href="/passet/css/main.css">
|
||||
<link rel="stylesheet" href="/passet/css/main_responsive.css">
|
||||
<link rel="stylesheet" href="/passet/css/style-color1.css">
|
||||
|
||||
<script src="/passet/js/vendor/modernizr-2.7.1.min.js"></script>
|
||||
</head>
|
||||
<body id="menu" class="alt-bg">
|
||||
<!--[if lt IE 8]>
|
||||
<p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
|
||||
<![endif]-->
|
||||
|
||||
<!-- Page Loader -->
|
||||
<div class="page-loader" id="page-loader">
|
||||
<div><i class="ion ion-loading-d"></i><p>loading</p></div>
|
||||
</div>
|
||||
|
||||
<!-- BEGIN OF site header Menu -->
|
||||
<!-- Add "material" class for a material design style -->
|
||||
<header class="header-top">
|
||||
|
||||
<div class="menu clearfix">
|
||||
<a href="#s-about-us">about</a>
|
||||
|
||||
<!--<div class="menu-cont">
|
||||
<p class="text">Menu cont</p>
|
||||
<ul class="sub-menu">
|
||||
<li><a href="htp://page">My Page</a></li>
|
||||
</ul>
|
||||
</div>-->
|
||||
<!-- Add other menu similar to "about" here -->
|
||||
<a href="#contact">contact</a>
|
||||
<a href="/agents/">account</a>
|
||||
</div>
|
||||
</header>
|
||||
<!-- END OF site header Menu-->
|
||||
|
||||
<!-- BEGIN OF Quick nav icons at left -->
|
||||
<nav class="quick-link count-4 nav-left">
|
||||
<div class="logo">
|
||||
<a href="#home">
|
||||
<img src="/passet/img/logo_only.png" alt="Logo Brand">
|
||||
</a>
|
||||
</div>
|
||||
<ul id="qmenu" class="qmenu">
|
||||
<li data-menuanchor="home">
|
||||
<a href="#home" class=""><i class="icon ion ion-home"></i>
|
||||
</a>
|
||||
<span class="title">Home page</span>
|
||||
</li>
|
||||
|
||||
<li data-menuanchor="about-us">
|
||||
<a href="#about-us"><i class="icon ion ion-android-information"></i>
|
||||
</a>
|
||||
<span class="title">About Us</span>
|
||||
</li>
|
||||
<!--<li data-menuanchor="contact">
|
||||
<a href="#contact"><i class="icon ion ion-android-call"></i>
|
||||
</a>
|
||||
<span class="title">Contact</span>
|
||||
</li>-->
|
||||
<li data-menuanchor="contact">
|
||||
<a href="#contact"><i class="icon ion ion-email"></i>
|
||||
</a>
|
||||
<span class="title">Contact</span>
|
||||
</li>
|
||||
</ul>
|
||||
</nav>
|
||||
<!-- END OF Quick nav icons at left -->
|
||||
|
||||
|
||||
|
||||
<!-- BEGIN OF site cover -->
|
||||
<div class="page-cover" id="s-cover">
|
||||
<!-- Cover Background -->
|
||||
<div class="cover-bg pos-abs full-size bg-img" data-image-src="/passet/img/payback.jpg"></div>
|
||||
|
||||
<!-- BEGIN OF Slideshow Background -->
|
||||
<!--<div class="cover-bg pos-abs full-size slide-show">
|
||||
<i class='img' data-src='./img/bg-slide1.jpg'></i>
|
||||
<i class='img' data-src='./img/bg-slide2.jpg'></i>
|
||||
<i class='img' data-src='./img/bg-slide3.jpg'></i>
|
||||
<i class='img' data-src='./img/bg-slide4.jpg'></i>
|
||||
</div>-->
|
||||
<!-- END OF Slideshow Background -->
|
||||
|
||||
<!--BEGIN OF Static video bg - uncomment below to use Video as Background-->
|
||||
<div id="container" class="video-container show-for-medium-up">
|
||||
<video autoplay="autoplay" loop="loop" autobuffer="autobuffer" muted="muted"
|
||||
width="640" height="360">
|
||||
<source src="/passet/vid/paywithcard.mp4" type="video/mp4">
|
||||
</video>
|
||||
</div>
|
||||
<!--END OF Static video bg-->
|
||||
|
||||
<!-- Solid color as background -->
|
||||
<!-- <div class="cover-bg pos-abs full-size bg-color" data-bgcolor="rgb(59, 59, 59)"></div>-->
|
||||
|
||||
<!-- Solid color as filter -->
|
||||
<div class="cover-bg-mask pos-abs full-size bg-color" data-bgcolor="rgba(0, 0, 0, 0.41)"></div>
|
||||
|
||||
</div>
|
||||
<!--END OF site Cover -->
|
||||
|
||||
<!-- Begin of timer pane -->
|
||||
<div class="pane-when " id="s-when">
|
||||
<div class="content">
|
||||
<!-- Clock -->
|
||||
<div class="clock clock-countdown">
|
||||
<div class="site-config"
|
||||
data-date="11/30/2016 00:00:00"
|
||||
data-date-timezone="+0"
|
||||
></div>
|
||||
<div class="elem-center">
|
||||
<div class="digit">
|
||||
WrenchBoard
|
||||
</div>
|
||||
</div>
|
||||
<!-- Logo instead -->
|
||||
<!--
|
||||
<div class="logo">
|
||||
<a href="#">
|
||||
<img src="/passet/img/logo_only.png">
|
||||
</a>
|
||||
</div>
|
||||
-->
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<footer>
|
||||
<p>Users and Vendors Management for Partners</p>
|
||||
</footer>
|
||||
</div>
|
||||
</div>
|
||||
<!-- End of timer pane -->
|
||||
|
||||
<!-- BEGIN OF site main content content here -->
|
||||
<main class="page-main" id="mainpage">
|
||||
|
||||
<!-- Begin of home page -->
|
||||
<div class="section page-home page page-cent" id="s-home">
|
||||
|
||||
<!-- Logo -->
|
||||
<!--<div class="logo-container">
|
||||
<img class="h-logo" src="/passet/img/logo_only.png" alt="Logo">
|
||||
</div>-->
|
||||
<!-- Content -->
|
||||
<section class="content">
|
||||
|
||||
<header class="header">
|
||||
<div class="h-left">
|
||||
<h2>Bulk <strong>topup,sms</strong></h2>
|
||||
</div>
|
||||
<div class="h-right">
|
||||
<h3>integrated payments</h3>
|
||||
</div>
|
||||
</header>
|
||||
</section>
|
||||
|
||||
<!-- Scroll down button -->
|
||||
<footer class="p-footer p-scrolldown">
|
||||
<a href="#register">
|
||||
<div class="arrow-d">
|
||||
<div class="before">Scroll</div>
|
||||
<div class="after">Down</div>
|
||||
<div class="circle"><i class="ion ion-mouse"></i></div>
|
||||
</div>
|
||||
</a>
|
||||
</footer>
|
||||
</div>
|
||||
<!-- End of home page -->
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- Begin of about us page -->
|
||||
<div class="section page-about page page-cent" id="s-about-us">
|
||||
<section class="content">
|
||||
<header class="p-title">
|
||||
<h3>About Us<i class="ion ion-android-information">
|
||||
</i>
|
||||
</h3>
|
||||
<h4 class="subhead">We <span class="bold">simplyfy</span> all things <span class="bold">payments</span> </h4>
|
||||
</header>
|
||||
<article class="text">
|
||||
<p>PayQuic is global payments and airtime top-up company. Open for business 24/7, 365 days a year, we pride ourselves on offering a fast, friendly and secure service. </p>
|
||||
</article>
|
||||
</section>
|
||||
<footer class="p-footer p-scrolldown">
|
||||
<a href="#contact">
|
||||
<div class="arrow-d">
|
||||
<div class="before">Contact</div>
|
||||
<div class="after">Message</div>
|
||||
<div class="circle"><i class="ion ion-mouse"></i></div>
|
||||
</div>
|
||||
</a>
|
||||
</footer>
|
||||
</div>
|
||||
<!-- End of about us page -->
|
||||
|
||||
<!-- Begin of Contact page -->
|
||||
<div class="section page-contact page page-cent bg-color" data-bgcolor="rgba(95, 25, 208, 0.88)s" id="s-contact">
|
||||
<!-- Begin of contact information -->
|
||||
<div class="slide" id="s-information" data-anchor="information">
|
||||
<section class="content">
|
||||
<header class="p-title">
|
||||
<h3>Contact<i class="ion ion-location">
|
||||
</i>
|
||||
</h3>
|
||||
<ul class="buttons">
|
||||
<li class="show-for-medium-up">
|
||||
<a title="About" href="#about-us" ><i class="ion ion-android-information"></i></a>
|
||||
</li>
|
||||
<!--<li>
|
||||
<a title="Contact" href="#contact/information"><i class="ion ion-location"></i></a>
|
||||
</li>-->
|
||||
<li>
|
||||
<a title="Message" href="#contact/message"><i class="ion ion-email"></i></a>
|
||||
</li>
|
||||
</ul>
|
||||
</header>
|
||||
<!-- Begin Of Page SubSction -->
|
||||
<div class="contact">
|
||||
<div class="row">
|
||||
<div class="medium-6 columns left">
|
||||
<ul>
|
||||
<li>
|
||||
<h4>Email</h4>
|
||||
<p><a href="mailto://support@payquic.com">support@payquic.com</a></p>
|
||||
</li>
|
||||
<li>
|
||||
<h4>Address</h4>
|
||||
<p>96th Floor Buffalo House
|
||||
<br>2 Allen Avenue, Ikeja Lagos.</p>
|
||||
</li>
|
||||
<li>
|
||||
<h4>Phone</h4>
|
||||
<p>+234 0909-4666346</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="medium-6 columns social-links right">
|
||||
<ul>
|
||||
|
||||
<!-- legal notice -->
|
||||
<li class="show-for-medium-up">
|
||||
<h4>Website</h4>
|
||||
<p><a href="https://www.payquic.com">www.payquic.com</a></p>
|
||||
</li>
|
||||
<li class="show-for-medium-up">
|
||||
<h4>Find us on</h4>
|
||||
<!-- Begin of Social links -->
|
||||
<div class="socialnet">
|
||||
<a href="https://www.facebook.com/pages/Payquic/323598201151222" target="_blank"><i class="ion ion-social-facebook"></i></a>
|
||||
<a href="#"><i class="ion ion-social-twitter"></i></a>
|
||||
</div>
|
||||
<!-- End of Social links -->
|
||||
</li>
|
||||
<li>
|
||||
<p><img src="/passet/img/logo.png" alt="PayQuic" class="logo"></p>
|
||||
<p class="small"><strong><a href="http://highhay.com">PayQuic</a></strong>. All right reserved 2015</p>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- End of page SubSection -->
|
||||
</section>
|
||||
</div>
|
||||
<!-- end of contact information -->
|
||||
|
||||
<!-- begin of contact message -->
|
||||
<div class="slide" id="s-message" data-anchor="message">
|
||||
<section class="content">
|
||||
<header class="p-title">
|
||||
<h3>Write to us<i class="ion ion-email">
|
||||
</i>
|
||||
</h3>
|
||||
<ul class="buttons">
|
||||
<li class="show-for-medium-up">
|
||||
<a title="About" href="#about-us"><i class="ion ion-android-information"></i></a>
|
||||
</li>
|
||||
<li>
|
||||
<a title="Contact" href="#contact/information"><i class="ion ion-location"></i></a>
|
||||
</li>
|
||||
<!--<li>
|
||||
<a title="Message" href="#contact/message"><i class="ion ion-email"></i></a>
|
||||
</li>-->
|
||||
</ul>
|
||||
</header>
|
||||
<!-- Begin Of Page SubSction -->
|
||||
|
||||
<div class="page-block c-right v-zoomIn">
|
||||
<div class="wrapper">
|
||||
<div>
|
||||
<form class="message form send_message_form" method="get" action="ajaxserver/serverfile.php">
|
||||
<div class="fields clearfix">
|
||||
<div class="input">
|
||||
<label for="mes-name">Name </label>
|
||||
<input id="mes-name" name="name" type="text" placeholder="Your Name" required></div>
|
||||
<div class="buttons">
|
||||
<button id="submit-message" class="button email_b" name="submit_message">Ok</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="fields clearfix">
|
||||
<div class="input">
|
||||
<label for="mes-email">Email </label>
|
||||
<input id="mes-email" type="email" placeholder="Email Address" name="email" required>
|
||||
</div>
|
||||
</div>
|
||||
<div class="fields clearfix no-border">
|
||||
<label for="mes-text">Message </label>
|
||||
<textarea id="mes-text" placeholder="Message ..." name="message" required></textarea>
|
||||
|
||||
<div>
|
||||
<p class="message-ok invisible">Your message has been sent, thank you.</p>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- End Of Page SubSction -->
|
||||
</section>
|
||||
|
||||
</div>
|
||||
<!-- End of contact message -->
|
||||
</div>
|
||||
<!-- End of Contact page -->
|
||||
|
||||
</main>
|
||||
|
||||
<!-- END OF site main content content here -->
|
||||
|
||||
<!-- Begin of site footer -->
|
||||
<footer class="page-footer">
|
||||
<div>
|
||||
<a href="https://www.facebook.com/pages/Payquic/323598201151222" target="_blank"><i class="ion icon ion-social-facebook"></i></a>
|
||||
<a href="http://twitter.com/miradontsoa" target="_blank"><i class="ion icon ion-social-twitter"></i></a>
|
||||
</div>
|
||||
</footer>
|
||||
<!-- End of site footer -->
|
||||
|
||||
|
||||
<!-- <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>-->
|
||||
|
||||
<!-- All Javascript plugins goes here -->
|
||||
<!-- <script src="//code.jquery.com/jquery-1.11.2.min.js"></script>-->
|
||||
<script src="/passet/js/vendor/jquery-1.11.2.min.js"></script>
|
||||
<!-- All vendor scripts -->
|
||||
<script src="/passet/js/vendor/all.js"></script>
|
||||
|
||||
<!-- Detailed vendor scripts -->
|
||||
<!--<script src="/passet/js/vendor/jquery.fullPage.min.js"></script>
|
||||
<script src="/passet/js/vendor/jquery.slimscroll.min.js"></script>
|
||||
<script src="/passet/js/vendor/jquery.knob.min.js"></script>
|
||||
<script src="/passet/js/vegas/vegas.min.js"></script>
|
||||
<script src="/passet/js/jquery.maximage.js"></script>
|
||||
<script src="/passet/js/okvideo.min.js"></script>-->
|
||||
|
||||
<!-- Downcount JS -->
|
||||
<script src="/passet/js/jquery.downCount.js"></script>
|
||||
|
||||
<!-- Form script -->
|
||||
<script src="/passet/js/form_script.js"></script>
|
||||
|
||||
<!-- Javascript main files -->
|
||||
<script src="/passet/js/main.js"></script>
|
||||
|
||||
|
||||
<!-- Google Analytics: Uncomment and change UA-XXXXX-X to be your site"s ID. -->
|
||||
<!--<script>
|
||||
(function(b,o,i,l,e,r){b.GoogleAnalyticsObject=l;b[l]||(b[l]=
|
||||
function(){(b[l].q=b[l].q||[]).push(arguments)});b[l].l=+new Date;
|
||||
e=o.createElement(i);r=o.getElementsByTagName(i)[0];
|
||||
e.src="//www.google-analytics.com/analytics.js";
|
||||
r.parentNode.insertBefore(e,r)}(window,document,"script","ga"));
|
||||
ga("create","UA-XXXXX-X");ga("send","pageview");
|
||||
</script>-->
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,162 @@
|
||||
<!-- Main sidebar -->
|
||||
<div class="sidebar sidebar-main sidebar-default">
|
||||
<div class="sidebar-content">
|
||||
|
||||
<!-- Main navigation -->
|
||||
<div class="sidebar-category sidebar-category-visible">
|
||||
|
||||
|
||||
<div class="category-content no-padding">
|
||||
<ul class="navigation navigation-main navigation-accordion">
|
||||
|
||||
<!-- Main -->
|
||||
<li class="navigation-header"><span>Main</span> <i class="icon-menu" title="Main pages"></i></li>
|
||||
<li class="active"><a href="/bkouser/dash"><i class="icon-home4"></i> <span>Dashboard</span></a></li>
|
||||
<li><a href="/bkouser/contact"><i class="icon-copy"></i> <span>Contact Us</span></a></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-stack2"></i> <span>Member</span></a>
|
||||
<ul>
|
||||
<li><a href="/bkouser/locate">Locate Member</a></li>
|
||||
<?php
|
||||
if ($_SESSION['bko_selected_memberd_id'] != '' and $_SESSION['bko_selected_memberd_id'] > 0) {
|
||||
?>
|
||||
<li><a href="/bkouser/memberdetail">Member[<?php echo $_SESSION['bko_selected_id']; ?>]</a>
|
||||
<ul>
|
||||
<li><a href="layout_navbar_main_hideable.html">Hideable main navbar</a></li>
|
||||
<li><a href="layout_navbar_secondary_hideable.html">Hideable secondary navbar</a></li>
|
||||
<li><a href="layout_sidebar_sticky_custom.html">Sticky sidebar (custom scroll)</a></li>
|
||||
<li><a href="layout_sidebar_sticky_native.html">Sticky sidebar (native scroll)</a></li>
|
||||
<li><a href="layout_footer_fixed.html">Fixed footer</a></li>
|
||||
<li class="navigation-divider"></li>
|
||||
<li><a href="boxed_default.html">Boxed with default sidebar</a></li>
|
||||
<li><a href="boxed_mini.html">Boxed with mini sidebar</a></li>
|
||||
<li><a href="boxed_full.html">Boxed full width</a></li>
|
||||
|
||||
</ul>
|
||||
</li>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</ul>
|
||||
</li>
|
||||
<?
|
||||
if ($_SESSION['bko_group'] == 1 ){
|
||||
?>
|
||||
<li>
|
||||
<a href="#"><i class="icon-copy"></i> <span>Selected USER</span></a>
|
||||
<ul>
|
||||
<li><a href="/bkosmember/userdash" id="layout1">User Dash</a></li>
|
||||
<li><a href="/bkosmember/mtransfer" id="layout1">Transfer</a></li>
|
||||
<li><a href="/bkosmember/mpayments" id="layout2">Payments</a></li>
|
||||
<li><a href="/bkosmember/mjobsdone" id="layout2">Jobs Performed</a></li>
|
||||
<li><a href="/bkosmember/mjobposted" id="layout2">Jobs Posted</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
<!-- /main -->
|
||||
|
||||
<!-- Forms -->
|
||||
<li class="navigation-header"><span>Transaction</span> <i class="icon-menu" title="Forms"></i></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-pencil3"></i> <span>Account Withdraws</span></a>
|
||||
<ul>
|
||||
<li><a href="/bkotransaction/moneytransfer">Pending Withdraws</a></li>
|
||||
<li><a href="/bkotransaction/transmittransfer">Transmit Withdraws</a></li>
|
||||
<li><a href="/bkotransaction/completedtransfer">Completed Withdraws</a></li>
|
||||
<li><a href="/bkotransaction/accountdeposit">Pending Deposits</a></li>
|
||||
|
||||
<li><a href="/bkotransaction/moneytransfer">More....</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-file-css"></i> <span>Jobs/Contracts</span></a>
|
||||
<ul>
|
||||
<li><a href="/bkotransaction/pendingcontract">Pending Offer/Contract</a></li>
|
||||
<li><a href="/bkotransaction/expiredoffers">Expired Offer</a></li>
|
||||
<li><a href="/bkotransaction/activecontract">Active Contracts</a></li>
|
||||
<li><a href="/bkotransaction/pastduecontract">Past Due Contracts</a></li>
|
||||
<li><a href="/bkotransaction/completedcontract">Completed Contracts</a></li>
|
||||
<li><a href="/bkotransaction/jobcontractreport">Job Report(s)</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a href="#"><i class="icon-insert-template"></i> <span>Referrer</span></a>
|
||||
<ul>
|
||||
<li><a href="/bkotransaction/recentrefer">Recent Refer</a></li>
|
||||
<li><a href="/bkotransaction/referactivity">Refer Activities</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<!-- /forms -->
|
||||
|
||||
<!-- Appearance -->
|
||||
<li class="navigation-header"><span>Reports</span> <i class="icon-menu" title="Appearance"></i></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-grid"></i> <span>Reports</span></a>
|
||||
<ul>
|
||||
<li><a href="/bkoreport/withdraws">Account Withdraws</a></li>
|
||||
<li><a href="/bkoreport/pendpay">Pending Payments</a></li>
|
||||
<li><a href="/bkoreport/payments">Payments</a></li>
|
||||
<li><a href="/bkoreport/activetask">Active Tasks</a></li>
|
||||
<li><a href="/bkoreport/signup">Signups</a></li>
|
||||
<li><a href="/bkoreport/pendsignup">Pending Accounts</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-puzzle2"></i> <span>Configure</span></a>
|
||||
<ul>
|
||||
<li><a href="/confg/siteitems">Site Configure</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<!-- /appearance -->
|
||||
|
||||
<!-- Layout -->
|
||||
<li class="navigation-header"><span>Administration</span> <i class="icon-menu" title="Layout options"></i></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-indent-decrease2"></i> <span>Site Tools</span></a>
|
||||
<ul>
|
||||
<li><a href="/bkouser/uploads">Uploads</a></li>
|
||||
<li><a href="/bkouser/faq">Faq</a></li>
|
||||
<li><a href="/bkouser/wrbwhy">WrenchBoard Why?</a></li>
|
||||
<li><a href="/bkouser/terms">Terms & Cond.</a></li>
|
||||
<li><a href="/bkouser/about">About us</a></li>
|
||||
<li><a href="/bkouser/privacy">Privacy Policy</a></li>
|
||||
<li><a href="/bkouser/referterms">Refer Terms & Cond.</a></li>
|
||||
<li><a href="/bkouser/postjob">PostJob Terms</a></li>
|
||||
|
||||
<li><a href="/bkouser/howitwork">How it work</a></li>
|
||||
<li><a href="/bkouser/library">Library</a></li>
|
||||
<li><a href="/bkouser/fundaccount">Fund Account</a></li>
|
||||
|
||||
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
|
||||
<li>
|
||||
<a href="#"><i class="icon-indent-decrease2"></i> <span>System Tools</span></a>
|
||||
<ul>
|
||||
<li><a href="/bkouser/faq">Transfer Fee</a></li>
|
||||
<li><a href="/bkoadmin/users">Users Manager</a></li>
|
||||
<li><a href="/bkoadmin/permission">Permissions</a></li>
|
||||
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
<?
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- /layout -->
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /main navigation -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<!-- /main sidebar -->
|
||||
@@ -0,0 +1,654 @@
|
||||
<!-- Main sidebar -->
|
||||
<div class="sidebar sidebar-main sidebar-default">
|
||||
<div class="sidebar-content">
|
||||
|
||||
<!-- Main navigation -->
|
||||
<div class="sidebar-category sidebar-category-visible">
|
||||
|
||||
|
||||
<div class="category-content no-padding">
|
||||
<ul class="navigation navigation-main navigation-accordion">
|
||||
|
||||
<!-- Main -->
|
||||
<li class="navigation-header"><span>Main</span> <i class="icon-menu" title="Main pages"></i></li>
|
||||
<li class="active"><a href="/bkouser/dash"><i class="icon-home4"></i> <span>Dashboard</span></a></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-stack2"></i> <span>Member</span></a>
|
||||
<ul>
|
||||
<li><a href="/bkouser/locate">Locate Member</a></li>
|
||||
<li><a href="/bkouser/memberdetail">Current Member</a></li>
|
||||
<li><a href="layout_navbar_main_hideable.html">Hideable main navbar</a></li>
|
||||
<li><a href="layout_navbar_secondary_hideable.html">Hideable secondary navbar</a></li>
|
||||
<li><a href="layout_sidebar_sticky_custom.html">Sticky sidebar (custom scroll)</a></li>
|
||||
<li><a href="layout_sidebar_sticky_native.html">Sticky sidebar (native scroll)</a></li>
|
||||
<li><a href="layout_footer_fixed.html">Fixed footer</a></li>
|
||||
<li class="navigation-divider"></li>
|
||||
<li><a href="boxed_default.html">Boxed with default sidebar</a></li>
|
||||
<li><a href="boxed_mini.html">Boxed with mini sidebar</a></li>
|
||||
<li><a href="boxed_full.html">Boxed full width</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-copy"></i> <span>Layouts</span></a>
|
||||
<ul>
|
||||
<li><a href="../../../layout_1/LTR/index.html" id="layout1">Layout 1</a></li>
|
||||
<li><a href="../../../layout_2/LTR/index.html" id="layout2">Layout 2</a></li>
|
||||
<li><a href="index.html" id="layout3">Layout 3 <span class="label bg-warning-400">Current</span></a></li>
|
||||
<li><a href="../../../layout_4/LTR/index.html" id="layout4">Layout 4</a></li>
|
||||
<li><a href="../../../layout_5/LTR/index.html" id="layout5">Layout 5</a></li>
|
||||
<li class="disabled"><a href="../../../layout_6/LTR/index.html" id="layout6">Layout 6 <span class="label label-transparent">Coming soon</span></a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-droplet2"></i> <span>Color system</span></a>
|
||||
<ul>
|
||||
<li><a href="colors_primary.html">Primary palette</a></li>
|
||||
<li><a href="colors_danger.html">Danger palette</a></li>
|
||||
<li><a href="colors_success.html">Success palette</a></li>
|
||||
<li><a href="colors_warning.html">Warning palette</a></li>
|
||||
<li><a href="colors_info.html">Info palette</a></li>
|
||||
<li class="navigation-divider"></li>
|
||||
<li><a href="colors_pink.html">Pink palette</a></li>
|
||||
<li><a href="colors_violet.html">Violet palette</a></li>
|
||||
<li><a href="colors_purple.html">Purple palette</a></li>
|
||||
<li><a href="colors_indigo.html">Indigo palette</a></li>
|
||||
<li><a href="colors_blue.html">Blue palette</a></li>
|
||||
<li><a href="colors_teal.html">Teal palette</a></li>
|
||||
<li><a href="colors_green.html">Green palette</a></li>
|
||||
<li><a href="colors_orange.html">Orange palette</a></li>
|
||||
<li><a href="colors_brown.html">Brown palette</a></li>
|
||||
<li><a href="colors_grey.html">Grey palette</a></li>
|
||||
<li><a href="colors_slate.html">Slate palette</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-stack"></i> <span>Starter kit</span></a>
|
||||
<ul>
|
||||
<li><a href="starters/horizontal_nav.html">Horizontal navigation</a></li>
|
||||
<li><a href="starters/1_col.html">1 column</a></li>
|
||||
<li><a href="starters/2_col.html">2 columns</a></li>
|
||||
<li>
|
||||
<a href="#">3 columns</a>
|
||||
<ul>
|
||||
<li><a href="starters/3_col_dual.html">Dual sidebars</a></li>
|
||||
<li><a href="starters/3_col_double.html">Double sidebars</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="starters/4_col.html">4 columns</a></li>
|
||||
<li><a href="starters/layout_boxed.html">Boxed layout</a></li>
|
||||
<li class="navigation-divider"></li>
|
||||
<li><a href="starters/layout_navbar_fixed_main.html">Fixed main navbar</a></li>
|
||||
<li><a href="starters/layout_navbar_fixed_secondary.html">Fixed secondary navbar</a></li>
|
||||
<li><a href="starters/layout_navbar_fixed_both.html">Both navbars fixed</a></li>
|
||||
<li><a href="starters/layout_sidebar_sticky.html">Sticky sidebar</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="changelog.html"><i class="icon-list-unordered"></i> <span>Changelog <span class="label bg-blue-400">1.3</span></span></a></li>
|
||||
<li><a href="../../RTL/index.html"><i class="icon-width"></i> <span>RTL version</span></a></li>
|
||||
<!-- /main -->
|
||||
|
||||
<!-- Forms -->
|
||||
<li class="navigation-header"><span>Forms</span> <i class="icon-menu" title="Forms"></i></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-pencil3"></i> <span>Form components</span></a>
|
||||
<ul>
|
||||
<li><a href="form_inputs_basic.html">Basic inputs</a></li>
|
||||
<li><a href="form_checkboxes_radios.html">Checkboxes & radios</a></li>
|
||||
<li><a href="form_input_groups.html">Input groups</a></li>
|
||||
<li><a href="form_controls_extended.html">Extended controls</a></li>
|
||||
<li><a href="form_floating_labels.html">Floating labels</a></li>
|
||||
<li>
|
||||
<a href="#">Selects</a>
|
||||
<ul>
|
||||
<li><a href="form_select2.html">Select2 selects</a></li>
|
||||
<li><a href="form_multiselect.html">Bootstrap multiselect</a></li>
|
||||
<li><a href="form_select_box_it.html">SelectBoxIt selects</a></li>
|
||||
<li><a href="form_bootstrap_select.html">Bootstrap selects</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="form_tag_inputs.html">Tag inputs</a></li>
|
||||
<li><a href="form_dual_listboxes.html">Dual Listboxes</a></li>
|
||||
<li><a href="form_editable.html">Editable forms</a></li>
|
||||
<li><a href="form_validation.html">Validation</a></li>
|
||||
<li><a href="form_inputs_grid.html">Inputs grid</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-file-css"></i> <span>JSON forms</span></a>
|
||||
<ul>
|
||||
<li><a href="alpaca_basic.html">Basic inputs</a></li>
|
||||
<li><a href="alpaca_advanced.html">Advanced inputs</a></li>
|
||||
<li><a href="alpaca_controls.html">Controls</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-footprint"></i> <span>Wizards</span></a>
|
||||
<ul>
|
||||
<li><a href="wizard_steps.html">Steps wizard</a></li>
|
||||
<li><a href="wizard_form.html">Form wizard</a></li>
|
||||
<li><a href="wizard_stepy.html">Stepy wizard</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-spell-check"></i> <span>Editors</span></a>
|
||||
<ul>
|
||||
<li><a href="editor_summernote.html">Summernote editor</a></li>
|
||||
<li><a href="editor_ckeditor.html">CKEditor</a></li>
|
||||
<li><a href="editor_wysihtml5.html">WYSIHTML5 editor</a></li>
|
||||
<li><a href="editor_code.html">Code editor</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-select2"></i> <span>Pickers</span></a>
|
||||
<ul>
|
||||
<li><a href="picker_date.html">Date & time pickers</a></li>
|
||||
<li><a href="picker_color.html">Color pickers</a></li>
|
||||
<li><a href="picker_location.html">Location pickers</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-insert-template"></i> <span>Form layouts</span></a>
|
||||
<ul>
|
||||
<li><a href="form_layout_vertical.html">Vertical form</a></li>
|
||||
<li><a href="form_layout_horizontal.html">Horizontal form</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<!-- /forms -->
|
||||
|
||||
<!-- Appearance -->
|
||||
<li class="navigation-header"><span>Appearance</span> <i class="icon-menu" title="Appearance"></i></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-grid"></i> <span>Components</span></a>
|
||||
<ul>
|
||||
<li><a href="components_modals.html">Modals</a></li>
|
||||
<li><a href="components_dropdowns.html">Dropdown menus</a></li>
|
||||
<li><a href="components_tabs.html">Tabs component</a></li>
|
||||
<li><a href="components_pills.html">Pills component</a></li>
|
||||
<li><a href="components_navs.html">Accordion and navs</a></li>
|
||||
<li><a href="components_buttons.html">Buttons</a></li>
|
||||
<li><a href="components_notifications_pnotify.html">PNotify notifications</a></li>
|
||||
<li><a href="components_notifications_others.html">Other notifications</a></li>
|
||||
<li><a href="components_popups.html">Tooltips and popovers</a></li>
|
||||
<li><a href="components_alerts.html">Alerts</a></li>
|
||||
<li><a href="components_pagination.html">Pagination</a></li>
|
||||
<li><a href="components_labels.html">Labels and badges</a></li>
|
||||
<li><a href="components_loaders.html">Loaders and bars</a></li>
|
||||
<li><a href="components_thumbnails.html">Thumbnails</a></li>
|
||||
<li><a href="components_page_header.html">Page header</a></li>
|
||||
<li><a href="components_breadcrumbs.html">Breadcrumbs</a></li>
|
||||
<li><a href="components_media.html">Media objects</a></li>
|
||||
<li><a href="components_affix.html">Affix and Scrollspy</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-puzzle2"></i> <span>Content appearance</span></a>
|
||||
<ul>
|
||||
<li><a href="appearance_content_panels.html">Content panels</a></li>
|
||||
<li><a href="appearance_panel_heading.html">Panel heading elements</a></li>
|
||||
<li><a href="appearance_panel_footer.html">Panel footer elements</a></li>
|
||||
<li><a href="appearance_draggable_panels.html">Draggable panels</a></li>
|
||||
<li><a href="appearance_text_styling.html">Text styling</a></li>
|
||||
<li><a href="appearance_typography.html">Typography</a></li>
|
||||
<li><a href="appearance_helpers.html">Helper classes</a></li>
|
||||
<li><a href="appearance_syntax_highlighter.html">Syntax highlighter</a></li>
|
||||
<li><a href="appearance_content_grid.html">Grid system</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-gift"></i> <span>Extra components</span></a>
|
||||
<ul>
|
||||
<li><a href="extra_sliders_noui.html">NoUI sliders</a></li>
|
||||
<li><a href="extra_sliders_ion.html">Ion range sliders</a></li>
|
||||
<li><a href="extra_session_timeout.html">Session timeout</a></li>
|
||||
<li><a href="extra_idle_timeout.html">Idle timeout</a></li>
|
||||
<li><a href="extra_trees.html">Dynamic tree views</a></li>
|
||||
<li><a href="extra_context_menu.html">Context menu</a></li>
|
||||
<li><a href="extra_fab.html">Floating action buttons</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-spinner2 spinner"></i> <span>Animations</span></a>
|
||||
<ul>
|
||||
<li><a href="animations_css3.html">CSS3 animations</a></li>
|
||||
<li>
|
||||
<a href="#">Velocity animations</a>
|
||||
<ul>
|
||||
<li><a href="animations_velocity_basic.html">Basic usage</a></li>
|
||||
<li><a href="animations_velocity_ui.html">UI pack effects</a></li>
|
||||
<li><a href="animations_velocity_examples.html">Advanced examples</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-thumbs-up2"></i> <span>Icons</span></a>
|
||||
<ul>
|
||||
<li><a href="icons_glyphicons.html">Glyphicons</a></li>
|
||||
<li><a href="icons_icomoon.html">Icomoon</a></li>
|
||||
<li><a href="icons_fontawesome.html">Font awesome</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<!-- /appearance -->
|
||||
|
||||
<!-- Layout -->
|
||||
<li class="navigation-header"><span>Layout</span> <i class="icon-menu" title="Layout options"></i></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-indent-decrease2"></i> <span>Sidebars</span></a>
|
||||
<ul>
|
||||
<li><a href="sidebar_default_collapse.html">Default collapsible</a></li>
|
||||
<li><a href="sidebar_default_hide.html">Default hideable</a></li>
|
||||
<li><a href="sidebar_mini_collapse.html">Mini collapsible</a></li>
|
||||
<li><a href="sidebar_mini_hide.html">Mini hideable</a></li>
|
||||
<li>
|
||||
<a href="#">Dual sidebar</a>
|
||||
<ul>
|
||||
<li><a href="sidebar_dual.html">Dual sidebar</a></li>
|
||||
<li><a href="sidebar_dual_double_collapse.html">Dual double collapse</a></li>
|
||||
<li><a href="sidebar_dual_double_hide.html">Dual double hide</a></li>
|
||||
<li><a href="sidebar_dual_swap.html">Swap sidebars</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#">Double sidebar</a>
|
||||
<ul>
|
||||
<li><a href="sidebar_double_collapse.html">Collapse main sidebar</a></li>
|
||||
<li><a href="sidebar_double_hide.html">Hide main sidebar</a></li>
|
||||
<li><a href="sidebar_double_fix_default.html">Fix default width</a></li>
|
||||
<li><a href="sidebar_double_fix_mini.html">Fix mini width</a></li>
|
||||
<li><a href="sidebar_double_visible.html">Opposite sidebar visible</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="sidebar_categories.html">Separate categories</a></li>
|
||||
<li><a href="sidebar_hidden.html">Hidden sidebar</a></li>
|
||||
<li><a href="sidebar_dark.html">Dark sidebar</a></li>
|
||||
<li><a href="sidebar_components.html">Sidebar components</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-sort"></i> <span>Vertical navigation</span></a>
|
||||
<ul>
|
||||
<li><a href="navigation_vertical_collapsible.html">Collapsible menu</a></li>
|
||||
<li><a href="navigation_vertical_accordion.html">Accordion menu</a></li>
|
||||
<li><a href="navigation_vertical_sizing.html">Navigation sizing</a></li>
|
||||
<li><a href="navigation_vertical_bordered.html">Bordered navigation</a></li>
|
||||
<li><a href="navigation_vertical_right_icons.html">Right icons</a></li>
|
||||
<li><a href="navigation_vertical_labels_badges.html">Labels and badges</a></li>
|
||||
<li><a href="navigation_vertical_disabled.html">Disabled navigation links</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-transmission"></i> <span>Horizontal navigation</span></a>
|
||||
<ul>
|
||||
<li><a href="navigation_horizontal_click.html">Submenu on click</a></li>
|
||||
<li><a href="navigation_horizontal_hover.html">Submenu on hover</a></li>
|
||||
<li><a href="navigation_horizontal_elements.html">With custom elements</a></li>
|
||||
<li><a href="navigation_horizontal_tabs.html">Tabbed navigation</a></li>
|
||||
<li><a href="navigation_horizontal_disabled.html">Disabled navigation links</a></li>
|
||||
<li><a href="navigation_horizontal_mega.html">Horizontal mega menu</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-menu3"></i> <span>Navbars</span></a>
|
||||
<ul>
|
||||
<li><a href="navbar_single.html">Single navbar</a></li>
|
||||
<li>
|
||||
<a href="#">Multiple navbars</a>
|
||||
<ul>
|
||||
<li><a href="navbar_multiple_navbar_navbar.html">Navbar + navbar</a></li>
|
||||
<li><a href="navbar_multiple_header_navbar.html">Header + navbar</a></li>
|
||||
<li><a href="navbar_multiple_navbar_content.html">Navbar + content</a></li>
|
||||
<li><a href="navbar_multiple_top_bottom.html">Top + bottom</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="navbar_colors.html">Color options</a></li>
|
||||
<li><a href="navbar_sizes.html">Sizing options</a></li>
|
||||
<li><a href="navbar_hideable.html">Hide on scroll</a></li>
|
||||
<li><a href="navbar_components.html">Navbar components</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-tree5"></i> <span>Menu levels</span></a>
|
||||
<ul>
|
||||
<li><a href="#"><i class="icon-IE"></i> Second level</a></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-firefox"></i> Second level with child</a>
|
||||
<ul>
|
||||
<li><a href="#"><i class="icon-android"></i> Third level</a></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-apple2"></i> Third level with child</a>
|
||||
<ul>
|
||||
<li><a href="#"><i class="icon-html5"></i> Fourth level</a></li>
|
||||
<li><a href="#"><i class="icon-css3"></i> Fourth level</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#"><i class="icon-windows"></i> Third level</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#"><i class="icon-chrome"></i> Second level</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<!-- /layout -->
|
||||
|
||||
<!-- Data visualization -->
|
||||
<li class="navigation-header"><span>Data visualization</span> <i class="icon-menu" title="Data visualization"></i></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-graph"></i> <span>Echarts library</span></a>
|
||||
<ul>
|
||||
<li><a href="echarts_lines_areas.html">Lines and areas</a></li>
|
||||
<li><a href="echarts_columns_waterfalls.html">Columns and waterfalls</a></li>
|
||||
<li><a href="echarts_bars_tornados.html">Bars and tornados</a></li>
|
||||
<li><a href="echarts_scatter.html">Scatter charts</a></li>
|
||||
<li><a href="echarts_pies_donuts.html">Pies and donuts</a></li>
|
||||
<li><a href="echarts_funnels_chords.html">Funnels and chords</a></li>
|
||||
<li><a href="echarts_candlesticks_others.html">Candlesticks and others</a></li>
|
||||
<li><a href="echarts_combinations.html">Chart combinations</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-statistics"></i> <span>D3 library</span></a>
|
||||
<ul>
|
||||
<li><a href="d3_lines_basic.html">Simple lines</a></li>
|
||||
<li><a href="d3_lines_advanced.html">Advanced lines</a></li>
|
||||
<li><a href="d3_bars_basic.html">Simple bars</a></li>
|
||||
<li><a href="d3_bars_advanced.html">Advanced bars</a></li>
|
||||
<li><a href="d3_pies.html">Pie charts</a></li>
|
||||
<li><a href="d3_circle_diagrams.html">Circle diagrams</a></li>
|
||||
<li><a href="d3_tree.html">Tree layout</a></li>
|
||||
<li><a href="d3_other.html">Other charts</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-stats-dots"></i> <span>Dimple library</span></a>
|
||||
<ul>
|
||||
<li>
|
||||
<a href="#">Line charts</a>
|
||||
<ul>
|
||||
<li><a href="dimple_lines_horizontal.html">Horizontal orientation</a></li>
|
||||
<li><a href="dimple_lines_vertical.html">Vertical orientation</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#">Bar charts</a>
|
||||
<ul>
|
||||
<li><a href="dimple_bars_horizontal.html">Horizontal orientation</a></li>
|
||||
<li><a href="dimple_bars_vertical.html">Vertical orientation</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#">Area charts</a>
|
||||
<ul>
|
||||
<li><a href="dimple_area_horizontal.html">Horizontal orientation</a></li>
|
||||
<li><a href="dimple_area_vertical.html">Vertical orientation</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#">Step charts</a>
|
||||
<ul>
|
||||
<li><a href="dimple_step_horizontal.html">Horizontal orientation</a></li>
|
||||
<li><a href="dimple_step_vertical.html">Vertical orientation</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="dimple_pies.html">Pie charts</a></li>
|
||||
<li><a href="dimple_rings.html">Ring charts</a></li>
|
||||
<li><a href="dimple_scatter.html">Scatter charts</a></li>
|
||||
<li><a href="dimple_bubble.html">Bubble charts</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-stats-bars"></i> <span>C3 library</span></a>
|
||||
<ul>
|
||||
<li><a href="c3_lines_areas.html">Lines and areas</a></li>
|
||||
<li><a href="c3_bars_pies.html">Bars and pies</a></li>
|
||||
<li><a href="c3_advanced.html">Advanced examples</a></li>
|
||||
<li><a href="c3_axis.html">Chart axis</a></li>
|
||||
<li><a href="c3_grid.html">Grid options</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-google"></i> <span>Google visualization</span></a>
|
||||
<ul>
|
||||
<li><a href="google_lines.html">Line charts</a></li>
|
||||
<li><a href="google_bars.html">Bar charts</a></li>
|
||||
<li><a href="google_pies.html">Pie charts</a></li>
|
||||
<li><a href="google_scatter_bubble.html">Bubble & scatter charts</a></li>
|
||||
<li><a href="google_other.html">Other charts</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-map5"></i> <span>Maps integration</span></a>
|
||||
<ul>
|
||||
<li>
|
||||
<a href="#">Google maps</a>
|
||||
<ul>
|
||||
<li><a href="maps_google_basic.html">Basics</a></li>
|
||||
<li><a href="maps_google_controls.html">Controls</a></li>
|
||||
<li><a href="maps_google_markers.html">Markers</a></li>
|
||||
<li><a href="maps_google_drawings.html">Map drawings</a></li>
|
||||
<li><a href="maps_google_layers.html">Layers</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="maps_vector.html">Vector maps</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<!-- /data visualization -->
|
||||
|
||||
<!-- Extensions -->
|
||||
<li class="navigation-header"><span>Extensions</span> <i class="icon-menu" title="Extensions"></i></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-puzzle4"></i> <span>Extensions</span></a>
|
||||
<ul>
|
||||
<li><a href="extension_image_cropper.html">Image cropper</a></li>
|
||||
<li><a href="extension_blockui.html">Block UI</a></li>
|
||||
<li><a href="extension_dnd.html">Drag and drop</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-popout"></i> <span>JQuery UI</span></a>
|
||||
<ul>
|
||||
<li><a href="jqueryui_interactions.html">Interactions</a></li>
|
||||
<li><a href="jqueryui_forms.html">Forms</a></li>
|
||||
<li><a href="jqueryui_components.html">Components</a></li>
|
||||
<li><a href="jqueryui_sliders.html">Sliders</a></li>
|
||||
<li><a href="jqueryui_navigation.html">Navigation</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-upload"></i> <span>File uploaders</span></a>
|
||||
<ul>
|
||||
<li><a href="uploader_plupload.html">Plupload</a></li>
|
||||
<li><a href="uploader_bootstrap.html">Bootstrap file uploader</a></li>
|
||||
<li><a href="uploader_dropzone.html">Dropzone</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-calendar3"></i> <span>Event calendars</span></a>
|
||||
<ul>
|
||||
<li><a href="extension_fullcalendar_views.html">Basic views</a></li>
|
||||
<li><a href="extension_fullcalendar_styling.html">Event styling</a></li>
|
||||
<li><a href="extension_fullcalendar_formats.html">Language and time</a></li>
|
||||
<li><a href="extension_fullcalendar_advanced.html">Advanced usage</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-sphere"></i> <span>Internationalization</span></a>
|
||||
<ul>
|
||||
<li><a href="internationalization_switch_direct.html">Direct translation</a></li>
|
||||
<li><a href="internationalization_switch_query.html">Querystring parameter</a></li>
|
||||
<li><a href="internationalization_on_init.html">Set language on init</a></li>
|
||||
<li><a href="internationalization_after_init.html">Set language after init</a></li>
|
||||
<li><a href="internationalization_fallback.html">Language fallback</a></li>
|
||||
<li><a href="internationalization_callbacks.html">Callbacks</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<!-- /extensions -->
|
||||
|
||||
<!-- Tables -->
|
||||
<li class="navigation-header"><span>Tables</span> <i class="icon-menu" title="Tables"></i></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-table2"></i> <span>Basic tables</span></a>
|
||||
<ul>
|
||||
<li><a href="table_basic.html">Basic examples</a></li>
|
||||
<li><a href="table_sizing.html">Table sizing</a></li>
|
||||
<li><a href="table_borders.html">Table borders</a></li>
|
||||
<li><a href="table_styling.html">Table styling</a></li>
|
||||
<li><a href="table_elements.html">Table elements</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-grid7"></i> <span>Data tables</span></a>
|
||||
<ul>
|
||||
<li><a href="datatable_basic.html">Basic initialization</a></li>
|
||||
<li><a href="datatable_styling.html">Basic styling</a></li>
|
||||
<li><a href="datatable_advanced.html">Advanced examples</a></li>
|
||||
<li><a href="datatable_sorting.html">Sorting options</a></li>
|
||||
<li><a href="datatable_api.html">Using API</a></li>
|
||||
<li><a href="datatable_data_sources.html">Data sources</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-alignment-unalign"></i> <span>Data tables extensions</span></a>
|
||||
<ul>
|
||||
<li><a href="datatable_extension_reorder.html">Columns reorder</a></li>
|
||||
<li><a href="datatable_extension_row_reorder.html">Row reorder</a></li>
|
||||
<li><a href="datatable_extension_fixed_columns.html">Fixed columns</a></li>
|
||||
<li><a href="datatable_extension_fixed_header.html">Fixed header</a></li>
|
||||
<li><a href="datatable_extension_autofill.html">Auto fill</a></li>
|
||||
<li><a href="datatable_extension_key_table.html">Key table</a></li>
|
||||
<li><a href="datatable_extension_scroller.html">Scroller</a></li>
|
||||
<li><a href="datatable_extension_select.html">Select</a></li>
|
||||
<li>
|
||||
<a href="#">Buttons</a>
|
||||
<ul>
|
||||
<li><a href="datatable_extension_buttons_init.html">Initialization</a></li>
|
||||
<li><a href="datatable_extension_buttons_flash.html">Flash buttons</a></li>
|
||||
<li><a href="datatable_extension_buttons_print.html">Print buttons</a></li>
|
||||
<li><a href="datatable_extension_buttons_html5.html">HTML5 buttons</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
<li><a href="datatable_extension_colvis.html">Columns visibility</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-file-spreadsheet"></i> <span>Handsontable</span></a>
|
||||
<ul>
|
||||
<li><a href="handsontable_basic.html">Basic configuration</a></li>
|
||||
<li><a href="handsontable_advanced.html">Advanced setup</a></li>
|
||||
<li><a href="handsontable_cols.html">Column features</a></li>
|
||||
<li><a href="handsontable_cells.html">Cell features</a></li>
|
||||
<li><a href="handsontable_types.html">Basic cell types</a></li>
|
||||
<li><a href="handsontable_custom_checks.html">Custom & checkboxes</a></li>
|
||||
<li><a href="handsontable_ac_password.html">Autocomplete & password</a></li>
|
||||
<li><a href="handsontable_search.html">Search</a></li>
|
||||
<li><a href="handsontable_context.html">Context menu</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-versions"></i> <span>Responsive options</span></a>
|
||||
<ul>
|
||||
<li><a href="table_responsive.html">Responsive basic tables</a></li>
|
||||
<li><a href="datatable_responsive.html">Responsive data tables</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<!-- /tables -->
|
||||
|
||||
<!-- Page kits -->
|
||||
<li class="navigation-header"><span>Page kits</span> <i class="icon-menu" title="Page kits"></i></li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-task"></i> <span>Task manager</span></a>
|
||||
<ul>
|
||||
<li><a href="task_manager_grid.html">Task grid</a></li>
|
||||
<li><a href="task_manager_list.html">Task list</a></li>
|
||||
<li><a href="task_manager_detailed.html">Task detailed</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-cash3"></i> <span>Invoicing</span></a>
|
||||
<ul>
|
||||
<li><a href="invoice_template.html">Invoice template</a></li>
|
||||
<li><a href="invoice_grid.html">Invoice grid</a></li>
|
||||
<li><a href="invoice_archive.html">Invoice archive</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-people"></i> <span>User pages</span></a>
|
||||
<ul>
|
||||
<li><a href="user_pages_cards.html">User cards</a></li>
|
||||
<li><a href="user_pages_list.html">User list</a></li>
|
||||
<li><a href="user_pages_profile.html">Simple profile</a></li>
|
||||
<li><a href="user_pages_profile_cover.html">Profile with cover</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-user-plus"></i> <span>Login & registration</span></a>
|
||||
<ul>
|
||||
<li><a href="login_simple.html">Simple login</a></li>
|
||||
<li><a href="login_advanced.html">More login info</a></li>
|
||||
<li><a href="login_registration.html">Simple registration</a></li>
|
||||
<li><a href="login_registration_advanced.html">More registration info</a></li>
|
||||
<li><a href="login_unlock.html">Unlock user</a></li>
|
||||
<li><a href="login_password_recover.html">Reset password</a></li>
|
||||
<li><a href="login_hide_navbar.html">Hide navbar</a></li>
|
||||
<li><a href="login_transparent.html">Transparent box</a></li>
|
||||
<li><a href="login_background.html">Background option</a></li>
|
||||
<li><a href="login_validation.html">With validation</a></li>
|
||||
<li><a href="login_tabbed.html">Tabbed form</a></li>
|
||||
<li><a href="login_modals.html">Inside modals</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-magazine"></i> <span>Timelines</span></a>
|
||||
<ul>
|
||||
<li><a href="timelines_left.html">Left timeline</a></li>
|
||||
<li><a href="timelines_right.html">Right timeline</a></li>
|
||||
<li><a href="timelines_center.html">Centered timeline</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-lifebuoy"></i> <span>Support</span></a>
|
||||
<ul>
|
||||
<li><a href="support_conversation_layouts.html">Conversation layouts</a></li>
|
||||
<li><a href="support_conversation_options.html">Conversation options</a></li>
|
||||
<li><a href="support_knowledgebase.html">Knowledgebase</a></li>
|
||||
<li><a href="support_faq.html">FAQ page</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-search4"></i> <span>Search</span></a>
|
||||
<ul>
|
||||
<li><a href="search_basic.html">Basic search results</a></li>
|
||||
<li><a href="search_users.html">User search results</a></li>
|
||||
<li><a href="search_images.html">Image search results</a></li>
|
||||
<li><a href="search_videos.html">Video search results</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-images2"></i> <span>Gallery</span></a>
|
||||
<ul>
|
||||
<li><a href="gallery_grid.html">Media grid</a></li>
|
||||
<li><a href="gallery_titles.html">Media with titles</a></li>
|
||||
<li><a href="gallery_description.html">Media with description</a></li>
|
||||
<li><a href="gallery_library.html">Media library</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"><i class="icon-warning"></i> <span>Error pages</span></a>
|
||||
<ul>
|
||||
<li><a href="error_403.html">Error 403</a></li>
|
||||
<li><a href="error_404.html">Error 404</a></li>
|
||||
<li><a href="error_405.html">Error 405</a></li>
|
||||
<li><a href="error_500.html">Error 500</a></li>
|
||||
<li><a href="error_503.html">Error 503</a></li>
|
||||
<li><a href="error_offline.html">Offline page</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<!-- /page kits -->
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /main navigation -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<!-- /main sidebar -->
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user