doushan7077 2016-08-25 18:42
浏览 45
已采纳

Softaculous启动symfony应用程序

So i have downloaded Softaculous (ampps), and from their dashboard I installed the symfony framework, and it created a symfony3 folder with all of the files in the www directory (with an index.php file in the root directory of symfony that only prints a welcome message).

When I access it through http://localhost/symfony3/ it shows the index.php (if i remove the index.php it just shows the tree of the symfony3 directory)

Is it possible to set my localhost to launch the app? If I run php bin/console server:start it launches my app on localhost with port 8000. Is it possible to set up Ampps to launch my app when it is accessed through localhost/symfony3/ ? Thanks in advance!

EDIT: So turns out I could do this just by editing the httpd70.conf file (ampps>conf>httpd70.conf)

find the <VirtualHost 127.0.0.1:80> block and change the <Directory "{$path}/www"> to the web folder in your app (in my case it was <Directory "{$path}/www/symfony3/web"> and do the same thing for DocumentRoot "{$path}/www" in the same block. Restart your Apache. You should now see your app when you just go to http://localhost/ (http://localhost/app_dev.php/)

  • 写回答

1条回答 默认 最新

  • douzhao7634 2016-08-26 07:56
    关注

    If I understood your question, you need to set up you web server with correct configuration file and to change permissions for Symfony project.

    It might be helpful (documentation for Symfony 2.8.*):

    1. Web server configuration.
    2. Symfony project file permissions.
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥40 复杂的限制性的商函数处理
  • ¥15 程序不包含适用于入口点的静态Main方法
  • ¥15 素材场景中光线烘焙后灯光失效
  • ¥15 请教一下各位,为什么我这个没有实现模拟点击
  • ¥15 执行 virtuoso 命令后,界面没有,cadence 启动不起来
  • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
  • ¥20 有关区间dp的问题求解
  • ¥15 多电路系统共用电源的串扰问题
  • ¥15 slam rangenet++配置
  • ¥15 有没有研究水声通信方面的帮我改俩matlab代码