💎一站式轻松地调用各大LLM模型接口,支持GPT4、智谱、星火、月之暗面及文生图 广告
# URL访问 ## URL访问 没有定义路由的情况下,那么url访问方式如下,配置了路由就按路由的规则来访问。 ``` <pre class="calibre16">``` http<span class="token1">:</span><span class="token">/</span><span class="token">/</span>serverName<span class="token">/</span>index<span class="token1">.</span>php(或者其它入口文件)<span class="token">/</span>控制器<span class="token">/</span>操作<span class="token">?</span>参数<span class="token3">1</span><span class="token">=</span>值 ``` ``` ## 隐藏入口文件 > 注意:您需要配置URL重写规则方能正常访问,部分`apache`服务无需配置,如不能正常访问前往[伪静态(url重写)](Wei%20Jing%20Tai.html) 章节中配置,前台的`index.php`在后台`站点配置->高级配置`中可以选择隐藏`index.php`。 1. 使用域名绑定的方式,在`config/app.php`文件下,可配置域名绑定应用,配置之后那么效果:[http://api.xxx.com/控制器/操作?参数1=值](http://api.xxx.com/%E6%8E%A7%E5%88%B6%E5%99%A8/%E6%93%8D%E4%BD%9C?%E5%8F%82%E6%95%B01=%E5%80%BC)``` <pre class="calibre20">``` <span class="token5">// 域名绑定(自动多应用模式有效)</span> <span class="token4">'domain_bind'</span> <span class="token">=</span><span class="token">></span> <span class="token1">[</span> <span class="token4">'api'</span> <span class="token">=</span><span class="token">></span> <span class="token4">'api'</span><span class="token1">,</span> <span class="token4">'*'</span> <span class="token">=</span><span class="token">></span> <span class="token4">'index'</span><span class="token1">,</span> <span class="token1">]</span><span class="token1">,</span> ``` ```