首页 \ 问答 \ 如何通过htaccess子域访问zf2中的公用文件夹[复制](How to access public folder in zf2 by htaccess subdomain [duplicate])

如何通过htaccess子域访问zf2中的公用文件夹[复制](How to access public folder in zf2 by htaccess subdomain [duplicate])

我是zf2的新手。 请帮我。 我在www.example.com/zend/目录上设置了我的新zend项目,但它没有直接调用。 它的电话是通过www.example.com/zend/public

如何直接访问www.example.com/zend/此网址。 我不想对虚拟主机进行任何更改。 我只想使用.htaccess文件。

请建议我解决方案。


This question already has an answer here:

I am new in zf2. Please help me. I setup my new zend project on www.example.com/zend/ directory but it didn't call directly. Its call via www.example.com/zend/public

How can i access directly access by www.example.com/zend/ this url. I don't want to any changes in virtual host. I want only use of .htaccess file.

Kindly suggest me solution.


原文:https://stackoverflow.com/questions/21452554
更新时间:2022-05-17 19:05

相关问答

更多
  • 我们目前正在尝试将我们的应用程序移植到Windows,并遇到了同样的问题。 底线,开箱即用的Ruby syslog将无法在Windows上运行(如https://www.ruby-forum.com/topic/78859#129379所示 ),因为它依赖于一些Unix功能(即syslog) (3) ) 其他人建议https://rubygems.org/gems/win32-eventlog/versions/0.6.3作为一种让您使用Windows事件日志API的方法。 或者,如果您不需要使用系统,则可 ...
  • 目前的问题是您希望执行的命令包含%字符。 根据crontab手册, %被认为是命令的结尾, %之后的所有内容都是该命令的标准输入。 如果您的命令需要%例如printf或date一般格式字符串,则需要转义% 。 man 5 crontab “第六”字段(行的其余部分)指定要运行的命令。 该行的整个命令部分,直到换行符或“ % ”字符将由/bin/sh或由cronfile的SHELL变量中指定的shell执行。 除非以反斜杠( \ )转义,否则命令中的“ % ”字符将被更改为换行符,并且第一个%后的所有数据将作 ...
  • 您可以将syslog设置$ActionFileDefaultTemplate从默认RSYSLOG_TraditionalFileFormat为RSYSLOG_FileFormat ,其时间戳为TIMESTAMP_ISO8601格式。 编辑/etc/rsyslog.conf文件。 #$ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat $ActionFileDefaultTemplate RSYSLOG_FileFormat 然后重新启动rsysl ...
  • 如果我做了一些更改,此代码在我的系统中正常工作: import logging.handlers as sh syslog_hdlr = sh.SysLogHandler(address='/dev/log', facility=sh.SysLogHandler.LOG_DAEMON) 和 root_logger.setLevel(logging.DEBUG) 因此,检查从config获取的日志记录级别并不比DEBUG更严格(例如:如果将其设置为INFO不会打印调试消息)。 如果您仍未在syslog上看 ...
  • 自GF 2.1以来,与syslog的连接已更改,其中使用了本机库“libutilforsyslog.so”。 在我看来,你现在必须在localhost上提供UDP端口514来接收GlassFish 3的系统日志消息。 com.sun.enterprise.server.logging.SyslogHandler创建一个这样的syslog实例: sysLogger = new Syslog("localhost"); //for now only write to this host ...这是com.s ...
  • 当您在syslog-ng中使用flags(no-parse)选项时,syslog-ng不会尝试解析消息的不同字段,而是将所有内容放入传入日志消息的MESSAGE字段中,并预先添加一个syslog头。 要删除这个头文件,请在你的syslog-ng目标中使用一个模板: template t_msg_only { template("${MSG}\n"); }; destination loghost { tcp("*.*.*.*" port(5140) template(t_msg_only) ); } 要 ...
  • 绝对的syslog ruby实现不允许我们使用自定义设施 。 syslog ruby实现使用syslog [C实现]( http://github.com/ruby/ruby/blob/trunk/ext/syslog/syslog.c#L36 )。 syslog C实现只允许我们使用非常短的设施名称列表: LOG_USER, LOG_MAIL, LOG_DAEMON, LOG_AUTH, LOG_SYSLOG, LOG_LPR, LOG_NEWS, LOG_UUCP, UUCP , LOG_CRON, L ...
  • 日期格式是RFC3339的更严格版本,提供诸如“2011-08-18T23:31:42Z”之类的字符串 我不确定strptime函数可以处理时区说明符(上面时间字符串中的Z),因此在你自己的函数中处理它可能更容易。 它肯定无法处理小数秒,因为struct tm不处理它们。 如果需要,您可以使用struct timespec来存储小数秒。 您可以使用strptime解析大部分格式: struct tm tm; time_t t char *extra; extra = strptime( tmstr, "%C ...
  • 根据https://blog.golang.org/playground , 要将用户程序与Google的基础架构隔离,后端在Native Client(或“NaCl”)下运行它们 并从https://golang.org/pkg/log/syslog/ 此程序包未在Windows上实现。 由于系统日志包已冻结,因此建议Windows用户使用标准库之外的包。 有关背景信息,请参阅https://golang.org/issue/1108 。 此计划未在计划9中实施。 此程序包未在NaCl(Native Cl ...
  • 如果使用syslog-ng,它会处理两个不同的时间戳: 当消息实际收到时 系统日志消息中包含的那个 这些可以通过宏访问。 您可以在https://www.balabit.com/sites/default/files/documents/syslog-ng-ose-3.7-guides/en/syslog-ng-ose-v3.7-guide-admin上阅读更多相关信息。 /html-single/index.html#reference-macros If you use syslog-ng, it ha ...

相关文章

更多

最新问答

更多
  • 您如何使用git diff文件,并将其应用于同一存储库的副本的本地分支?(How do you take a git diff file, and apply it to a local branch that is a copy of the same repository?)
  • 将长浮点值剪切为2个小数点并复制到字符数组(Cut Long Float Value to 2 decimal points and copy to Character Array)
  • OctoberCMS侧边栏不呈现(OctoberCMS Sidebar not rendering)
  • 页面加载后对象是否有资格进行垃圾回收?(Are objects eligible for garbage collection after the page loads?)
  • codeigniter中的语言不能按预期工作(language in codeigniter doesn' t work as expected)
  • 在计算机拍照在哪里进入
  • 使用cin.get()从c ++中的输入流中丢弃不需要的字符(Using cin.get() to discard unwanted characters from the input stream in c++)
  • No for循环将在for循环中运行。(No for loop will run inside for loop. Testing for primes)
  • 单页应用程序:页面重新加载(Single Page Application: page reload)
  • 在循环中选择具有相似模式的列名称(Selecting Column Name With Similar Pattern in a Loop)
  • System.StackOverflow错误(System.StackOverflow error)
  • KnockoutJS未在嵌套模板上应用beforeRemove和afterAdd(KnockoutJS not applying beforeRemove and afterAdd on nested templates)
  • 散列包括方法和/或嵌套属性(Hash include methods and/or nested attributes)
  • android - 如何避免使用Samsung RFS文件系统延迟/冻结?(android - how to avoid lag/freezes with Samsung RFS filesystem?)
  • TensorFlow:基于索引列表创建新张量(TensorFlow: Create a new tensor based on list of indices)
  • 企业安全培训的各项内容
  • 错误:RPC失败;(error: RPC failed; curl transfer closed with outstanding read data remaining)
  • C#类名中允许哪些字符?(What characters are allowed in C# class name?)
  • NumPy:将int64值存储在np.array中并使用dtype float64并将其转换回整数是否安全?(NumPy: Is it safe to store an int64 value in an np.array with dtype float64 and later convert it back to integer?)
  • 注销后如何隐藏导航portlet?(How to hide navigation portlet after logout?)
  • 将多个行和可变行移动到列(moving multiple and variable rows to columns)
  • 提交表单时忽略基础href,而不使用Javascript(ignore base href when submitting form, without using Javascript)
  • 对setOnInfoWindowClickListener的意图(Intent on setOnInfoWindowClickListener)
  • Angular $资源不会改变方法(Angular $resource doesn't change method)
  • 在Angular 5中不是一个函数(is not a function in Angular 5)
  • 如何配置Composite C1以将.m和桌面作为同一站点提供服务(How to configure Composite C1 to serve .m and desktop as the same site)
  • 不适用:悬停在悬停时:在元素之前[复制](Don't apply :hover when hovering on :before element [duplicate])
  • 常见的python rpc和cli接口(Common python rpc and cli interface)
  • Mysql DB单个字段匹配多个其他字段(Mysql DB single field matching to multiple other fields)
  • 产品页面上的Magento Up出售对齐问题(Magento Up sell alignment issue on the products page)