doufeiqiong3515 2017-08-08 05:24
浏览 32
已采纳

是否可以在Mac上的xampp的htdocs中使用别名目录?

I installed Xampp on mac and I'm going to run my web application on local, which located on "/Data/MyApp/App".

I know I should put source codes inside htdocs. So I created an alias of "App" by right click -> Make Alias and put it to "Applications/Xampp/htdocs/". I changed alias name test. When I run localhost/test on chrome browser, I see empty screen but downloads unknown file test.

Instead, I paste whole sources(App) to htdocs with name test2 and localhost/test2 shows me correct screen according to the index.php inside of test2. Just note that file structures of test and test2 are exactly same.

Applications/Xampp/htdocs/test(alias)/index.php         // not working
Applications/Xampp/htdocs/test2(real folder)/index.php  // work well

What's wrong with this? Should I set something for making alias folder work inside htdocs?

  • 写回答

2条回答 默认 最新

  • douti9253 2017-08-08 12:22
    关注

    Well, after struggling a few hours, I found what I was wrong. I removed alias folder which I created by right click -> Make Alias and created new one with this command.

    cd /Applications/XAMPP/htdocs
    ln -s /Data/MyApp/App test
    

    I'm not sure what was wrong with original alias.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 聚类分析或者python进行数据分析
  • ¥15 逻辑谓词和消解原理的运用
  • ¥15 三菱伺服电机按启动按钮有使能但不动作
  • ¥15 js,页面2返回页面1时定位进入的设备
  • ¥50 导入文件到网吧的电脑并且在重启之后不会被恢复
  • ¥15 (希望可以解决问题)ma和mb文件无法正常打开,打开后是空白,但是有正常内存占用,但可以在打开Maya应用程序后打开场景ma和mb格式。
  • ¥20 ML307A在使用AT命令连接EMQX平台的MQTT时被拒绝
  • ¥20 腾讯企业邮箱邮件可以恢复么
  • ¥15 有人知道怎么将自己的迁移策略布到edgecloudsim上使用吗?
  • ¥15 错误 LNK2001 无法解析的外部符号