-
AgBRAT Junior Member
 
-
Posts: 25
Threads: 11
Joined: May 2022
Reputation:
0
06-12-2022, 11:03 PM
(This post was last modified: 06-12-2022, 11:32 PM by AgBRAT.)
(06-12-2022, 02:59 PM)kenjis Wrote: Check your routes:
$ php spark routes
Code: nykianderson@Nykis-MacBook-Pro shape_search % php spark routes
PHP Warning: Failed loading Zend extension 'xdebug' (tried: /usr/local/lib/php/pecl/20210902/xdebug (dlopen(/usr/local/lib/php/pecl/20210902/xdebug, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/xdebug' (no such file)), /usr/local/lib/php/pecl/20210902/xdebug.so (dlopen(/usr/local/lib/php/pecl/20210902/xdebug.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/xdebug.so' (no such file))) in Unknown on line 0
Warning: Failed loading Zend extension 'xdebug' (tried: /usr/local/lib/php/pecl/20210902/xdebug (dlopen(/usr/local/lib/php/pecl/20210902/xdebug, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/xdebug' (no such file)), /usr/local/lib/php/pecl/20210902/xdebug.so (dlopen(/usr/local/lib/php/pecl/20210902/xdebug.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/xdebug.so' (no such file))) in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'curl' (tried: /usr/local/lib/php/pecl/20210902/curl (dlopen(/usr/local/lib/php/pecl/20210902/curl, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/curl' (no such file)), /usr/local/lib/php/pecl/20210902/curl.so (dlopen(/usr/local/lib/php/pecl/20210902/curl.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/curl.so' (no such file))) in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library 'curl' (tried: /usr/local/lib/php/pecl/20210902/curl (dlopen(/usr/local/lib/php/pecl/20210902/curl, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/curl' (no such file)), /usr/local/lib/php/pecl/20210902/curl.so (dlopen(/usr/local/lib/php/pecl/20210902/curl.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/curl.so' (no such file))) in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'gd' (tried: /usr/local/lib/php/pecl/20210902/gd (dlopen(/usr/local/lib/php/pecl/20210902/gd, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/gd' (no such file)), /usr/local/lib/php/pecl/20210902/gd.so (dlopen(/usr/local/lib/php/pecl/20210902/gd.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/gd.so' (no such file))) in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library 'gd' (tried: /usr/local/lib/php/pecl/20210902/gd (dlopen(/usr/local/lib/php/pecl/20210902/gd, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/gd' (no such file)), /usr/local/lib/php/pecl/20210902/gd.so (dlopen(/usr/local/lib/php/pecl/20210902/gd.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/gd.so' (no such file))) in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'intl' (tried: /usr/local/lib/php/pecl/20210902/intl (dlopen(/usr/local/lib/php/pecl/20210902/intl, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/intl' (no such file)), /usr/local/lib/php/pecl/20210902/intl.so (dlopen(/usr/local/lib/php/pecl/20210902/intl.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/intl.so' (no such file))) in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library 'intl' (tried: /usr/local/lib/php/pecl/20210902/intl (dlopen(/usr/local/lib/php/pecl/20210902/intl, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/intl' (no such file)), /usr/local/lib/php/pecl/20210902/intl.so (dlopen(/usr/local/lib/php/pecl/20210902/intl.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/intl.so' (no such file))) in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'mbstring' (tried: /usr/local/lib/php/pecl/20210902/mbstring (dlopen(/usr/local/lib/php/pecl/20210902/mbstring, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mbstring' (no such file)), /usr/local/lib/php/pecl/20210902/mbstring.so (dlopen(/usr/local/lib/php/pecl/20210902/mbstring.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mbstring.so' (no such file))) in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library 'mbstring' (tried: /usr/local/lib/php/pecl/20210902/mbstring (dlopen(/usr/local/lib/php/pecl/20210902/mbstring, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mbstring' (no such file)), /usr/local/lib/php/pecl/20210902/mbstring.so (dlopen(/usr/local/lib/php/pecl/20210902/mbstring.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mbstring.so' (no such file))) in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'mysqli' (tried: /usr/local/lib/php/pecl/20210902/mysqli (dlopen(/usr/local/lib/php/pecl/20210902/mysqli, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mysqli' (no such file)), /usr/local/lib/php/pecl/20210902/mysqli.so (dlopen(/usr/local/lib/php/pecl/20210902/mysqli.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mysqli.so' (no such file))) in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library 'mysqli' (tried: /usr/local/lib/php/pecl/20210902/mysqli (dlopen(/usr/local/lib/php/pecl/20210902/mysqli, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mysqli' (no such file)), /usr/local/lib/php/pecl/20210902/mysqli.so (dlopen(/usr/local/lib/php/pecl/20210902/mysqli.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mysqli.so' (no such file))) in Unknown on line 0
PHP Warning: chdir(): No such file or directory (errno 2) in /Users/nykianderson/Sites/shape_search/spark on line 44
Warning: chdir(): No such file or directory (errno 2) in /Users/nykianderson/Sites/shape_search/spark on line 44
CodeIgniter v4.2.0 Command Line Tool - Server Time: 2022-06-13 01:55:55 UTC-04:00
+--------+----------------------------------+-------------------------------------------------+-------------------------------------------------+-------------------------------+
| Method | Route | Handler | Before Filters | After Filters |
+--------+----------------------------------+-------------------------------------------------+-------------------------------------------------+-------------------------------+
| GET | / | \App\Controllers\Home::index | honeypot csrf invalidchars | honeypot secureheaders |
| GET | pages/([^/]+) | \App\Controllers\Home::view_pages/$1 | honeypot csrf invalidchars | honeypot secureheaders |
| GET | users/register | \App\Controllers\Users::register | noauth honeypot csrf invalidchars | noauth honeypot secureheaders |
| GET | users/login | \App\Controllers\Users::login | noauth honeypot csrf invalidchars | noauth honeypot secureheaders |
| GET | users/members/dashboard | \App\Controllers\Users\Members::index | auth honeypot csrf invalidchars | auth honeypot secureheaders |
| GET | users/members/profile/([^/]+) | \App\Controllers\Users\Members::view_profile/$1 | auth honeypot csrf invalidchars | auth honeypot secureheaders |
| GET | images/gallery | \App\Controllers\Images\Gallery::index | auth honeypot csrf invalidchars | auth honeypot secureheaders |
| GET | images/view_image/([a-zA-Z0-9]+) | \App\Controllers\Images\Gallery::view_image/$1 | auth honeypot csrf invalidchars | auth honeypot secureheaders |
| GET | logout | \App\Controllers\Users::logout | honeypot csrf invalidchars | honeypot secureheaders |
| POST | users/register | \App\Controllers\Users::register | noauth honeypot csrf invalidchars throttle csrf | noauth honeypot secureheaders |
| POST | users/login | \App\Controllers\Users::login | noauth honeypot csrf invalidchars throttle csrf | noauth honeypot secureheaders |
| POST | users/admin//dashboard | \App\Controllers\admin::dashboard | auth honeypot csrf invalidchars throttle csrf | auth honeypot secureheaders |
| POST | images/view_image/([a-zA-Z0-9]+) | \App\Controllers\Images\Gallery::view_image/$1 | auth honeypot csrf invalidchars throttle csrf | auth honeypot secureheaders |
| CLI | ci(.*) | \CodeIgniter\CLI\CommandRunner::index/$1 | | |
+--------+----------------------------------+-------------------------------------------------+-------------------------------------------------+-------------------------------+
(06-12-2022, 11:03 PM)AgBRAT Wrote: (06-12-2022, 02:59 PM)kenjis Wrote: Check your routes:
$ php spark routes
Code: nykianderson@Nykis-MacBook-Pro shape_search % php spark routes
PHP Warning: Failed loading Zend extension 'xdebug' (tried: /usr/local/lib/php/pecl/20210902/xdebug (dlopen(/usr/local/lib/php/pecl/20210902/xdebug, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/xdebug' (no such file)), /usr/local/lib/php/pecl/20210902/xdebug.so (dlopen(/usr/local/lib/php/pecl/20210902/xdebug.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/xdebug.so' (no such file))) in Unknown on line 0
Warning: Failed loading Zend extension 'xdebug' (tried: /usr/local/lib/php/pecl/20210902/xdebug (dlopen(/usr/local/lib/php/pecl/20210902/xdebug, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/xdebug' (no such file)), /usr/local/lib/php/pecl/20210902/xdebug.so (dlopen(/usr/local/lib/php/pecl/20210902/xdebug.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/xdebug.so' (no such file))) in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'curl' (tried: /usr/local/lib/php/pecl/20210902/curl (dlopen(/usr/local/lib/php/pecl/20210902/curl, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/curl' (no such file)), /usr/local/lib/php/pecl/20210902/curl.so (dlopen(/usr/local/lib/php/pecl/20210902/curl.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/curl.so' (no such file))) in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library 'curl' (tried: /usr/local/lib/php/pecl/20210902/curl (dlopen(/usr/local/lib/php/pecl/20210902/curl, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/curl' (no such file)), /usr/local/lib/php/pecl/20210902/curl.so (dlopen(/usr/local/lib/php/pecl/20210902/curl.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/curl.so' (no such file))) in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'gd' (tried: /usr/local/lib/php/pecl/20210902/gd (dlopen(/usr/local/lib/php/pecl/20210902/gd, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/gd' (no such file)), /usr/local/lib/php/pecl/20210902/gd.so (dlopen(/usr/local/lib/php/pecl/20210902/gd.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/gd.so' (no such file))) in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library 'gd' (tried: /usr/local/lib/php/pecl/20210902/gd (dlopen(/usr/local/lib/php/pecl/20210902/gd, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/gd' (no such file)), /usr/local/lib/php/pecl/20210902/gd.so (dlopen(/usr/local/lib/php/pecl/20210902/gd.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/gd.so' (no such file))) in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'intl' (tried: /usr/local/lib/php/pecl/20210902/intl (dlopen(/usr/local/lib/php/pecl/20210902/intl, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/intl' (no such file)), /usr/local/lib/php/pecl/20210902/intl.so (dlopen(/usr/local/lib/php/pecl/20210902/intl.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/intl.so' (no such file))) in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library 'intl' (tried: /usr/local/lib/php/pecl/20210902/intl (dlopen(/usr/local/lib/php/pecl/20210902/intl, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/intl' (no such file)), /usr/local/lib/php/pecl/20210902/intl.so (dlopen(/usr/local/lib/php/pecl/20210902/intl.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/intl.so' (no such file))) in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'mbstring' (tried: /usr/local/lib/php/pecl/20210902/mbstring (dlopen(/usr/local/lib/php/pecl/20210902/mbstring, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mbstring' (no such file)), /usr/local/lib/php/pecl/20210902/mbstring.so (dlopen(/usr/local/lib/php/pecl/20210902/mbstring.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mbstring.so' (no such file))) in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library 'mbstring' (tried: /usr/local/lib/php/pecl/20210902/mbstring (dlopen(/usr/local/lib/php/pecl/20210902/mbstring, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mbstring' (no such file)), /usr/local/lib/php/pecl/20210902/mbstring.so (dlopen(/usr/local/lib/php/pecl/20210902/mbstring.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mbstring.so' (no such file))) in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'mysqli' (tried: /usr/local/lib/php/pecl/20210902/mysqli (dlopen(/usr/local/lib/php/pecl/20210902/mysqli, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mysqli' (no such file)), /usr/local/lib/php/pecl/20210902/mysqli.so (dlopen(/usr/local/lib/php/pecl/20210902/mysqli.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mysqli.so' (no such file))) in Unknown on line 0
Warning: PHP Startup: Unable to load dynamic library 'mysqli' (tried: /usr/local/lib/php/pecl/20210902/mysqli (dlopen(/usr/local/lib/php/pecl/20210902/mysqli, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mysqli' (no such file)), /usr/local/lib/php/pecl/20210902/mysqli.so (dlopen(/usr/local/lib/php/pecl/20210902/mysqli.so, 0x0009): tried: '/usr/local/lib/php/pecl/20210902/mysqli.so' (no such file))) in Unknown on line 0
PHP Warning: chdir(): No such file or directory (errno 2) in /Users/nykianderson/Sites/shape_search/spark on line 44
Warning: chdir(): No such file or directory (errno 2) in /Users/nykianderson/Sites/shape_search/spark on line 44
CodeIgniter v4.2.0 Command Line Tool - Server Time: 2022-06-13 01:55:55 UTC-04:00
+--------+----------------------------------+-------------------------------------------------+-------------------------------------------------+-------------------------------+
| Method | Route | Handler | Before Filters | After Filters |
+--------+----------------------------------+-------------------------------------------------+-------------------------------------------------+-------------------------------+
| GET | / | \App\Controllers\Home::index | honeypot csrf invalidchars | honeypot secureheaders |
| GET | pages/([^/]+) | \App\Controllers\Home::view_pages/$1 | honeypot csrf invalidchars | honeypot secureheaders |
| GET | users/register | \App\Controllers\Users::register | noauth honeypot csrf invalidchars | noauth honeypot secureheaders |
| GET | users/login | \App\Controllers\Users::login | noauth honeypot csrf invalidchars | noauth honeypot secureheaders |
| GET | users/members/dashboard | \App\Controllers\Users\Members::index | auth honeypot csrf invalidchars | auth honeypot secureheaders |
| GET | users/members/profile/([^/]+) | \App\Controllers\Users\Members::view_profile/$1 | auth honeypot csrf invalidchars | auth honeypot secureheaders |
| GET | images/gallery | \App\Controllers\Images\Gallery::index | auth honeypot csrf invalidchars | auth honeypot secureheaders |
| GET | images/view_image/([a-zA-Z0-9]+) | \App\Controllers\Images\Gallery::view_image/$1 | auth honeypot csrf invalidchars | auth honeypot secureheaders |
| GET | logout | \App\Controllers\Users::logout | honeypot csrf invalidchars | honeypot secureheaders |
| POST | users/register | \App\Controllers\Users::register | noauth honeypot csrf invalidchars throttle csrf | noauth honeypot secureheaders |
| POST | users/login | \App\Controllers\Users::login | noauth honeypot csrf invalidchars throttle csrf | noauth honeypot secureheaders |
| POST | users/admin//dashboard | \App\Controllers\admin::dashboard | auth honeypot csrf invalidchars throttle csrf | auth honeypot secureheaders |
| POST | images/view_image/([a-zA-Z0-9]+) | \App\Controllers\Images\Gallery::view_image/$1 | auth honeypot csrf invalidchars throttle csrf | auth honeypot secureheaders |
| CLI | ci(.*) | \CodeIgniter\CLI\CommandRunner::index/$1 | | |
+--------+----------------------------------+-------------------------------------------------+-------------------------------------------------+-------------------------------+
I get a bunch of php errors before the routes are shown.
I have some routes commented out and if I uncomment them, the rest of the site breaks. So effectively I cannot add any more routes....
PHP Code: <?php
namespace Config;
// Create a new instance of our RouteCollection class. $routes = Services::routes();
// Load the system's routing file first, so that the app and ENVIRONMENT // can override as needed. if (file_exists(SYSTEMPATH . 'Config/Routes.php')) { require SYSTEMPATH . 'Config/Routes.php'; }
/* * -------------------------------------------------------------------- * Router Setup * -------------------------------------------------------------------- */ $routes->setDefaultNamespace('App\Controllers'); $routes->setDefaultController('Home'); $routes->setDefaultMethod('index'); $routes->setTranslateURIDashes(TRUE); $routes->set404Override(); $routes->setAutoRoute(FALSE);
/* * -------------------------------------------------------------------- * Route Definitions * -------------------------------------------------------------------- */
// Default Route $routes->get('/', 'Home::index', ['as' => 'home']);
$routes->get('pages/(:segment)', 'Home::view_pages/$1', ['pages']);
// Login and Registration $routes->match(['get', 'post'], 'users/register', 'Users::register', ['filter' => 'noauth', 'as' => 'register']); $routes->match(['get', 'post'], 'users/login', 'Users::login', ['filter' => 'noauth', 'as' => 'login']);
// Admin Routes $routes->group('users/admin', ['filter' => 'auth'], function ($routes) { $routes->post('/dashboard', 'admin::dashboard'); });
// Users Routes $routes->group('users/members', ['filter' => 'auth'], function ($routes) { $routes->get('dashboard', 'Users\Members::index', ['as' => 'member_dashboard']); $routes->get('profile/(:segment)', 'Users\Members::view_profile/$1', ['as' => 'member_profile']); //$routes->get('edit_profile/(:segment)', 'Users\Members::edit_profile/$1', ['as' => 'edit_profile']); //$routes->get('manage_uploads/(:alphanum)', 'Users\Members::manage_uploads/$1', ['as' => 'manage_uploads']); //$routes->post('upload/(:segment)', 'Users\Members::upload_image/$1', ['as' => 'upload_image']); });
// Images Routes $routes->group('images', ['filter' => 'auth'], function ($routes) { $routes->get('gallery', 'Images\Gallery::index', ['as' => 'gallery']); $routes->match(['get', 'post'], 'view_image/(:alphanum)', 'Images\Gallery::view_image/$1', ['as' => 'view_image']); });
// Logout $routes->get('logout', 'Users::logout', ['as' => 'logout']);
/* * -------------------------------------------------------------------- * Additional Routing * -------------------------------------------------------------------- * * There will often be times that you need additional routing and you * need it to be able to override any defaults in this file. Environment * based routes is one such time. require() additional route files here * to make that happen. * * You will have access to the $routes object within that file without * needing to reload it. */ if (file_exists(APPPATH . 'Config/' . ENVIRONMENT . '/Routes.php')) { require APPPATH . 'Config/' . ENVIRONMENT . '/Routes.php'; }
|