dsieyx2015 2013-12-12 21:16
浏览 71
已采纳

隐藏父文件夹中所有子文件夹的列表,但显示子文件夹的内容

Hide listing of all childfolders in parent folder but show childfolder's content, or simply writing something like below in the .htaccess of parent folder...

IndexIgnore * (except childfolders+their content)

Directory structure:

parent >

child 1->something.pdf
child 2->anything.pdf
...
...
child n->another-something.pdf

now to the user when he goes to parent, then nothing should be visible but when he goes to parent/child [1 to n]/ he should see the corresponding pdf.

(also childfolders are dynamically generated and are very large in number !)

  • 写回答

1条回答 默认 最新

  • douxiajia6309 2013-12-12 22:31
    关注

    Place this code in parent/.htaccess:

    RewriteEngine on
    
    RewriteRule ^$ - [F]
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 随身WiFi网络灯亮但是没有网络,如何解决?
  • ¥15 gdf格式的脑电数据如何处理matlab
  • ¥20 重新写的代码替换了之后运行hbuliderx就这样了
  • ¥100 监控抖音用户作品更新可以微信公众号提醒
  • ¥15 UE5 如何可以不渲染HDRIBackdrop背景
  • ¥70 2048小游戏毕设项目
  • ¥20 mysql架构,按照姓名分表
  • ¥15 MATLAB实现区间[a,b]上的Gauss-Legendre积分
  • ¥15 delphi webbrowser组件网页下拉菜单自动选择问题
  • ¥15 linux驱动,linux应用,多线程