Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CI页面跳转问题 #2

Open
Wscats opened this issue Nov 18, 2016 · 0 comments
Open

CI页面跳转问题 #2

Wscats opened this issue Nov 18, 2016 · 0 comments

Comments

@Wscats
Copy link
Owner

Wscats commented Nov 18, 2016

官方文档的URL辅助函数
使用的时候先引入url辅助函数

$this->load->helper('url');

然后可以在对应的控制器和视图上拼接新的url

<a href="<?php echo site_url('form_delete');?>">删除</a>

默认在没有设置config的config.php的$config['base_url']前,跳转的域名是会显示
image
::1其实是ipv6本地环回地址简写,但如果觉得不好看,可以在config.php重新设置$config['base_url'],例如下面这样

$config['base_url'] = 'http://localhost/CI/myCi/';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant