【发布时间】:2018-07-13 02:34:19
【问题描述】:
我在public 文件夹下有一张图片。
如何在 symfony4 中获取我的图像目录?
在 symfony 3 中,它相当于:
$webPath = $this->get('kernel')->getRootDir() . '/../web/';
【问题讨论】:
-
您好,欢迎来到 StackOverflow。请花一些时间阅读帮助页面,尤其是名为"What topics can I ask about here?" 和"What types of questions should I avoid asking?" 的部分。更重要的是,请阅读the Stack Overflow question checklist。您可能还想了解Minimal, Complete, and Verifiable Examples。