I am new in Symfony and dont know how to install Symfony on my Xamp server. In symfony webm, when i want to download it, Through this command c:> php -r "readfile('http://symfony.com/installer');" > symfony`
then Access denied is occur on my cmd.
I am also beginner to symfony and had a same problem.
I think you also need to install composer first to make it working. I download the composer from https://getcomposer.org/download/ and then installed it. After that the symfony installer command worked for me. Try it and Good luck.
I just had a similar problem, it was not allowing me to download the symfony file (and displaying "Access denied") because I had a folder named Symfony. Renaming the folder solved the project problem.
Probably you do not have write access to your c:\ directory - it is default settings on Windows 7, 8, ....
Create some folder (for ex. c:\symfony_project) and try readfile('http://symfony.com/installer');" > symfony in that folder
For those who are still facing the problem, here how I solved mine. First you have to open XAMPP as administrator by clicking right click on XAMPP make sure its closed first after opening it as admin enable Apache and mysql then open shell, then head to htdocs and make sure there is composure installed and then paste the installing of symfony there. I hope it works after that.
Related
I have been trying for several days to deploy a Symfony site. All the files are well in the public folder with the .htaccess, I only need the dependencies for the site to be functional. The problem is that when I run the command
php composer.phar update
I get several error messages concerning my version of PHP.
The host is hostinger. I know the problem comes from the composer.json file and the version of the bundles but I don't know how to solve the problem.
Thanks
you need php version 8.1 as the message says. Normally, for a deployment you should not launch a composer update. It would rather be a composer install.
I contacted hostinger, and the problem is that the server was in PHP7 after changing to PHP8 it worked. Thank you all for your responses
I'm new to Drupal 8, I installed it locally on XAMPP my Mac machine, but in Verify Requirement I got a problem which is
The Settings file is not writable.
The Drupal installer requires write permissions to ./sites/default/settings.php during the installation process. The webhosting issues documentation section offers help on this and other topics.
I tried a lot on Internet but there isn't effective solution, Could anyone has knowledge in this.
In a terminal, run this command, where /path/to/drupal/root/ is just that: The path to the folder where you installed Drupal.
chmod 644 /path/to/drupal/root/sites/default/settings.php
have you tried:
Go to the path - sites/default/ and execute below command.
chmod -R 777 /files.
Check this link also https://www.drupal.org/forum/support/installing-drupal/2018-02-13/solved-the-directory-sitesdefaultfiles-is-not-writable
I tried to install Simple OAuth (https://www.drupal.org/project/simple_oauth) module in my drupal site running in a shared Godaddy hosting. My first mistake was not to read the installation guide instructing to install the module by using composer. Instead, I installed the module using the Extend=>install a module link within Drupal. Installing the simple_oauth and enabling the module crashed my site and there is no output from the site.
Then I realised there is something wrong with the installation and checked the error log file. The error logged was:
PHP Fatal error: Interface 'League\OAuth2\Server\Repositories\AccessTokenRepositoryInterface' not found in /home/-----------/public_html/drupal/modules/simple_oauth/src/Repositories/AccessTokenRepository.php on line 10
At that point I realised there is something wrong with the installation and checked the module instructions which states I should use composer to install the module. I tried to solve this problem by redoing the installation from the ssh by using composer and this command:
composer config repositories.drupal composer https://packages.drupal.org/8 && composer require drupal/simple_oauth:^3
Which did not work because GoDaddy shared hosting plan has only 512mb of rams and composer kills the command because of lack of memory.
I tried reading through and understand how Composer works. There were recommendations saying you should never use composer in a production site and you should run it on your computer and copy the composer.lock file which needs much less rams. I created a PHP server using XAMMP on my computer and copied the composer.json file to my computer and run composer update command in my computer. It downloaded the dependencies and stuff on my computer. And feeling I get the hang of it, I copied the composer.lock file in my drupal server, run composer update command and saw composer delete many stuff which I could not undo.
So my questions are: 1- Is there a way of rescuing this drupal site at this point? I deleted many composer dependencies as far as I can understand.
The new error log says: PHP Fatal error: Interface 'Symfony\Component\HttpKernel\HttpKernelInterface' not found in /home/--------/public_html/drupal/core/lib/Drupal/Core/DrupalKernelInterface.php on line 15
2- If not, which is fine as I was just beginning to setup the site. Is it possible for someone to explain the best way of handling this scenario? I mean installing a module using composer in a memory critical place. Or explain how composer works for layman. I read about all the dependency stuff but could not figure out how to use it for this scenario.
Thanks.
Please I need help on this project, I have wamp server to run the project on symphony.Look at the error display on my web browser ,when load the project from wamp server
If I run this code from my command prompt see the results php app/check.php
If I run this code from my command prompt see the results php app/check.php
php app/console server:run
It looks like you also have XAMPP installed on your system, or did at one time.
See the line that says
Configuration file used in PHP : C:\xampp\php\php.ini
^^^^^
I would suggest that you check your Windows PATH. I guess XAMPP might have added it's own PHP version into the PATH.
Alternatively you could uninstall XAMPP, but make sure you back everything up, code/databases etc before you uninstall it.
WAMPServer does not need anything placed on the Windows PATH, and if you do it makes switching versions of PHP far more complicated and prone to mistakes.
Have a look at this answer for how to make the PHP CLI as flexible as WAMPServer when it comes to running PHP code on different versions of PHP from the command line.
It also looks like you have not istalled composer. Follow the instructions on how to instal composed from the error messages. Or have a look at the composer site for help
So this is what I got when I try to add the Symfony tool (Symfony version : 3..)
The project was created from another machine and cloned into mine (Git)
I could make the necessary changes for composer.phar and php.exe when adding the Composer tool and I had no problem concerning that but when it comes to add the Symfony tool I got a " Failed to parse command output " error message and there are the details of the error
enter image description here
What should I do?
Thank you
As you can see, yours paths contain both "/" and "\". I think this happened because you create the project in a linux/unix machine and now you are working on Windows.
Path problem is in composer files. Is vendor folder committed in the repository? If yes, remove it and re run composer install.