小编Dju*_*pen的帖子

htaccess - 子域作为 GET 参数

我的文件中已有以下内容.htaccess

RewriteEngine on

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?route=$1 [L,QSA]
Run Code Online (Sandbox Code Playgroud)

但我想添加这样的规则:

RewriteCond %{HTTP_HOST} ^(.+).example.com
RewriteRule ^(.*)% http://example.com/?name=%1&type=$1 [R,L]
Run Code Online (Sandbox Code Playgroud)

但如果没有它的绑定example.com,它就必须在任何域上工作。

apache subdomain .htaccess mod-rewrite

5
推荐指数
1
解决办法
4114
查看次数

Google搜索API.过滤许可证

我想在特定许可下使用Google API搜索图片.但是看看API文档,我无法理解如何正确使用它.我想搜索:

  • 免费使用或分享,甚至商业
  • 免费使用,分享或修改,甚至商业化

在我看到的文档中

  • cc_publicdomain
  • cc_attribute
  • cc_sharealike
  • cc_noncommercial
  • cc_nonderived

https://developers.google.com/custom-search/json-api/v1/reference/cse/list

有人能告诉我我的要求应该是什么样的吗?

google-search-api

5
推荐指数
1
解决办法
741
查看次数