MAMP PHP yapılandırma dosyası yardım

3 Cevap php

Ben bulunan php.ini belgeyi değiştirmek zaman

Applications/MAMP/conf/php5/php.ini

Değişiklikler MAMP arayüzünde php bilgi sayfasında yansıtılmaz

NEDEN?

3 Cevap

Olası cevaplar:

  • You forgot to restart the Apache webserver after the change
  • PHP uses a php.ini from a different location (Check the PHPIniDir setting in your Apache config).

Etkili olması için php.ini değişiklikler için mAmp (Ya gerçekten herhangi bir Apache sunucusu) yeniden başlatmanız gerekir. GUI kullanarak mAmp yeniden başlatın.

Hala hiçbir değişiklik yaşıyorsanız, bu yanlış php.ini dosyayı düzenlerken mümkün. MAMP, her php sürümü kendi php.ini dosyası bulunuyor sahiptir.

Tamamen emin doğru php.ini dosyasını düzenlerken yapmak için aşağıdaki adımları kullanın:

  1. En sevdiğiniz metin editörü yeni. Php dosyası oluşturun.
  2. Tip

    <?php phpinfo(); ?> 
    

    ve mAmp en htdocs dizinine kaydedin.

  3. Index.php olarak kaydedin

  4. Emin MAMP çalıştığından emin olun!
  5. Start Safari, or any browser, and type "localhost:8888" into your URL bar.
  6. You should see a purple table filled with information about your apache server.
  7. The 6th row should be titled "Configuration File (php.ini)", and on the right of this, a path should be displayed to the php.ini file apache is currently using. It should look like this: "/Applications/MAMP/bin/php/php5.4.4/conf"
  8. Now, either use Finder to look browse to this location and edit the .ini file with Text Edit, or use Terminal.
  9. If you want to use Terminal, open a new window and type the following: 'cd (and then copy and paste the path you gained from step 6)'. It should look like something like this: 'cd /Applications/MAMP/bin/php/php5.4.4/conf'
  10. Şimdi ls yazın
  11. Typing ls will show you the files within the 'conf' directory. The correct php.ini file should be displayed amongst other files such as 'pear.conf'. If you can see 'php.ini', we're nearly there. If not, you've gone wrong somewhere, so read over the previous steps.
  12. Now type 'sudo nano /Applications/MAMP/bin/php/php5.4.4/conf/php.ini'
  13. Bunun için sorar ve terminal şifrenizi vermek
  14. The php.ini file will be opened in Terminal's integrated text-editor, nano. Edit it, and save it using Nano.
  15. Simply quit terminal. 15) Restart Apache using MAMP's GUI 16) Browse to localhost:8888 in your favourite browser. Your changes should be reflected in the configuration screen.

Bu talimatları takip etmek zor olabilir anlıyorum, ama bu çalışma almak için ekip izleyici veya bir şey kullanmak istiyorsanız sadece bana ulaşın! İyi şanslar

Bu MAMP kurulumda 2 php.ini dosyaları var gibi görünüyor. Benim durumumda ayrıştırılması gibi görünüyor, bir config/ klasörüne ama bin/php/php5.3.14/conf/php.ini değil