├── .gitignore ├── BackgroundProcess.php ├── LICENSE ├── README.md └── examples ├── README.md ├── basic ├── index.php └── process.php ├── codeigniter3 ├── .editorconfig ├── .gitignore ├── application │ ├── .htaccess │ ├── cache │ │ └── index.html │ ├── config │ │ ├── autoload.php │ │ ├── config.php │ │ ├── constants.php │ │ ├── database.php │ │ ├── doctypes.php │ │ ├── foreign_chars.php │ │ ├── hooks.php │ │ ├── index.html │ │ ├── memcached.php │ │ ├── migration.php │ │ ├── mimes.php │ │ ├── profiler.php │ │ ├── routes.php │ │ ├── smileys.php │ │ └── user_agents.php │ ├── controllers │ │ ├── Background.php │ │ ├── Welcome.php │ │ └── index.html │ ├── core │ │ └── index.html │ ├── helpers │ │ └── index.html │ ├── hooks │ │ └── index.html │ ├── index.html │ ├── language │ │ ├── english │ │ │ └── index.html │ │ └── index.html │ ├── libraries │ │ ├── BackgroundProcess.php │ │ └── index.html │ ├── logs │ │ └── index.html │ ├── models │ │ └── index.html │ ├── third_party │ │ └── index.html │ └── views │ │ ├── errors │ │ ├── cli │ │ │ ├── error_404.php │ │ │ ├── error_db.php │ │ │ ├── error_exception.php │ │ │ ├── error_general.php │ │ │ ├── error_php.php │ │ │ └── index.html │ │ ├── html │ │ │ ├── error_404.php │ │ │ ├── error_db.php │ │ │ ├── error_exception.php │ │ │ ├── error_general.php │ │ │ ├── error_php.php │ │ │ └── index.html │ │ └── index.html │ │ ├── index.html │ │ └── welcome_message.php ├── composer.json ├── contributing.md ├── index.php ├── license.txt ├── readme.rst ├── system │ ├── .htaccess │ ├── core │ │ ├── Benchmark.php │ │ ├── CodeIgniter.php │ │ ├── Common.php │ │ ├── Config.php │ │ ├── Controller.php │ │ ├── Exceptions.php │ │ ├── Hooks.php │ │ ├── Input.php │ │ ├── Lang.php │ │ ├── Loader.php │ │ ├── Log.php │ │ ├── Model.php │ │ ├── Output.php │ │ ├── Router.php │ │ ├── Security.php │ │ ├── URI.php │ │ ├── Utf8.php │ │ ├── compat │ │ │ ├── hash.php │ │ │ ├── index.html │ │ │ ├── mbstring.php │ │ │ ├── password.php │ │ │ └── standard.php │ │ └── index.html │ ├── database │ │ ├── DB.php │ │ ├── DB_cache.php │ │ ├── DB_driver.php │ │ ├── DB_forge.php │ │ ├── DB_query_builder.php │ │ ├── DB_result.php │ │ ├── DB_utility.php │ │ ├── drivers │ │ │ ├── cubrid │ │ │ │ ├── cubrid_driver.php │ │ │ │ ├── cubrid_forge.php │ │ │ │ ├── cubrid_result.php │ │ │ │ ├── cubrid_utility.php │ │ │ │ └── index.html │ │ │ ├── ibase │ │ │ │ ├── ibase_driver.php │ │ │ │ ├── ibase_forge.php │ │ │ │ ├── ibase_result.php │ │ │ │ ├── ibase_utility.php │ │ │ │ └── index.html │ │ │ ├── index.html │ │ │ ├── mssql │ │ │ │ ├── index.html │ │ │ │ ├── mssql_driver.php │ │ │ │ ├── mssql_forge.php │ │ │ │ ├── mssql_result.php │ │ │ │ └── mssql_utility.php │ │ │ ├── mysql │ │ │ │ ├── index.html │ │ │ │ ├── mysql_driver.php │ │ │ │ ├── mysql_forge.php │ │ │ │ ├── mysql_result.php │ │ │ │ └── mysql_utility.php │ │ │ ├── mysqli │ │ │ │ ├── index.html │ │ │ │ ├── mysqli_driver.php │ │ │ │ ├── mysqli_forge.php │ │ │ │ ├── mysqli_result.php │ │ │ │ └── mysqli_utility.php │ │ │ ├── oci8 │ │ │ │ ├── index.html │ │ │ │ ├── oci8_driver.php │ │ │ │ ├── oci8_forge.php │ │ │ │ ├── oci8_result.php │ │ │ │ └── oci8_utility.php │ │ │ ├── odbc │ │ │ │ ├── index.html │ │ │ │ ├── odbc_driver.php │ │ │ │ ├── odbc_forge.php │ │ │ │ ├── odbc_result.php │ │ │ │ └── odbc_utility.php │ │ │ ├── pdo │ │ │ │ ├── index.html │ │ │ │ ├── pdo_driver.php │ │ │ │ ├── pdo_forge.php │ │ │ │ ├── pdo_result.php │ │ │ │ ├── pdo_utility.php │ │ │ │ └── subdrivers │ │ │ │ │ ├── index.html │ │ │ │ │ ├── pdo_4d_driver.php │ │ │ │ │ ├── pdo_4d_forge.php │ │ │ │ │ ├── pdo_cubrid_driver.php │ │ │ │ │ ├── pdo_cubrid_forge.php │ │ │ │ │ ├── pdo_dblib_driver.php │ │ │ │ │ ├── pdo_dblib_forge.php │ │ │ │ │ ├── pdo_firebird_driver.php │ │ │ │ │ ├── pdo_firebird_forge.php │ │ │ │ │ ├── pdo_ibm_driver.php │ │ │ │ │ ├── pdo_ibm_forge.php │ │ │ │ │ ├── pdo_informix_driver.php │ │ │ │ │ ├── pdo_informix_forge.php │ │ │ │ │ ├── pdo_mysql_driver.php │ │ │ │ │ ├── pdo_mysql_forge.php │ │ │ │ │ ├── pdo_oci_driver.php │ │ │ │ │ ├── pdo_oci_forge.php │ │ │ │ │ ├── pdo_odbc_driver.php │ │ │ │ │ ├── pdo_odbc_forge.php │ │ │ │ │ ├── pdo_pgsql_driver.php │ │ │ │ │ ├── pdo_pgsql_forge.php │ │ │ │ │ ├── pdo_sqlite_driver.php │ │ │ │ │ ├── pdo_sqlite_forge.php │ │ │ │ │ ├── pdo_sqlsrv_driver.php │ │ │ │ │ └── pdo_sqlsrv_forge.php │ │ │ ├── postgre │ │ │ │ ├── index.html │ │ │ │ ├── postgre_driver.php │ │ │ │ ├── postgre_forge.php │ │ │ │ ├── postgre_result.php │ │ │ │ └── postgre_utility.php │ │ │ ├── sqlite │ │ │ │ ├── index.html │ │ │ │ ├── sqlite_driver.php │ │ │ │ ├── sqlite_forge.php │ │ │ │ ├── sqlite_result.php │ │ │ │ └── sqlite_utility.php │ │ │ ├── sqlite3 │ │ │ │ ├── index.html │ │ │ │ ├── sqlite3_driver.php │ │ │ │ ├── sqlite3_forge.php │ │ │ │ ├── sqlite3_result.php │ │ │ │ └── sqlite3_utility.php │ │ │ └── sqlsrv │ │ │ │ ├── index.html │ │ │ │ ├── sqlsrv_driver.php │ │ │ │ ├── sqlsrv_forge.php │ │ │ │ ├── sqlsrv_result.php │ │ │ │ └── sqlsrv_utility.php │ │ └── index.html │ ├── fonts │ │ ├── index.html │ │ └── texb.ttf │ ├── helpers │ │ ├── array_helper.php │ │ ├── captcha_helper.php │ │ ├── cookie_helper.php │ │ ├── date_helper.php │ │ ├── directory_helper.php │ │ ├── download_helper.php │ │ ├── email_helper.php │ │ ├── file_helper.php │ │ ├── form_helper.php │ │ ├── html_helper.php │ │ ├── index.html │ │ ├── inflector_helper.php │ │ ├── language_helper.php │ │ ├── number_helper.php │ │ ├── path_helper.php │ │ ├── security_helper.php │ │ ├── smiley_helper.php │ │ ├── string_helper.php │ │ ├── text_helper.php │ │ ├── typography_helper.php │ │ ├── url_helper.php │ │ └── xml_helper.php │ ├── index.html │ ├── language │ │ ├── english │ │ │ ├── calendar_lang.php │ │ │ ├── date_lang.php │ │ │ ├── db_lang.php │ │ │ ├── email_lang.php │ │ │ ├── form_validation_lang.php │ │ │ ├── ftp_lang.php │ │ │ ├── imglib_lang.php │ │ │ ├── index.html │ │ │ ├── migration_lang.php │ │ │ ├── number_lang.php │ │ │ ├── pagination_lang.php │ │ │ ├── profiler_lang.php │ │ │ ├── unit_test_lang.php │ │ │ └── upload_lang.php │ │ └── index.html │ └── libraries │ │ ├── Cache │ │ ├── Cache.php │ │ ├── drivers │ │ │ ├── Cache_apc.php │ │ │ ├── Cache_dummy.php │ │ │ ├── Cache_file.php │ │ │ ├── Cache_memcached.php │ │ │ ├── Cache_redis.php │ │ │ ├── Cache_wincache.php │ │ │ └── index.html │ │ └── index.html │ │ ├── Calendar.php │ │ ├── Cart.php │ │ ├── Driver.php │ │ ├── Email.php │ │ ├── Encrypt.php │ │ ├── Encryption.php │ │ ├── Form_validation.php │ │ ├── Ftp.php │ │ ├── Image_lib.php │ │ ├── Javascript.php │ │ ├── Javascript │ │ ├── Jquery.php │ │ └── index.html │ │ ├── Migration.php │ │ ├── Pagination.php │ │ ├── Parser.php │ │ ├── Profiler.php │ │ ├── Session │ │ ├── Session.php │ │ ├── SessionHandlerInterface.php │ │ ├── Session_driver.php │ │ ├── drivers │ │ │ ├── Session_database_driver.php │ │ │ ├── Session_files_driver.php │ │ │ ├── Session_memcached_driver.php │ │ │ ├── Session_redis_driver.php │ │ │ └── index.html │ │ └── index.html │ │ ├── Table.php │ │ ├── Trackback.php │ │ ├── Typography.php │ │ ├── Unit_test.php │ │ ├── Upload.php │ │ ├── User_agent.php │ │ ├── Xmlrpc.php │ │ ├── Xmlrpcs.php │ │ ├── Zip.php │ │ └── index.html └── user_guide │ ├── .buildinfo │ ├── DCO.html │ ├── _downloads │ └── ELDocs.tmbundle.zip │ ├── _images │ ├── appflowchart.gif │ └── smile.gif │ ├── _static │ ├── ajax-loader.gif │ ├── basic.css │ ├── ci-icon.ico │ ├── comment-bright.png │ ├── comment-close.png │ ├── comment.png │ ├── css │ │ ├── badge_only.css │ │ ├── citheme.css │ │ └── theme.css │ ├── doctools.js │ ├── down-pressed.png │ ├── down.png │ ├── file.png │ ├── fonts │ │ ├── FontAwesome.otf │ │ ├── fontawesome-webfont.eot │ │ ├── fontawesome-webfont.svg │ │ ├── fontawesome-webfont.ttf │ │ └── fontawesome-webfont.woff │ ├── images │ │ └── ci-icon.ico │ ├── jquery-3.1.0.js │ ├── jquery.js │ ├── js │ │ ├── oldtheme.js │ │ └── theme.js │ ├── minus.png │ ├── plus.png │ ├── pygments.css │ ├── searchtools.js │ ├── underscore-1.3.1.js │ ├── underscore.js │ ├── up-pressed.png │ ├── up.png │ └── websupport.js │ ├── changelog.html │ ├── contributing │ └── index.html │ ├── database │ ├── caching.html │ ├── call_function.html │ ├── configuration.html │ ├── connecting.html │ ├── db_driver_reference.html │ ├── examples.html │ ├── forge.html │ ├── helpers.html │ ├── index.html │ ├── metadata.html │ ├── queries.html │ ├── query_builder.html │ ├── results.html │ ├── transactions.html │ └── utilities.html │ ├── documentation │ └── index.html │ ├── general │ ├── alternative_php.html │ ├── ancillary_classes.html │ ├── autoloader.html │ ├── caching.html │ ├── cli.html │ ├── common_functions.html │ ├── compatibility_functions.html │ ├── controllers.html │ ├── core_classes.html │ ├── creating_drivers.html │ ├── creating_libraries.html │ ├── credits.html │ ├── drivers.html │ ├── environments.html │ ├── errors.html │ ├── helpers.html │ ├── hooks.html │ ├── index.html │ ├── libraries.html │ ├── managing_apps.html │ ├── models.html │ ├── profiling.html │ ├── requirements.html │ ├── reserved_names.html │ ├── routing.html │ ├── security.html │ ├── styleguide.html │ ├── urls.html │ ├── views.html │ └── welcome.html │ ├── genindex.html │ ├── helpers │ ├── array_helper.html │ ├── captcha_helper.html │ ├── cookie_helper.html │ ├── date_helper.html │ ├── directory_helper.html │ ├── download_helper.html │ ├── email_helper.html │ ├── file_helper.html │ ├── form_helper.html │ ├── html_helper.html │ ├── index.html │ ├── inflector_helper.html │ ├── language_helper.html │ ├── number_helper.html │ ├── path_helper.html │ ├── security_helper.html │ ├── smiley_helper.html │ ├── string_helper.html │ ├── text_helper.html │ ├── typography_helper.html │ ├── url_helper.html │ └── xml_helper.html │ ├── index.html │ ├── installation │ ├── downloads.html │ ├── index.html │ ├── troubleshooting.html │ ├── upgrade_120.html │ ├── upgrade_130.html │ ├── upgrade_131.html │ ├── upgrade_132.html │ ├── upgrade_133.html │ ├── upgrade_140.html │ ├── upgrade_141.html │ ├── upgrade_150.html │ ├── upgrade_152.html │ ├── upgrade_153.html │ ├── upgrade_154.html │ ├── upgrade_160.html │ ├── upgrade_161.html │ ├── upgrade_162.html │ ├── upgrade_163.html │ ├── upgrade_170.html │ ├── upgrade_171.html │ ├── upgrade_172.html │ ├── upgrade_200.html │ ├── upgrade_201.html │ ├── upgrade_202.html │ ├── upgrade_203.html │ ├── upgrade_210.html │ ├── upgrade_211.html │ ├── upgrade_212.html │ ├── upgrade_213.html │ ├── upgrade_214.html │ ├── upgrade_220.html │ ├── upgrade_221.html │ ├── upgrade_222.html │ ├── upgrade_223.html │ ├── upgrade_300.html │ ├── upgrade_301.html │ ├── upgrade_302.html │ ├── upgrade_303.html │ ├── upgrade_304.html │ ├── upgrade_305.html │ ├── upgrade_306.html │ ├── upgrade_310.html │ ├── upgrade_311.html │ ├── upgrade_3110.html │ ├── upgrade_3111.html │ ├── upgrade_312.html │ ├── upgrade_313.html │ ├── upgrade_314.html │ ├── upgrade_315.html │ ├── upgrade_316.html │ ├── upgrade_317.html │ ├── upgrade_318.html │ ├── upgrade_319.html │ ├── upgrade_b11.html │ └── upgrading.html │ ├── libraries │ ├── benchmark.html │ ├── caching.html │ ├── calendar.html │ ├── cart.html │ ├── config.html │ ├── email.html │ ├── encrypt.html │ ├── encryption.html │ ├── file_uploading.html │ ├── form_validation.html │ ├── ftp.html │ ├── image_lib.html │ ├── index.html │ ├── input.html │ ├── javascript.html │ ├── language.html │ ├── loader.html │ ├── migration.html │ ├── output.html │ ├── pagination.html │ ├── parser.html │ ├── security.html │ ├── sessions.html │ ├── table.html │ ├── trackback.html │ ├── typography.html │ ├── unit_testing.html │ ├── uri.html │ ├── user_agent.html │ ├── xmlrpc.html │ └── zip.html │ ├── license.html │ ├── objects.inv │ ├── overview │ ├── appflow.html │ ├── at_a_glance.html │ ├── features.html │ ├── getting_started.html │ ├── goals.html │ ├── index.html │ └── mvc.html │ ├── search.html │ ├── searchindex.js │ └── tutorial │ ├── conclusion.html │ ├── create_news_items.html │ ├── index.html │ ├── news_section.html │ └── static_pages.html └── codeigniter4 ├── .gitignore ├── README.md ├── app ├── .htaccess ├── Common.php ├── Config │ ├── App.php │ ├── Autoload.php │ ├── Boot │ │ ├── development.php │ │ ├── production.php │ │ └── testing.php │ ├── Cache.php │ ├── Constants.php │ ├── ContentSecurityPolicy.php │ ├── Database.php │ ├── DocTypes.php │ ├── Email.php │ ├── Encryption.php │ ├── Events.php │ ├── Exceptions.php │ ├── Filters.php │ ├── ForeignCharacters.php │ ├── Format.php │ ├── Honeypot.php │ ├── Images.php │ ├── Kint.php │ ├── Logger.php │ ├── Migrations.php │ ├── Mimes.php │ ├── Modules.php │ ├── Pager.php │ ├── Paths.php │ ├── Routes.php │ ├── Services.php │ ├── Toolbar.php │ ├── UserAgents.php │ ├── Validation.php │ └── View.php ├── Controllers │ ├── Background.php │ ├── BackgroundRunner.php │ ├── BaseController.php │ └── Home.php ├── Database │ ├── Migrations │ │ └── .gitkeep │ └── Seeds │ │ └── .gitkeep ├── Filters │ └── .gitkeep ├── Helpers │ └── .gitkeep ├── Language │ └── .gitkeep ├── Libraries │ ├── .gitkeep │ └── BackgroundProcess.php ├── Models │ └── .gitkeep ├── ThirdParty │ └── .gitkeep ├── Views │ ├── errors │ │ ├── cli │ │ │ ├── error_404.php │ │ │ ├── error_exception.php │ │ │ └── production.php │ │ └── html │ │ │ ├── debug.css │ │ │ ├── debug.js │ │ │ ├── error_404.php │ │ │ ├── error_exception.php │ │ │ └── production.php │ └── welcome_message.php └── index.html ├── builds ├── composer.json ├── env ├── license.txt ├── phpunit.xml.dist ├── public ├── .htaccess ├── favicon.ico ├── index.php ├── page_control │ └── log │ │ └── log_background_process.log └── robots.txt ├── spark ├── tests ├── README.md ├── _support │ ├── Database │ │ ├── Migrations │ │ │ └── 2020-02-22-222222_example_migration.php │ │ └── Seeds │ │ │ └── ExampleSeeder.php │ ├── DatabaseTestCase.php │ ├── Libraries │ │ └── ConfigReader.php │ ├── Models │ │ └── ExampleModel.php │ └── SessionTestCase.php ├── database │ └── ExampleDatabaseTest.php ├── session │ └── ExampleSessionTest.php └── unit │ └── HealthTest.php └── writable ├── .htaccess ├── cache └── index.html ├── logs └── index.html ├── session └── index.html └── uploads └── index.html /.gitignore: -------------------------------------------------------------------------------- 1 | **vendor** -------------------------------------------------------------------------------- /BackgroundProcess.php: -------------------------------------------------------------------------------- 1 | command = $cmd; 25 | $this->isOutPut = $isOutPut; 26 | $this->do_process(); 27 | } else { 28 | $this->msg['error'] = "Please Provide the Command Here"; 29 | } 30 | } 31 | 32 | public function setCmd($cmd) 33 | { 34 | $this->command = $cmd; 35 | return true; 36 | } 37 | 38 | public function setProcessId($pid) 39 | { 40 | $this->pid = $pid; 41 | return true; 42 | } 43 | 44 | public function getProcessId() 45 | { 46 | return $this->pid; 47 | } 48 | public function status() 49 | { 50 | $command = 'ps -p ' . $this->pid; 51 | exec($command, $op); 52 | if (!isset($op[1])) return false; 53 | else return true; 54 | } 55 | 56 | public function showAllProcess() 57 | { 58 | $command = 'ps -ef ' . $this->pid; 59 | exec($command, $op); 60 | return $op; 61 | } 62 | 63 | public function start($isOutPut = null) 64 | { 65 | $this->isOutPut = $isOutPut; 66 | if ($this->command != '') 67 | $this->do_process(); 68 | else return true; 69 | } 70 | 71 | public function stop() 72 | { 73 | $command = 'kill ' . $this->pid; 74 | exec($command); 75 | if ($this->status() == false) return true; 76 | else return false; 77 | } 78 | public function get_log_paths() 79 | { 80 | return "Log path: \nstdout: /tmp/out_" . $this->random . "\nstderr: /tmp/error_out_" . $this->random . "\n"; 81 | } 82 | public function create_command_string() 83 | { 84 | $outPath = ' > /dev/null 2>&1'; 85 | if ($this->isOutPut) { 86 | $this->random = rand(5, 15); 87 | $outPath = ' 1> /tmp/out_' . $this->random . ' 2> /tmp/error_out_' . $this->random; 88 | } 89 | return 'nohup ' . $this->command . $outPath . ' & echo $!'; 90 | } 91 | //do the process in background 92 | public function do_process() 93 | { 94 | $command = $this->create_command_string(); 95 | exec($command, $process); 96 | $this->pid = (int) $process[0]; 97 | } 98 | 99 | /* 100 | *To execute a PHP url on background you have to do the following things. 101 | * $process=new BackgroundProcess("curl -s -o /log/xyz.log -d param_key="); 102 | */ 103 | } 104 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 pandasanjay 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /examples/README.md: -------------------------------------------------------------------------------- 1 | # Codeigniter4 example how to run. 2 | 3 | ```bash 4 | # Docker command 5 | docker run -p 8080:8080 -v ${PWD}:/app -it composer bash 6 | 7 | # Inside docker 8 | $ apk add icu-dev 9 | $ docker-php-ext-install intl 10 | 11 | # Inside root of the examples/codeigniter4 12 | $ composer update 13 | $ php spark serve 14 | 15 | # Run this curl command to execute the background job in other tab 16 | $ curl http://localhost:8080/backgroundrunner/ 17 | 18 | ``` 19 | 20 | # Codeigniter3 example how to run 21 | 22 | ```bash 23 | # Docker command 24 | $ docker run -p 8086:80 -v ${PWD}:/www -it cswl/xampp bash 25 | 26 | # Inside root of the examples/codeigniter4 27 | $ composer update 28 | 29 | $ rm /opt/lampp/lib/libldap_r-2.4.so.2 30 | $ ln -s /usr/lib/x86_64-linux-gnu/libldap_r-2.4.so.2.10.8 /opt/lampp/lib/libldap_r-2.4.so.2 31 | 32 | $ rm /opt/lampp/lib/libldap_r-2.4.so.2 33 | $ ln -s /usr/lib/x86_64-linux-gnu/libldap_r-2.4.so.2.10.8 /opt/lampp/lib/libldap_r-2.4.so.2 34 | 35 | $ rm /opt/lampp/lib/liblber-2.4.so.2 36 | $ ln -l /usr/lib/x86_64-linux-gnu/liblber-2.4.so.2.10.8 /opt/lampp/lib/liblber-2.4.so.2 37 | 38 | # Run this curl command to execute the background job in other tab 39 | $ curl http://localhost/www/index.php/welcome/background 40 | ``` 41 | -------------------------------------------------------------------------------- /examples/basic/index.php: -------------------------------------------------------------------------------- 1 | getProcessId(); 8 | 9 | echo $proc->get_log_paths(); 10 | 11 | echo "Process id: " . $pid . "\n"; 12 | -------------------------------------------------------------------------------- /examples/basic/process.php: -------------------------------------------------------------------------------- 1 | 2 | Require all denied 3 | 4 | 5 | Deny from all 6 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/cache/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/config/doctypes.php: -------------------------------------------------------------------------------- 1 | '', 6 | 'xhtml1-strict' => '', 7 | 'xhtml1-trans' => '', 8 | 'xhtml1-frame' => '', 9 | 'xhtml-basic11' => '', 10 | 'html5' => '', 11 | 'html4-strict' => '', 12 | 'html4-trans' => '', 13 | 'html4-frame' => '', 14 | 'mathml1' => '', 15 | 'mathml2' => '', 16 | 'svg10' => '', 17 | 'svg11' => '', 18 | 'svg11-basic' => '', 19 | 'svg11-tiny' => '', 20 | 'xhtml-math-svg-xh' => '', 21 | 'xhtml-math-svg-sh' => '', 22 | 'xhtml-rdfa-1' => '', 23 | 'xhtml-rdfa-2' => '' 24 | ); 25 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/config/foreign_chars.php: -------------------------------------------------------------------------------- 1 | 'ae', 14 | '/ö|œ/' => 'oe', 15 | '/ü/' => 'ue', 16 | '/Ä/' => 'Ae', 17 | '/Ü/' => 'Ue', 18 | '/Ö/' => 'Oe', 19 | '/À|Á|Â|Ã|Ä|Å|Ǻ|Ā|Ă|Ą|Ǎ|Α|Ά|Ả|Ạ|Ầ|Ẫ|Ẩ|Ậ|Ằ|Ắ|Ẵ|Ẳ|Ặ|А/' => 'A', 20 | '/à|á|â|ã|å|ǻ|ā|ă|ą|ǎ|ª|α|ά|ả|ạ|ầ|ấ|ẫ|ẩ|ậ|ằ|ắ|ẵ|ẳ|ặ|а/' => 'a', 21 | '/Б/' => 'B', 22 | '/б/' => 'b', 23 | '/Ç|Ć|Ĉ|Ċ|Č/' => 'C', 24 | '/ç|ć|ĉ|ċ|č/' => 'c', 25 | '/Д|Δ/' => 'D', 26 | '/д|δ/' => 'd', 27 | '/Ð|Ď|Đ/' => 'Dj', 28 | '/ð|ď|đ/' => 'dj', 29 | '/È|É|Ê|Ë|Ē|Ĕ|Ė|Ę|Ě|Ε|Έ|Ẽ|Ẻ|Ẹ|Ề|Ế|Ễ|Ể|Ệ|Е|Э/' => 'E', 30 | '/è|é|ê|ë|ē|ĕ|ė|ę|ě|έ|ε|ẽ|ẻ|ẹ|ề|ế|ễ|ể|ệ|е|э/' => 'e', 31 | '/Ф/' => 'F', 32 | '/ф/' => 'f', 33 | '/Ĝ|Ğ|Ġ|Ģ|Γ|Г|Ґ/' => 'G', 34 | '/ĝ|ğ|ġ|ģ|γ|г|ґ/' => 'g', 35 | '/Ĥ|Ħ/' => 'H', 36 | '/ĥ|ħ/' => 'h', 37 | '/Ì|Í|Î|Ï|Ĩ|Ī|Ĭ|Ǐ|Į|İ|Η|Ή|Ί|Ι|Ϊ|Ỉ|Ị|И|Ы/' => 'I', 38 | '/ì|í|î|ï|ĩ|ī|ĭ|ǐ|į|ı|η|ή|ί|ι|ϊ|ỉ|ị|и|ы|ї/' => 'i', 39 | '/Ĵ/' => 'J', 40 | '/ĵ/' => 'j', 41 | '/Θ/' => 'TH', 42 | '/θ/' => 'th', 43 | '/Ķ|Κ|К/' => 'K', 44 | '/ķ|κ|к/' => 'k', 45 | '/Ĺ|Ļ|Ľ|Ŀ|Ł|Λ|Л/' => 'L', 46 | '/ĺ|ļ|ľ|ŀ|ł|λ|л/' => 'l', 47 | '/М/' => 'M', 48 | '/м/' => 'm', 49 | '/Ñ|Ń|Ņ|Ň|Ν|Н/' => 'N', 50 | '/ñ|ń|ņ|ň|ʼn|ν|н/' => 'n', 51 | '/Ò|Ó|Ô|Õ|Ō|Ŏ|Ǒ|Ő|Ơ|Ø|Ǿ|Ο|Ό|Ω|Ώ|Ỏ|Ọ|Ồ|Ố|Ỗ|Ổ|Ộ|Ờ|Ớ|Ỡ|Ở|Ợ|О/' => 'O', 52 | '/ò|ó|ô|õ|ō|ŏ|ǒ|ő|ơ|ø|ǿ|º|ο|ό|ω|ώ|ỏ|ọ|ồ|ố|ỗ|ổ|ộ|ờ|ớ|ỡ|ở|ợ|о/' => 'o', 53 | '/П/' => 'P', 54 | '/п/' => 'p', 55 | '/Ŕ|Ŗ|Ř|Ρ|Р/' => 'R', 56 | '/ŕ|ŗ|ř|ρ|р/' => 'r', 57 | '/Ś|Ŝ|Ş|Ș|Š|Σ|С/' => 'S', 58 | '/ś|ŝ|ş|ș|š|ſ|σ|ς|с/' => 's', 59 | '/Ț|Ţ|Ť|Ŧ|Τ|Т/' => 'T', 60 | '/ț|ţ|ť|ŧ|τ|т/' => 't', 61 | '/Þ|þ/' => 'th', 62 | '/Ù|Ú|Û|Ũ|Ū|Ŭ|Ů|Ű|Ų|Ư|Ǔ|Ǖ|Ǘ|Ǚ|Ǜ|Ũ|Ủ|Ụ|Ừ|Ứ|Ữ|Ử|Ự|У/' => 'U', 63 | '/ù|ú|û|ũ|ū|ŭ|ů|ű|ų|ư|ǔ|ǖ|ǘ|ǚ|ǜ|υ|ύ|ϋ|ủ|ụ|ừ|ứ|ữ|ử|ự|у/' => 'u', 64 | '/Ƴ|Ɏ|Ỵ|Ẏ|Ӳ|Ӯ|Ў|Ý|Ÿ|Ŷ|Υ|Ύ|Ϋ|Ỳ|Ỹ|Ỷ|Ỵ|Й/' => 'Y', 65 | '/ẙ|ʏ|ƴ|ɏ|ỵ|ẏ|ӳ|ӯ|ў|ý|ÿ|ŷ|ỳ|ỹ|ỷ|ỵ|й/' => 'y', 66 | '/В/' => 'V', 67 | '/в/' => 'v', 68 | '/Ŵ/' => 'W', 69 | '/ŵ/' => 'w', 70 | '/Φ/' => 'F', 71 | '/φ/' => 'f', 72 | '/Χ/' => 'CH', 73 | '/χ/' => 'ch', 74 | '/Ź|Ż|Ž|Ζ|З/' => 'Z', 75 | '/ź|ż|ž|ζ|з/' => 'z', 76 | '/Æ|Ǽ/' => 'AE', 77 | '/ß/' => 'ss', 78 | '/IJ/' => 'IJ', 79 | '/ij/' => 'ij', 80 | '/Œ/' => 'OE', 81 | '/ƒ/' => 'f', 82 | '/Ξ/' => 'KS', 83 | '/ξ/' => 'ks', 84 | '/Π/' => 'P', 85 | '/π/' => 'p', 86 | '/Β/' => 'V', 87 | '/β/' => 'v', 88 | '/Μ/' => 'M', 89 | '/μ/' => 'm', 90 | '/Ψ/' => 'PS', 91 | '/ψ/' => 'ps', 92 | '/Ё/' => 'Yo', 93 | '/ё/' => 'yo', 94 | '/Є/' => 'Ye', 95 | '/є/' => 'ye', 96 | '/Ї/' => 'Yi', 97 | '/Ж/' => 'Zh', 98 | '/ж/' => 'zh', 99 | '/Х/' => 'Kh', 100 | '/х/' => 'kh', 101 | '/Ц/' => 'Ts', 102 | '/ц/' => 'ts', 103 | '/Ч/' => 'Ch', 104 | '/ч/' => 'ch', 105 | '/Ш/' => 'Sh', 106 | '/ш/' => 'sh', 107 | '/Щ/' => 'Shch', 108 | '/щ/' => 'shch', 109 | '/Ъ|ъ|Ь|ь/' => '', 110 | '/Ю/' => 'Yu', 111 | '/ю/' => 'yu', 112 | '/Я/' => 'Ya', 113 | '/я/' => 'ya' 114 | ); 115 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/config/hooks.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/config/memcached.php: -------------------------------------------------------------------------------- 1 | array( 15 | 'hostname' => '127.0.0.1', 16 | 'port' => '11211', 17 | 'weight' => '1', 18 | ), 19 | ); 20 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/config/profiler.php: -------------------------------------------------------------------------------- 1 | my_controller/index 50 | | my-controller/my-method -> my_controller/my_method 51 | */ 52 | $route['default_controller'] = 'welcome'; 53 | $route['404_override'] = ''; 54 | $route['translate_uri_dashes'] = FALSE; 55 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/controllers/Background.php: -------------------------------------------------------------------------------- 1 | 20 | * @see https://codeigniter.com/user_guide/general/urls.html 21 | */ 22 | public function index() 23 | { 24 | $this->load->view('welcome_message'); 25 | } 26 | 27 | public function background() 28 | { 29 | $this->load->library('backgroundprocess'); 30 | $this->backgroundprocess->setCmd("curl -o /www/application/logs/log_background_process.log " . base_url('index.php/background/run')); 31 | //Please don't use "true" argument in a production, This will fill your storage if you not clean all the logs. 32 | $this->backgroundprocess->start(true); 33 | $pid = $this->backgroundprocess->getProcessId(); 34 | echo $this->backgroundprocess->get_log_paths(); 35 | echo $pid . "\n"; 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/controllers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/core/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/helpers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/hooks/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/language/english/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/language/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/libraries/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/logs/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/models/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/third_party/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/views/errors/cli/error_404.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | An uncaught Exception was encountered 4 | 5 | Type: 6 | Message: 7 | Filename: getFile(), "\n"; ?> 8 | Line Number: getLine(); ?> 9 | 10 | 11 | 12 | Backtrace: 13 | getTrace() as $error): ?> 14 | 15 | File: 16 | Line: 17 | Function: 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/views/errors/cli/error_general.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | A PHP Error was encountered 4 | 5 | Severity: 6 | Message: 7 | Filename: 8 | Line Number: 9 | 10 | 11 | 12 | Backtrace: 13 | 14 | 15 | File: 16 | Line: 17 | Function: 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/views/errors/cli/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/views/errors/html/error_404.php: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 404 Page Not Found 8 | 57 | 58 | 59 |
60 |

61 | 62 |
63 | 64 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/views/errors/html/error_db.php: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | Database Error 8 | 57 | 58 | 59 |
60 |

61 | 62 |
63 | 64 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/views/errors/html/error_exception.php: -------------------------------------------------------------------------------- 1 | 4 | 5 |
6 | 7 |

An uncaught Exception was encountered

8 | 9 |

Type:

10 |

Message:

11 |

Filename: getFile(); ?>

12 |

Line Number: getLine(); ?>

13 | 14 | 15 | 16 |

Backtrace:

17 | getTrace() as $error): ?> 18 | 19 | 20 | 21 |

22 | File:
23 | Line:
24 | Function: 25 |

26 | 27 | 28 | 29 | 30 | 31 | 32 |
-------------------------------------------------------------------------------- /examples/codeigniter3/application/views/errors/html/error_general.php: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | Error 8 | 57 | 58 | 59 |
60 |

61 | 62 |
63 | 64 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/views/errors/html/error_php.php: -------------------------------------------------------------------------------- 1 | 4 | 5 |
6 | 7 |

A PHP Error was encountered

8 | 9 |

Severity:

10 |

Message:

11 |

Filename:

12 |

Line Number:

13 | 14 | 15 | 16 |

Backtrace:

17 | 18 | 19 | 20 | 21 |

22 | File:
23 | Line:
24 | Function: 25 |

26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 |
-------------------------------------------------------------------------------- /examples/codeigniter3/application/views/errors/html/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/views/errors/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/views/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/application/views/welcome_message.php: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | Welcome to CodeIgniter 8 | 9 | 67 | 68 | 69 | 70 |
71 |

Welcome to CodeIgniter!

72 | 73 |
74 |

The page you are looking at is being generated dynamically by CodeIgniter.

75 | 76 |

If you would like to edit this page you'll find it located at:

77 | application/views/welcome_message.php 78 | 79 |

The corresponding controller for this page is found at:

80 | application/controllers/Welcome.php 81 | 82 |

If you are exploring CodeIgniter for the very first time, you should start by reading the User Guide.

83 |
84 | 85 | 86 |
87 | 88 | 89 | -------------------------------------------------------------------------------- /examples/codeigniter3/composer.json: -------------------------------------------------------------------------------- 1 | { 2 | "description": "The CodeIgniter framework", 3 | "name": "codeigniter/framework", 4 | "type": "project", 5 | "homepage": "https://codeigniter.com", 6 | "license": "MIT", 7 | "support": { 8 | "forum": "http://forum.codeigniter.com/", 9 | "wiki": "https://github.com/bcit-ci/CodeIgniter/wiki", 10 | "slack": "https://codeigniterchat.slack.com", 11 | "source": "https://github.com/bcit-ci/CodeIgniter" 12 | }, 13 | "require": { 14 | "php": ">=5.3.7" 15 | }, 16 | "suggest": { 17 | "paragonie/random_compat": "Provides better randomness in PHP 5.x" 18 | }, 19 | "require-dev": { 20 | "mikey179/vfsStream": "1.1.*", 21 | "phpunit/phpunit": "4.* || 5.*" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /examples/codeigniter3/license.txt: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 - 2019, British Columbia Institute of Technology 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. -------------------------------------------------------------------------------- /examples/codeigniter3/readme.rst: -------------------------------------------------------------------------------- 1 | ################### 2 | What is CodeIgniter 3 | ################### 4 | 5 | CodeIgniter is an Application Development Framework - a toolkit - for people 6 | who build web sites using PHP. Its goal is to enable you to develop projects 7 | much faster than you could if you were writing code from scratch, by providing 8 | a rich set of libraries for commonly needed tasks, as well as a simple 9 | interface and logical structure to access these libraries. CodeIgniter lets 10 | you creatively focus on your project by minimizing the amount of code needed 11 | for a given task. 12 | 13 | ******************* 14 | Release Information 15 | ******************* 16 | 17 | This repo contains in-development code for future releases. To download the 18 | latest stable release please visit the `CodeIgniter Downloads 19 | `_ page. 20 | 21 | ************************** 22 | Changelog and New Features 23 | ************************** 24 | 25 | You can find a list of all changes for each release in the `user 26 | guide change log `_. 27 | 28 | ******************* 29 | Server Requirements 30 | ******************* 31 | 32 | PHP version 5.6 or newer is recommended. 33 | 34 | It should work on 5.3.7 as well, but we strongly advise you NOT to run 35 | such old versions of PHP, because of potential security and performance 36 | issues, as well as missing features. 37 | 38 | ************ 39 | Installation 40 | ************ 41 | 42 | Please see the `installation section `_ 43 | of the CodeIgniter User Guide. 44 | 45 | ******* 46 | License 47 | ******* 48 | 49 | Please see the `license 50 | agreement `_. 51 | 52 | ********* 53 | Resources 54 | ********* 55 | 56 | - `User Guide `_ 57 | - `Language File Translations `_ 58 | - `Community Forums `_ 59 | - `Community Wiki `_ 60 | - `Community Slack Channel `_ 61 | 62 | Report security issues to our `Security Panel `_ 63 | or via our `page on HackerOne `_, thank you. 64 | 65 | *************** 66 | Acknowledgement 67 | *************** 68 | 69 | The CodeIgniter team would like to thank EllisLab, all the 70 | contributors to the CodeIgniter project and you, the CodeIgniter user. 71 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/.htaccess: -------------------------------------------------------------------------------- 1 | 2 | Require all denied 3 | 4 | 5 | Deny from all 6 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/core/Model.php: -------------------------------------------------------------------------------- 1 | $key; 74 | } 75 | 76 | } 77 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/core/compat/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/core/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/cubrid/cubrid_utility.php: -------------------------------------------------------------------------------- 1 | db->data_cache['db_names'])) 57 | { 58 | return $this->db->data_cache['db_names']; 59 | } 60 | 61 | return $this->db->data_cache['db_names'] = cubrid_list_dbs($this->db->conn_id); 62 | } 63 | 64 | // -------------------------------------------------------------------- 65 | 66 | /** 67 | * CUBRID Export 68 | * 69 | * @param array Preferences 70 | * @return mixed 71 | */ 72 | protected function _backup($params = array()) 73 | { 74 | // No SQL based support in CUBRID as of version 8.4.0. Database or 75 | // table backup can be performed using CUBRID Manager 76 | // database administration tool. 77 | return $this->db->display_error('db_unsupported_feature'); 78 | } 79 | } 80 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/cubrid/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/ibase/ibase_utility.php: -------------------------------------------------------------------------------- 1 | db->hostname, $this->db->username, $this->db->password)) 58 | { 59 | $res = ibase_backup($service, $this->db->database, $filename.'.fbk'); 60 | 61 | // Close the service connection 62 | ibase_service_detach($service); 63 | return $res; 64 | } 65 | 66 | return FALSE; 67 | } 68 | 69 | } 70 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/ibase/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/mssql/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/mssql/mssql_utility.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsupported_feature'); 75 | } 76 | 77 | } 78 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/mysql/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/mysqli/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/oci8/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/oci8/oci8_utility.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsupported_feature'); 66 | } 67 | 68 | } 69 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/odbc/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/odbc/odbc_forge.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsupported_feature'); 61 | } 62 | 63 | } 64 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/pdo/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/pdo/pdo_forge.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsupported_feature'); 61 | } 62 | 63 | } 64 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/pdo/subdrivers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/pdo/subdrivers/pdo_odbc_forge.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/postgre/postgre_utility.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsupported_feature'); 77 | } 78 | } 79 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/sqlite/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/sqlite/sqlite_utility.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsupported_feature'); 59 | } 60 | 61 | } 62 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/sqlite3/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/sqlite3/sqlite3_utility.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsupported_feature'); 59 | } 60 | 61 | } 62 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/sqlsrv/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/drivers/sqlsrv/sqlsrv_utility.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsupported_feature'); 75 | } 76 | 77 | } 78 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/database/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/fonts/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/fonts/texb.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/system/fonts/texb.ttf -------------------------------------------------------------------------------- /examples/codeigniter3/system/helpers/email_helper.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/helpers/language_helper.php: -------------------------------------------------------------------------------- 1 | lang->line($line); 67 | 68 | if ($for !== '') 69 | { 70 | $line = ''; 71 | } 72 | 73 | return $line; 74 | } 75 | } 76 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/helpers/path_helper.php: -------------------------------------------------------------------------------- 1 | ', '"', "'", '-'), 76 | array('&', '<', '>', '"', ''', '-'), 77 | $str 78 | ); 79 | 80 | // Decode the temp markers back to entities 81 | $str = preg_replace('/'.$temp.'(\d+);/', '&#\\1;', $str); 82 | 83 | if ($protect_all === TRUE) 84 | { 85 | return preg_replace('/'.$temp.'(\w+);/', '&\\1;', $str); 86 | } 87 | 88 | return $str; 89 | } 90 | } 91 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/language/english/ftp_lang.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/language/english/migration_lang.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/libraries/Cache/drivers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/libraries/Cache/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/libraries/Javascript/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/libraries/Session/SessionHandlerInterface.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/libraries/Session/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/system/libraries/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/.buildinfo: -------------------------------------------------------------------------------- 1 | # Sphinx build info version 1 2 | # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. 3 | config: 6b49d1813643817be290c380a3028e52 4 | tags: 645f666f9bcd5a90fca523b33c5a78b7 5 | -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_downloads/ELDocs.tmbundle.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_downloads/ELDocs.tmbundle.zip -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_images/appflowchart.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_images/appflowchart.gif -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_images/smile.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_images/smile.gif -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/ajax-loader.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/ajax-loader.gif -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/ci-icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/ci-icon.ico -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/comment-bright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/comment-bright.png -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/comment-close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/comment-close.png -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/comment.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/comment.png -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/css/citheme.css: -------------------------------------------------------------------------------- 1 | @import 'theme.css'; 2 | 3 | .highlighted { 4 | padding: 0px !important; 5 | font-weight: inherit !important; 6 | background-color: #f1d40f !important; 7 | } 8 | 9 | #nav { 10 | background-color: #494949; 11 | margin: 0; 12 | padding: 0; 13 | display: none; 14 | } 15 | 16 | #nav2 { 17 | background: url(data:image/jpeg;base64,/9j/4AAQSkZJRgABAgAAZABkAAD/7AARRHVja3kAAQAEAAAARgAA/+4ADkFkb2JlAGTAAAAAAf/bAIQABAMDAwMDBAMDBAYEAwQGBwUEBAUHCAYGBwYGCAoICQkJCQgKCgwMDAwMCgwMDQ0MDBERERERFBQUFBQUFBQUFAEEBQUIBwgPCgoPFA4ODhQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQU/8AAEQgAMgAzAwERAAIRAQMRAf/EAFkAAQADAQAAAAAAAAAAAAAAAAABBQcIAQEAAAAAAAAAAAAAAAAAAAAAEAABAgYDAAAAAAAAAAAAAAAAAVERAtMEFJRVBxgRAQAAAAAAAAAAAAAAAAAAAAD/2gAMAwEAAhEDEQA/AMRAAAAAAAA7a87dZcCu3e1wHnbrLgV272uA87dZcCu3e1wHnbrLgV272uA87dZcCu3e1wHnbrLgV272uA87dZcCu3e1wN/wJGAYEjAMCRgGBIwDAkYBgSMAwJGAsoIwCCMAgjAIIwCCMAgjAIIwEgAAAAAAAAAAAAAAAAAAAAAAAH//2Q==) repeat-x scroll left top transparent; 18 | margin: 0; 19 | padding: 0 310px 0 0; 20 | text-align: right; 21 | display: none; 22 | } 23 | 24 | #nav_inner { 25 | background-color: transparent; 26 | font-family: Lucida Grande,Verdana,Geneva,sans-serif; 27 | font-size: 11px; 28 | margin: 0; 29 | padding: 8px 12px 0 20px; 30 | } 31 | 32 | div#pulldown-menu { 33 | -moz-column-count: 5; 34 | -moz-column-gap: 20px; 35 | -webkit-column-count: 5; 36 | -webkit-column-gap: 20px; 37 | column-count: 5; 38 | column-gap: 20px; 39 | -webkit-column-rule: 1px groove #b8b8b8; 40 | -moz-column-rule: 1px groove #b8b8b8; 41 | column-rule: 1px groove #b8b8b8; 42 | } 43 | 44 | #pulldown-menu > ul { 45 | padding-top: 10px; 46 | padding-bottom: 10px; 47 | -webkit-column-break-inside: avoid; /*Chrome, Safari*/ 48 | display: table; /*Firefox*/ 49 | break-inside: avoid; /*IE 10+ theoretically*/ 50 | } 51 | 52 | #pulldown-menu ul li.toctree-l2 { 53 | font-size: 0.82em; 54 | margin-left: 20px; 55 | list-style-image: url(data:image/gif;base64,R0lGODlhCwAJALMJAO7u7uTk5PLy8unp6fb29t7e3vj4+Li4uIWFheTk5AAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAAkALAAAAAALAAkAAAQoMJ1JqTQ4Z3SI98jHCWSJkByArCyiHkMsIzEX3DeCc0Xv+4hEa5iIAAA7); 56 | } 57 | 58 | #pulldown-menu ul li.toctree-l1 a { 59 | color: #ffffff; 60 | text-decoration: none; 61 | font-size: 12px; 62 | font-family: "Roboto Slab","ff-tisa-web-pro","Georgia",Arial,sans-serif; 63 | font-weight: 700; 64 | } 65 | 66 | #pulldown-menu ul li.toctree-l2 a { 67 | text-decoration: none; 68 | font-size: 11px; 69 | line-height: 1.4em; 70 | font-weight: 300; 71 | font-family: Lucida Grande,Verdana,Geneva,sans-serif; 72 | color: #aaaaaa; 73 | } 74 | 75 | /*hide pulldown menu on mobile devices*/ 76 | @media (max-width: 768px) { /*tablet size defined by theme*/ 77 | #closeMe { 78 | display: none; 79 | } 80 | 81 | #pulldown { 82 | display: none; 83 | } 84 | 85 | #openToc { 86 | display: none; 87 | } 88 | } -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/down-pressed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/down-pressed.png -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/down.png -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/file.png -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/images/ci-icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/images/ci-icon.ico -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/js/oldtheme.js: -------------------------------------------------------------------------------- 1 | $( document ).ready(function() { 2 | // Shift nav in mobile when clicking the menu. 3 | $(document).on('click', "[data-toggle='wy-nav-top']", function() { 4 | $("[data-toggle='wy-nav-shift']").toggleClass("shift"); 5 | $("[data-toggle='rst-versions']").toggleClass("shift"); 6 | }); 7 | // Close menu when you click a link. 8 | $(document).on('click', ".wy-menu-vertical .current ul li a", function() { 9 | $("[data-toggle='wy-nav-shift']").removeClass("shift"); 10 | $("[data-toggle='rst-versions']").toggleClass("shift"); 11 | }); 12 | $(document).on('click', "[data-toggle='rst-current-version']", function() { 13 | $("[data-toggle='rst-versions']").toggleClass("shift-up"); 14 | }); 15 | // Make tables responsive 16 | $("table.docutils:not(.field-list)").wrap("
"); 17 | }); 18 | 19 | window.SphinxRtdTheme = (function (jquery) { 20 | var stickyNav = (function () { 21 | var navBar, 22 | win, 23 | stickyNavCssClass = 'stickynav', 24 | applyStickNav = function () { 25 | if (navBar.height() <= win.height()) { 26 | navBar.addClass(stickyNavCssClass); 27 | } else { 28 | navBar.removeClass(stickyNavCssClass); 29 | } 30 | }, 31 | enable = function () { 32 | applyStickNav(); 33 | win.on('resize', applyStickNav); 34 | }, 35 | init = function () { 36 | navBar = jquery('nav.wy-nav-side:first'); 37 | win = jquery(window); 38 | }; 39 | jquery(init); 40 | return { 41 | enable : enable 42 | }; 43 | }()); 44 | return { 45 | StickyNav : stickyNav 46 | }; 47 | }($)); 48 | -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/minus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/minus.png -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/plus.png -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/up-pressed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/up-pressed.png -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/_static/up.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/_static/up.png -------------------------------------------------------------------------------- /examples/codeigniter3/user_guide/objects.inv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter3/user_guide/objects.inv -------------------------------------------------------------------------------- /examples/codeigniter4/.gitignore: -------------------------------------------------------------------------------- 1 | #------------------------- 2 | # Operating Specific Junk Files 3 | #------------------------- 4 | 5 | # OS X 6 | .DS_Store 7 | .AppleDouble 8 | .LSOverride 9 | 10 | # OS X Thumbnails 11 | ._* 12 | 13 | # Windows image file caches 14 | Thumbs.db 15 | ehthumbs.db 16 | Desktop.ini 17 | 18 | # Recycle Bin used on file shares 19 | $RECYCLE.BIN/ 20 | 21 | # Windows Installer files 22 | *.cab 23 | *.msi 24 | *.msm 25 | *.msp 26 | 27 | # Windows shortcuts 28 | *.lnk 29 | 30 | # Linux 31 | *~ 32 | 33 | # KDE directory preferences 34 | .directory 35 | 36 | # Linux trash folder which might appear on any partition or disk 37 | .Trash-* 38 | 39 | #------------------------- 40 | # Environment Files 41 | #------------------------- 42 | # These should never be under version control, 43 | # as it poses a security risk. 44 | .env 45 | .vagrant 46 | Vagrantfile 47 | 48 | #------------------------- 49 | # Temporary Files 50 | #------------------------- 51 | writable/cache/* 52 | !writable/cache/index.html 53 | 54 | writable/logs/* 55 | !writable/logs/index.html 56 | 57 | writable/session/* 58 | !writable/session/index.html 59 | 60 | writable/uploads/* 61 | !writable/uploads/index.html 62 | 63 | writable/debugbar/* 64 | 65 | php_errors.log 66 | 67 | #------------------------- 68 | # User Guide Temp Files 69 | #------------------------- 70 | user_guide_src/build/* 71 | user_guide_src/cilexer/build/* 72 | user_guide_src/cilexer/dist/* 73 | user_guide_src/cilexer/pycilexer.egg-info/* 74 | 75 | #------------------------- 76 | # Test Files 77 | #------------------------- 78 | tests/coverage* 79 | 80 | # Don't save phpunit under version control. 81 | phpunit 82 | 83 | #------------------------- 84 | # Composer 85 | #------------------------- 86 | vendor/ 87 | composer.lock 88 | 89 | #------------------------- 90 | # IDE / Development Files 91 | #------------------------- 92 | 93 | # Modules Testing 94 | _modules/* 95 | 96 | # phpenv local config 97 | .php-version 98 | 99 | # Jetbrains editors (PHPStorm, etc) 100 | .idea/ 101 | *.iml 102 | 103 | # Netbeans 104 | nbproject/ 105 | build/ 106 | nbbuild/ 107 | dist/ 108 | nbdist/ 109 | nbactions.xml 110 | nb-configuration.xml 111 | .nb-gradle/ 112 | 113 | # Sublime Text 114 | *.tmlanguage.cache 115 | *.tmPreferences.cache 116 | *.stTheme.cache 117 | *.sublime-workspace 118 | *.sublime-project 119 | .phpintel 120 | /api/ 121 | 122 | # Visual Studio Code 123 | .vscode/ 124 | 125 | /results/ 126 | /phpunit*.xml 127 | /.phpunit.*.cache 128 | -------------------------------------------------------------------------------- /examples/codeigniter4/README.md: -------------------------------------------------------------------------------- 1 | # CodeIgniter 4 Application Starter 2 | 3 | ## What is CodeIgniter? 4 | 5 | CodeIgniter is a PHP full-stack web framework that is light, fast, flexible, and secure. 6 | More information can be found at the [official site](http://codeigniter.com). 7 | 8 | This repository holds a composer-installable app starter. 9 | It has been built from the 10 | [development repository](https://github.com/codeigniter4/CodeIgniter4). 11 | 12 | More information about the plans for version 4 can be found in [the announcement](http://forum.codeigniter.com/thread-62615.html) on the forums. 13 | 14 | The user guide corresponding to this version of the framework can be found 15 | [here](https://codeigniter4.github.io/userguide/). 16 | 17 | ## Installation & updates 18 | 19 | `composer create-project codeigniter4/appstarter` then `composer update` whenever 20 | there is a new release of the framework. 21 | 22 | When updating, check the release notes to see if there are any changes you might need to apply 23 | to your `app` folder. The affected files can be copied or merged from 24 | `vendor/codeigniter4/framework/app`. 25 | 26 | ## Setup 27 | 28 | Copy `env` to `.env` and tailor for your app, specifically the baseURL 29 | and any database settings. 30 | 31 | ## Important Change with index.php 32 | 33 | `index.php` is no longer in the root of the project! It has been moved inside the *public* folder, 34 | for better security and separation of components. 35 | 36 | This means that you should configure your web server to "point" to your project's *public* folder, and 37 | not to the project root. A better practice would be to configure a virtual host to point there. A poor practice would be to point your web server to the project root and expect to enter *public/...*, as the rest of your logic and the 38 | framework are exposed. 39 | 40 | **Please** read the user guide for a better explanation of how CI4 works! 41 | The user guide updating and deployment is a bit awkward at the moment, but we are working on it! 42 | 43 | ## Repository Management 44 | 45 | We use Github issues, in our main repository, to track **BUGS** and to track approved **DEVELOPMENT** work packages. 46 | We use our [forum](http://forum.codeigniter.com) to provide SUPPORT and to discuss 47 | FEATURE REQUESTS. 48 | 49 | This repository is a "distribution" one, built by our release preparation script. 50 | Problems with it can be raised on our forum, or as issues in the main repository. 51 | 52 | ## Server Requirements 53 | 54 | PHP version 7.2 or higher is required, with the following extensions installed: 55 | 56 | - [intl](http://php.net/manual/en/intl.requirements.php) 57 | - [libcurl](http://php.net/manual/en/curl.requirements.php) if you plan to use the HTTP\CURLRequest library 58 | 59 | Additionally, make sure that the following extensions are enabled in your PHP: 60 | 61 | - json (enabled by default - don't turn it off) 62 | - [mbstring](http://php.net/manual/en/mbstring.installation.php) 63 | - [mysqlnd](http://php.net/manual/en/mysqlnd.install.php) 64 | - xml (enabled by default - don't turn it off) 65 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/.htaccess: -------------------------------------------------------------------------------- 1 | 2 | Require all denied 3 | 4 | 5 | Deny from all 6 | 7 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Common.php: -------------------------------------------------------------------------------- 1 | '', 34 | 'hostname' => 'localhost', 35 | 'username' => '', 36 | 'password' => '', 37 | 'database' => '', 38 | 'DBDriver' => 'MySQLi', 39 | 'DBPrefix' => '', 40 | 'pConnect' => false, 41 | 'DBDebug' => (ENVIRONMENT !== 'production'), 42 | 'cacheOn' => false, 43 | 'cacheDir' => '', 44 | 'charset' => 'utf8', 45 | 'DBCollat' => 'utf8_general_ci', 46 | 'swapPre' => '', 47 | 'encrypt' => false, 48 | 'compress' => false, 49 | 'strictOn' => false, 50 | 'failover' => [], 51 | 'port' => 3306, 52 | ]; 53 | 54 | /** 55 | * This database connection is used when 56 | * running PHPUnit database tests. 57 | * 58 | * @var array 59 | */ 60 | public $tests = [ 61 | 'DSN' => '', 62 | 'hostname' => '127.0.0.1', 63 | 'username' => '', 64 | 'password' => '', 65 | 'database' => ':memory:', 66 | 'DBDriver' => 'SQLite3', 67 | 'DBPrefix' => 'db_', // Needed to ensure we're working correctly with prefixes live. DO NOT REMOVE FOR CI DEVS 68 | 'pConnect' => false, 69 | 'DBDebug' => (ENVIRONMENT !== 'production'), 70 | 'cacheOn' => false, 71 | 'cacheDir' => '', 72 | 'charset' => 'utf8', 73 | 'DBCollat' => 'utf8_general_ci', 74 | 'swapPre' => '', 75 | 'encrypt' => false, 76 | 'compress' => false, 77 | 'strictOn' => false, 78 | 'failover' => [], 79 | 'port' => 3306, 80 | ]; 81 | 82 | //-------------------------------------------------------------------- 83 | 84 | public function __construct() 85 | { 86 | parent::__construct(); 87 | 88 | // Ensure that we always set the database group to 'tests' if 89 | // we are currently running an automated test suite, so that 90 | // we don't overwrite live data on accident. 91 | if (ENVIRONMENT === 'testing') 92 | { 93 | $this->defaultGroup = 'tests'; 94 | 95 | // Under Travis-CI, we can set an ENV var named 'DB_GROUP' 96 | // so that we can test against multiple databases. 97 | if ($group = getenv('DB')) 98 | { 99 | if (is_file(TESTPATH . 'travis/Database.php')) 100 | { 101 | require TESTPATH . 'travis/Database.php'; 102 | 103 | if (! empty($dbconfig) && array_key_exists($group, $dbconfig)) 104 | { 105 | $this->tests = $dbconfig[$group]; 106 | } 107 | } 108 | } 109 | } 110 | } 111 | 112 | //-------------------------------------------------------------------- 113 | 114 | } 115 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/DocTypes.php: -------------------------------------------------------------------------------- 1 | '', 14 | 'xhtml1-strict' => '', 15 | 'xhtml1-trans' => '', 16 | 'xhtml1-frame' => '', 17 | 'xhtml-basic11' => '', 18 | 'html5' => '', 19 | 'html4-strict' => '', 20 | 'html4-trans' => '', 21 | 'html4-frame' => '', 22 | 'mathml1' => '', 23 | 'mathml2' => '', 24 | 'svg10' => '', 25 | 'svg11' => '', 26 | 'svg11-basic' => '', 27 | 'svg11-tiny' => '', 28 | 'xhtml-math-svg-xh' => '', 29 | 'xhtml-math-svg-sh' => '', 30 | 'xhtml-rdfa-1' => '', 31 | 'xhtml-rdfa-2' => '', 32 | ]; 33 | } 34 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/Email.php: -------------------------------------------------------------------------------- 1 | 0) 26 | { 27 | \ob_end_flush(); 28 | } 29 | 30 | \ob_start(function ($buffer) { 31 | return $buffer; 32 | }); 33 | } 34 | 35 | /* 36 | * -------------------------------------------------------------------- 37 | * Debug Toolbar Listeners. 38 | * -------------------------------------------------------------------- 39 | * If you delete, they will no longer be collected. 40 | */ 41 | if (ENVIRONMENT !== 'production') 42 | { 43 | Events::on('DBQuery', 'CodeIgniter\Debug\Toolbar\Collectors\Database::collect'); 44 | Services::toolbar()->respond(); 45 | } 46 | }); 47 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/Exceptions.php: -------------------------------------------------------------------------------- 1 | \CodeIgniter\Filters\CSRF::class, 11 | 'toolbar' => \CodeIgniter\Filters\DebugToolbar::class, 12 | 'honeypot' => \CodeIgniter\Filters\Honeypot::class, 13 | ]; 14 | 15 | // Always applied before every request 16 | public $globals = [ 17 | 'before' => [ 18 | //'honeypot' 19 | // 'csrf', 20 | ], 21 | 'after' => [ 22 | 'toolbar', 23 | //'honeypot' 24 | ], 25 | ]; 26 | 27 | // Works on all of a particular HTTP method 28 | // (GET, POST, etc) as BEFORE filters only 29 | // like: 'post' => ['CSRF', 'throttle'], 30 | public $methods = []; 31 | 32 | // List filter aliases and any before/after uri patterns 33 | // that they should run on, like: 34 | // 'isLoggedIn' => ['before' => ['account/*', 'profiles/*']], 35 | public $filters = []; 36 | } 37 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/ForeignCharacters.php: -------------------------------------------------------------------------------- 1 | \CodeIgniter\Format\JSONFormatter::class, 39 | 'application/xml' => \CodeIgniter\Format\XMLFormatter::class, 40 | 'text/xml' => \CodeIgniter\Format\XMLFormatter::class, 41 | ]; 42 | 43 | //-------------------------------------------------------------------- 44 | 45 | /** 46 | * A Factory method to return the appropriate formatter for the given mime type. 47 | * 48 | * @param string $mime 49 | * 50 | * @return \CodeIgniter\Format\FormatterInterface 51 | */ 52 | public function getFormatter(string $mime) 53 | { 54 | if (! array_key_exists($mime, $this->formatters)) 55 | { 56 | throw new \InvalidArgumentException('No Formatter defined for mime type: ' . $mime); 57 | } 58 | 59 | $class = $this->formatters[$mime]; 60 | 61 | if (! class_exists($class)) 62 | { 63 | throw new \BadMethodCallException($class . ' is not a valid Formatter.'); 64 | } 65 | 66 | return new $class(); 67 | } 68 | 69 | //-------------------------------------------------------------------- 70 | 71 | } 72 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/Honeypot.php: -------------------------------------------------------------------------------- 1 | {label}'; 34 | } 35 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/Images.php: -------------------------------------------------------------------------------- 1 | \CodeIgniter\Images\Handlers\GDHandler::class, 29 | 'imagick' => \CodeIgniter\Images\Handlers\ImageMagickHandler::class, 30 | ]; 31 | } 32 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/Kint.php: -------------------------------------------------------------------------------- 1 | php spark migrate:create 41 | | 42 | | Typical formats: 43 | | YmdHis_ 44 | | Y-m-d-His_ 45 | | Y_m_d_His_ 46 | | 47 | */ 48 | public $timestampFormat = 'Y-m-d-His_'; 49 | 50 | } 51 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/Modules.php: -------------------------------------------------------------------------------- 1 | enabled) 59 | { 60 | return false; 61 | } 62 | 63 | $alias = strtolower($alias); 64 | 65 | return in_array($alias, $this->activeExplorers); 66 | } 67 | } 68 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/Pager.php: -------------------------------------------------------------------------------- 1 | 'CodeIgniter\Pager\Views\default_full', 22 | 'default_simple' => 'CodeIgniter\Pager\Views\default_simple', 23 | 'default_head' => 'CodeIgniter\Pager\Views\default_head', 24 | ]; 25 | 26 | /* 27 | |-------------------------------------------------------------------------- 28 | | Items Per Page 29 | |-------------------------------------------------------------------------- 30 | | 31 | | The default number of results shown in a single page. 32 | | 33 | */ 34 | public $perPage = 20; 35 | } 36 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/Paths.php: -------------------------------------------------------------------------------- 1 | setDefaultNamespace('App\Controllers'); 19 | $routes->setDefaultController('Home'); 20 | $routes->setDefaultMethod('index'); 21 | $routes->setTranslateURIDashes(false); 22 | $routes->set404Override(); 23 | $routes->setAutoRoute(true); 24 | 25 | /** 26 | * -------------------------------------------------------------------- 27 | * Route Definitions 28 | * -------------------------------------------------------------------- 29 | */ 30 | 31 | // We get a performance increase by specifying the default 32 | // route since we don't have to scan directories. 33 | $routes->get('/', 'Home::index'); 34 | 35 | /** 36 | * -------------------------------------------------------------------- 37 | * Additional Routing 38 | * -------------------------------------------------------------------- 39 | * 40 | * There will often be times that you need additional routing and you 41 | * need to it be able to override any defaults in this file. Environment 42 | * based routes is one such time. require() additional route files here 43 | * to make that happen. 44 | * 45 | * You will have access to the $routes object within that file without 46 | * needing to reload it. 47 | */ 48 | if (file_exists(APPPATH . 'Config/' . ENVIRONMENT . '/Routes.php')) 49 | { 50 | require APPPATH . 'Config/' . ENVIRONMENT . '/Routes.php'; 51 | } 52 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/Services.php: -------------------------------------------------------------------------------- 1 | 'CodeIgniter\Validation\Views\list', 30 | 'single' => 'CodeIgniter\Validation\Views\single', 31 | ]; 32 | 33 | //-------------------------------------------------------------------- 34 | // Rules 35 | //-------------------------------------------------------------------- 36 | } 37 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Config/View.php: -------------------------------------------------------------------------------- 1 | getProcessId(); 15 | echo $pid . "\n"; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Controllers/BaseController.php: -------------------------------------------------------------------------------- 1 | session = \Config\Services::session(); 44 | } 45 | 46 | } 47 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Controllers/Home.php: -------------------------------------------------------------------------------- 1 | command = $cmd; 28 | $this->isOutPut = $isOutPut; 29 | $this->do_process(); 30 | } else { 31 | $this->msg['error'] = "Please Provide the Command Here"; 32 | } 33 | } 34 | 35 | public function setCmd($cmd) 36 | { 37 | $this->command = $cmd; 38 | return true; 39 | } 40 | 41 | public function setProcessId($pid) 42 | { 43 | $this->pid = $pid; 44 | return true; 45 | } 46 | 47 | public function getProcessId() 48 | { 49 | return $this->pid; 50 | } 51 | public function status() 52 | { 53 | $command = 'ps -p ' . $this->pid; 54 | exec($command, $op); 55 | if (!isset($op[1])) return false; 56 | else return true; 57 | } 58 | 59 | public function showAllProcess() 60 | { 61 | $command = 'ps -ef ' . $this->pid; 62 | exec($command, $op); 63 | return $op; 64 | } 65 | 66 | public function start($isOutPut = null) 67 | { 68 | $this->isOutPut = $isOutPut; 69 | if ($this->command != '') 70 | $this->do_process(); 71 | else return true; 72 | } 73 | 74 | public function stop() 75 | { 76 | $command = 'kill ' . $this->pid; 77 | exec($command); 78 | if ($this->status() == false) return true; 79 | else return false; 80 | } 81 | public function get_log_paths() 82 | { 83 | return "Log path: \nstdout: /tmp/out_" . $this->random . "\nstderr: /tmp/error_out_" . $this->random . "\n"; 84 | } 85 | public function create_command_string() 86 | { 87 | $outPath = ' > /dev/null 2>&1'; 88 | if ($this->isOutPut) { 89 | $this->random = rand(5, 15); 90 | $outPath = ' 1> /tmp/out_' . $this->random . ' 2> /tmp/error_out_' . $this->random; 91 | } 92 | return 'nohup ' . $this->command . $outPath . ' & echo $!'; 93 | } 94 | //do the process in background 95 | public function do_process() 96 | { 97 | $command = $this->create_command_string(); 98 | exec($command, $process); 99 | $this->pid = (int) $process[0]; 100 | } 101 | 102 | /* 103 | *To execute a PHP url on background you have to do the following things. 104 | * $process=new BackgroundProcess("curl -s -o /log/xyz.log -d param_key="); 105 | */ 106 | } 107 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Models/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter4/app/Models/.gitkeep -------------------------------------------------------------------------------- /examples/codeigniter4/app/ThirdParty/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter4/app/ThirdParty/.gitkeep -------------------------------------------------------------------------------- /examples/codeigniter4/app/Views/errors/cli/error_404.php: -------------------------------------------------------------------------------- 1 | 4 | Message: 5 | Filename: getFile(), "\n"; ?> 6 | Line Number: getLine(); ?> 7 | 8 | 9 | 10 | Backtrace: 11 | getTrace() as $error): ?> 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Views/errors/cli/production.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 404 Page Not Found 6 | 7 | 70 | 71 | 72 |
73 |

404 - File Not Found

74 | 75 |

76 | 77 | 78 | 79 | Sorry! Cannot seem to find the page you were looking for. 80 | 81 |

82 |
83 | 84 | 85 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/Views/errors/html/production.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Whoops! 8 | 9 | 12 | 13 | 14 | 15 |
16 | 17 |

Whoops!

18 | 19 |

We seem to have hit a snag. Please try again later...

20 | 21 |
22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /examples/codeigniter4/app/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter4/composer.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "codeigniter4/appstarter", 3 | "type": "project", 4 | "description": "CodeIgniter4 starter app", 5 | "homepage": "https://codeigniter.com", 6 | "license": "MIT", 7 | "require": { 8 | "php": ">=7.2", 9 | "codeigniter4/codeigniter4": "dev-develop" 10 | }, 11 | "require-dev": { 12 | "mikey179/vfsstream": "1.6.*", 13 | "phpunit/phpunit": "8.5.*" 14 | }, 15 | "autoload-dev": { 16 | "psr-4": { 17 | "Tests\\Support\\": "tests/_support" 18 | } 19 | }, 20 | "scripts": { 21 | "test": "phpunit", 22 | "post-update-cmd": [ 23 | "@composer dump-autoload" 24 | ] 25 | }, 26 | "support": { 27 | "forum": "http://forum.codeigniter.com/", 28 | "source": "https://github.com/codeigniter4/CodeIgniter4", 29 | "slack": "https://codeigniterchat.slack.com" 30 | }, 31 | "minimum-stability": "dev", 32 | "prefer-stable": true, 33 | "repositories": [ 34 | { 35 | "type": "vcs", 36 | "url": "https://github.com/codeigniter4/codeigniter4" 37 | } 38 | ] 39 | } 40 | -------------------------------------------------------------------------------- /examples/codeigniter4/license.txt: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014-2019 British Columbia Institute of Technology 4 | Copyright (c) 2019-2020 CodeIgniter Foundation 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | -------------------------------------------------------------------------------- /examples/codeigniter4/phpunit.xml.dist: -------------------------------------------------------------------------------- 1 | 2 | 12 | 13 | 14 | ./tests 15 | 16 | 17 | 18 | 19 | 20 | ./app 21 | 22 | ./app/Views 23 | ./app/Config/Routes.php 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /examples/codeigniter4/public/.htaccess: -------------------------------------------------------------------------------- 1 | # Disable directory browsing 2 | Options All -Indexes 3 | 4 | # ---------------------------------------------------------------------- 5 | # Rewrite engine 6 | # ---------------------------------------------------------------------- 7 | 8 | # Turning on the rewrite engine is necessary for the following rules and features. 9 | # FollowSymLinks must be enabled for this to work. 10 | 11 | Options +FollowSymlinks 12 | RewriteEngine On 13 | 14 | # If you installed CodeIgniter in a subfolder, you will need to 15 | # change the following line to match the subfolder you need. 16 | # http://httpd.apache.org/docs/current/mod/mod_rewrite.html#rewritebase 17 | # RewriteBase / 18 | 19 | # Redirect Trailing Slashes... 20 | RewriteCond %{REQUEST_FILENAME} !-d 21 | RewriteRule ^(.*)/$ /$1 [L,R=301] 22 | 23 | # Rewrite "www.example.com -> example.com" 24 | RewriteCond %{HTTPS} !=on 25 | RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC] 26 | RewriteRule ^ http://%1%{REQUEST_URI} [R=301,L] 27 | 28 | # Checks to see if the user is attempting to access a valid file, 29 | # such as an image or css document, if this isn't true it sends the 30 | # request to the front controller, index.php 31 | RewriteCond %{REQUEST_FILENAME} !-f 32 | RewriteCond %{REQUEST_FILENAME} !-d 33 | RewriteRule ^(.*)$ index.php/$1 [L] 34 | 35 | # Ensure Authorization header is passed along 36 | RewriteCond %{HTTP:Authorization} . 37 | RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}] 38 | 39 | 40 | 41 | # If we don't have mod_rewrite installed, all 404's 42 | # can be sent to index.php, and everything works as normal. 43 | ErrorDocument 404 index.php 44 | 45 | 46 | # Disable server signature start 47 | ServerSignature Off 48 | # Disable server signature end 49 | -------------------------------------------------------------------------------- /examples/codeigniter4/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pandasanjay/php-script-background-processer/e1b68298e6a09ca680c54c11a667ba908980ce61/examples/codeigniter4/public/favicon.ico -------------------------------------------------------------------------------- /examples/codeigniter4/public/index.php: -------------------------------------------------------------------------------- 1 | systemDirectory, '/ ') . '/bootstrap.php'; 37 | 38 | /* 39 | *--------------------------------------------------------------- 40 | * LAUNCH THE APPLICATION 41 | *--------------------------------------------------------------- 42 | * Now that everything is setup, it's time to actually fire 43 | * up the engines and make this app do its thang. 44 | */ 45 | $app->run(); 46 | -------------------------------------------------------------------------------- /examples/codeigniter4/public/page_control/log/log_background_process.log: -------------------------------------------------------------------------------- 1 | Hello I am a background process World! 2 | -------------------------------------------------------------------------------- /examples/codeigniter4/public/robots.txt: -------------------------------------------------------------------------------- 1 | User-agent: * 2 | Disallow: 3 | -------------------------------------------------------------------------------- /examples/codeigniter4/spark: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env php 2 | systemDirectory, '/ ') . '/bootstrap.php'; 45 | 46 | // Grab our Console 47 | $console = new \CodeIgniter\CLI\Console($app); 48 | 49 | // We want errors to be shown when using it from the CLI. 50 | error_reporting(-1); 51 | ini_set('display_errors', 1); 52 | 53 | // Show basic information before we do anything else. 54 | $console->showHeader(); 55 | 56 | // fire off the command in the main framework. 57 | $response = $console->run(); 58 | if ($response->getStatusCode() >= 300) 59 | { 60 | exit($response->getStatusCode()); 61 | } 62 | -------------------------------------------------------------------------------- /examples/codeigniter4/tests/_support/Database/Migrations/2020-02-22-222222_example_migration.php: -------------------------------------------------------------------------------- 1 | [ 13 | 'type' => 'varchar', 14 | 'constraint' => 31, 15 | ], 16 | 'uid' => [ 17 | 'type' => 'varchar', 18 | 'constraint' => 31, 19 | ], 20 | 'class' => [ 21 | 'type' => 'varchar', 22 | 'constraint' => 63, 23 | ], 24 | 'icon' => [ 25 | 'type' => 'varchar', 26 | 'constraint' => 31, 27 | ], 28 | 'summary' => [ 29 | 'type' => 'varchar', 30 | 'constraint' => 255, 31 | ], 32 | 'created_at' => [ 33 | 'type' => 'datetime', 34 | 'null' => true, 35 | ], 36 | 'updated_at' => [ 37 | 'type' => 'datetime', 38 | 'null' => true, 39 | ], 40 | 'deleted_at' => [ 41 | 'type' => 'datetime', 42 | 'null' => true, 43 | ], 44 | ]; 45 | 46 | $this->forge->addField('id'); 47 | $this->forge->addField($fields); 48 | 49 | $this->forge->addKey('name'); 50 | $this->forge->addKey('uid'); 51 | $this->forge->addKey(['deleted_at', 'id']); 52 | $this->forge->addKey('created_at'); 53 | 54 | $this->forge->createTable('factories'); 55 | } 56 | 57 | public function down() 58 | { 59 | $this->forge->dropTable('factories'); 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /examples/codeigniter4/tests/_support/Database/Seeds/ExampleSeeder.php: -------------------------------------------------------------------------------- 1 | 'Test Factory', 12 | 'uid' => 'test001', 13 | 'class' => 'Factories\Tests\NewFactory', 14 | 'icon' => 'fas fa-puzzle-piece', 15 | 'summary' => 'Longer sample text for testing', 16 | ], 17 | [ 18 | 'name' => 'Widget Factory', 19 | 'uid' => 'widget', 20 | 'class' => 'Factories\Tests\WidgetPlant', 21 | 'icon' => 'fas fa-puzzle-piece', 22 | 'summary' => 'Create widgets in your factory', 23 | ], 24 | [ 25 | 'name' => 'Evil Factory', 26 | 'uid' => 'evil-maker', 27 | 'class' => 'Factories\Evil\MyFactory', 28 | 'icon' => 'fas fa-book-dead', 29 | 'summary' => 'Abandon all hope, ye who enter here', 30 | ], 31 | ]; 32 | 33 | $builder = $this->db->table('factories'); 34 | 35 | foreach ($factories as $factory) 36 | { 37 | $builder->insert($factory); 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /examples/codeigniter4/tests/_support/DatabaseTestCase.php: -------------------------------------------------------------------------------- 1 | mockSession(); 19 | } 20 | 21 | /** 22 | * Pre-loads the mock session driver into $this->session. 23 | * 24 | * @var string 25 | */ 26 | protected function mockSession() 27 | { 28 | $config = config('App'); 29 | $this->session = new MockSession(new ArrayHandler($config, '0.0.0.0'), $config); 30 | \Config\Services::injectMock('session', $this->session); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /examples/codeigniter4/tests/database/ExampleDatabaseTest.php: -------------------------------------------------------------------------------- 1 | findAll(); 20 | 21 | // Make sure the count is as expected 22 | $this->assertCount(3, $objects); 23 | } 24 | 25 | public function testSoftDeleteLeavesRow() 26 | { 27 | $model = new ExampleModel(); 28 | $this->setPrivateProperty($model, 'useSoftDeletes', true); 29 | $this->setPrivateProperty($model, 'tempUseSoftDeletes', true); 30 | 31 | $object = $model->first(); 32 | $model->delete($object->id); 33 | 34 | // The model should no longer find it 35 | $this->assertNull($model->find($object->id)); 36 | 37 | // ... but it should still be in the database 38 | $result = $model->builder()->where('id', $object->id)->get()->getResult(); 39 | 40 | $this->assertCount(1, $result); 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /examples/codeigniter4/tests/session/ExampleSessionTest.php: -------------------------------------------------------------------------------- 1 | session->set('logged_in', 123); 13 | 14 | $value = $this->session->get('logged_in'); 15 | 16 | $this->assertEquals(123, $value); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /examples/codeigniter4/tests/unit/HealthTest.php: -------------------------------------------------------------------------------- 1 | assertTrue($test); 15 | } 16 | 17 | public function testBaseUrlHasBeenSet() 18 | { 19 | $env = $config = false; 20 | 21 | // First check in .env 22 | if (is_file(HOMEPATH . '.env')) 23 | { 24 | $env = (bool) preg_grep("/^app\.baseURL = './", file(HOMEPATH . '.env')); 25 | } 26 | 27 | // Then check the actual config file 28 | $reader = new \Tests\Support\Libraries\ConfigReader(); 29 | $config = ! empty($reader->baseUrl); 30 | 31 | $this->assertTrue($env || $config); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /examples/codeigniter4/writable/.htaccess: -------------------------------------------------------------------------------- 1 | 2 | Require all denied 3 | 4 | 5 | Deny from all 6 | 7 | -------------------------------------------------------------------------------- /examples/codeigniter4/writable/cache/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter4/writable/logs/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter4/writable/session/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /examples/codeigniter4/writable/uploads/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 403 Forbidden 5 | 6 | 7 | 8 |

Directory access is forbidden.

9 | 10 | 11 | 12 | --------------------------------------------------------------------------------