I recently installed git for sharing cakephp 3.0 code but after pushing and pulling the browser seems blank then I edit .gitignore file and remove all commands excluding /tem/* because I didn't worry about security right now and then I shared my code and got this error:
Fatal error: Class 'Psr\Log\AbstractLogger' not found in /var/www/html/project/bmw12/vendor/cakephp/cakephp/src/Log/Engine/BaseLog.php on line 24
Fatal error: Uncaught RuntimeException: Could not load class Cake\Log\Engine\FileLog in /var/www/html/project/bmw12/vendor/cakephp/cakephp/src/Log/LogEngineRegistry.php:57 Stack trace: #0
/var/www/html/project/bmw12/vendor/cakephp/cakephp/src/Core/ObjectRegistry.php(91): Cake\Log\LogEngineRegistry->_throwMissingClassError('Cake\\Log\\Engine...', NULL) #1
/var/www/html/project/bmw12/vendor/cakephp/cakephp/src/Log/Log.php(198): Cake\Core\ObjectRegistry->load('Cake\\Log\\Engine...', Array) #2
/var/www/html/project/bmw12/vendor/cakephp/cakephp/src/Log/Log.php(180): Cake\Log\Log::_loadConfig() #3
/var/www/html/project/bmw12/vendor/cakephp/cakephp/src/Log/Log.php(360): Cake\Log\Log::_init() #4
/var/www/html/project/bmw12/vendor/cakephp/cakephp/src/Error/BaseErrorHandler.php(284): Cake\Log\Log::write(3, 'Fatal Error (1)...') #5
/var/www/html/project/bmw12/vendor/cakephp/cakephp/src/Error/BaseErrorHandler.php(216): Cake\Error\BaseErrorHandler->_logError(3, Array) #6
/var/www/html/project/bmw12/vendor/cakephp/cakephp/src/Error/Bas in /var/www/html/project/bmw12/vendor/cakephp/cakephp/src/Log/LogEngineRegistry.php on line 57
I m posting answer for my question, actually its a permission issue in Linux and therefore it doesn't allow to share all the file while using push command in git but while using it doesn't show any error but it doesn't work properly on other end.
Related
I installed laravel-snappy using the official documentation but when i try to run my application i get this error.
Fatal error: Uncaught Error: Call to undefined method Illuminate\Foundation\Application::configure() in D:\php\myapp\vendor\barryvdh\laravel-snappy\src\LumenServiceProvider.php:21 Stack trace: #0 D:\php\myapp\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(574): Barryvdh\Snappy\LumenServiceProvider->register() #1 D:\php\myapp\bootstrap\app.php(35): Illuminate\Foundation\Application->register(Object(Barryvdh\Snappy\LumenServiceProvider)) #2 D:\php\myapp\public\index.php(36): require_once('D:\php\myapp\bo...') #3 D:\php\myapp\server.php(21): require_once('D:\php\myapp\pu...') #4 {main} thrown in D:\php\myapp\vendor\barryvdh\laravel-snappy\src\LumenServiceProvider.php on line 21
Another one :
when i use anchor tag for routing a download like below
Download PDF
It goes to
http://localhost:8000/%7B%7B%20route('generate-pdf',['download'=%3E'pdf'])%20%7D%7D
why is it like that?
Why do i get this error and how do i resolve it? thanks in advance.
I am trying to migrate a live WordPress site to my localhost environment. And I believe that the PHP version on current hosting server is higher than my localhost environment version, which is causing some issue while migrating. As I don't know much about SQL code as well as how to interpret the error log, can you guide me on what I should be doing to rectify the error?
Followed is the error message I am getting:
Fatal error: Uncaught Error: Call to undefined function mysql_escape_string() in C:\xampp\htdocs\shag\wp-content\themes\twentyseventeen\functions.php:60
Stack trace:
#0 C:\xampp\htdocs\shag\wp-settings.php(425): include()
#1 C:\xampp\htdocs\shag\wp-config.php(89): require_once('C:\\xampp\\htdocs...')
#2 C:\xampp\htdocs\shag\wp-load.php(37): require_once('C:\\xampp\\htdocs...')
#3 C:\xampp\htdocs\shag\wp-blog-header.php(13): require_once('C:\\xampp\\htdocs...')
#4 C:\xampp\htdocs\shag\index.php(17): require('C:\\xampp\\htdocs...')
#5 {main} thrown in C:\xampp\htdocs\shag\wp-content\themes\twentyseventeen\functions.php on line 60
define('WP_USE_EXT_MYSQL', true);
Would you please define above code in your wp-config.php? And check it. I think it's helpful for you.
I just moved my website to a separate server in an attempt to make sure that when I push the site to the production server everything transitions smoothly. Unfortunately, the site appears blank when I visit the link unless I add something like "echo 'hello';" to the index.php page, nothing is being logged in the laravel storage files (even though the permissions are recursively set to 777), and I get this error:
nickstaging#ubuntuStaging:/var/www/html/almost_acceptable$ php artisan config:cache
PHP Fatal error: Uncaught ReflectionException: Class log does not exist in /var
/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php:741
Stack trace:
#0 /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php(741): ReflectionClass->__construct('log')
#1 /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php(631): Illuminate\Container\Container->build('log', Array)
#2 /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(674): Illuminate\Container\Container->make('log', Array)
#3 /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php(842): Illuminate\Foundation\Application->make('log')
#4 /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php(805): Illuminate\Container\Container->resolveClass(Object(ReflectionParameter))
#5 /var/www/html/almost_acceptable/vendor/laravel/framework/src/I in /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 741
PHP Fatal error: Uncaught ReflectionException: Class log does not exist in /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php:741
Stack trace:
#0 /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php(741): ReflectionClass->__construct('log')
#1 /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php(631): Illuminate\Container\Container->build('log', Array)
#2 /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(674): Illuminate\Container\Container->make('log', Array)
#3 /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php(842): Illuminate\Foundation\Application->make('log')
#4 /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php(805): Illuminate\Container\Container->resolveClass(Object(ReflectionParameter))
#5 /var/www/html/almost_acceptable/vendor/laravel/framework/src/I in /var/www/html/almost_acceptable/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 741
I cannot, for the life of me, figure out why it's occurring. It is recorded in the apache log file on the server. The site still runs correctly on my local homestead vm that I have running for general testing, and I tried reuploading all of the files to the server but nothing has worked.
If anyone has any idea why this is occurring, that would be great and I would very much appreciate it! Thanks in advance!
Edit
Installing php-mysql did not fix the problem and there was no difference in the error afterwards.
The most common problem is either you have spaces in your .env file or a wrong value in one of your config files.
More info here:
https://laracasts.com/discuss/channels/general-discussion/class-log-does-not-exist
i have to use google api in my project using php
the project : using google search engine and gathering urls and their source pages
i downloaded google api php client and i followed what ever is written here
https://code.google.com/p/google-api-php-client/
after running i ge this error:
Fatal error: Uncaught exception 'Google_ServiceException' with message 'Error calling GET https://www.googleapis.com/plus/v1/people/me/activities/public?key=[REDACTED]: (403) Access Not Configured' in C:\xampp\htdocs\google-api-php-client\src\io\Google_REST.php:66 Stack trace: #0 C:\xampp\htdocs\google-api-php-client\src\io\Google_REST.php(36): Google_REST::decodeHttpResponse(Object(Google_HttpRequest)) #1 C:\xampp\htdocs\google-api-php-client\src\service\Google_ServiceResource.php(186): Google_REST::execute(Object(Google_HttpRequest)) #2 C:\xampp\htdocs\google-api-php-client\src\contrib\Google_PlusService.php(58): Google_ServiceResource->__call('list', Array) #3 C:\xampp\htdocs\googleapitest.php(31): Google_ActivitiesServiceResource->listActivities('me', 'public') #4 {main} thrown in C:\xampp\htdocs\google-api-php-client\src\io\Google_REST.php on line 66
i am completely confused and don't know what to do
That error often means you're not matching your access requirements in the API console - i.e. if you have IP or referrer restrictions configured.
Just remove your developer key and add the scope
'www.googleapis.com/auth/userinfo.email',
'www.googleapis.com/auth/userinfo.profile',
'www.googleapis.com/auth/plus.login',
'www.googleapis.com/auth/plus.me'));
I have just upgraded a couple of sites from an earlier release of SS3 to the 3.0 stable build (CMS and Sapphire). Now, when I try to dev/build I am getting the following error:
PHP Fatal error: Uncaught exception 'SS_DAG_CyclicException' with message 'DAG has cyclic requirements' in /Users/fraser/Documents/Work/HallPass/sapphire/core/DAG.php:73
Stack trace:
#0 /Users/fraser/Documents/Work/HallPass/sapphire/core/manifest/ConfigManifest.php(272): SS_DAG->sort()
#1 /Users/fraser/Documents/Work/HallPass/sapphire/core/manifest/ConfigManifest.php(144): SS_ConfigManifest->sortYamlFragments()
#2 /Users/fraser/Documents/Work/HallPass/sapphire/core/manifest/ConfigManifest.php(75): SS_ConfigManifest->regenerate(false)
#3 /Users/fraser/Documents/Work/HallPass/sapphire/core/Core.php(275): SS_ConfigManifest->__construct('/Users/fraser/D...', false, false)
#4 /Users/fraser/Documents/Work/HallPass/sapphire/main.php(62): require_once('/Users/fraser/D...')
#5 {main}
thrown in /Users/fraser/Documents/Work/HallPass/sapphire/core/DAG.php on line 73
Everything else works fine however, it's just when I do anything in /dev. I have made some changes and need to regenerate the manifest on these sites.
I have also tried a clean install of SS and am getting the same issue.
Any ideas?
This was a bug in the CMS and Sapphire code. I raised the issue on open.silverstripe.org and it has since been corrected. #7817 on open.silverstripe.org