我是Android开发的新手,我正在尝试安装Android Studio Bundle:http://developer.android.com/sdk/
我从http://www.oracle.com/technetwork/java/javase/downloads/index.html下载并安装了JDK 8u25
我首先安装了JDK,然后尝试启动从Android.com下载的android-studio-bundle-135.1641136.exe文件但是当我运行它时出现以下弹出错误:无法提升[error:]
还没有安装,我已经遇到问题..请帮忙!
真诚地感谢您提供的任何帮助.
我是CodeIgniter的新手并完成了我的第一个项目.但是,在我把它放在我的托管网站上之前,我想使用CodeIgniter在config文件夹中提供的routes.php文件来清理URL.
我的网站将使用以下网址加载:
http://fakehost:8888/TheWorksPlumbing/index.php/theWorksPlumbingController/index/home
http://fakehost:8888/TheWorksPlumbing/index.php/theWorksPlumbingController/index/about
http://fakehost:8888/TheWorksPlumbing/index.php/theWorksPlumbingController/index/services
Run Code Online (Sandbox Code Playgroud)
它还将使用以下默认控制器URL加载主页: http://fakehost:8888/TheWorksPlumbing/
但是,我希望网站的每个页面都有一个网址,但无法让它工作.例如,我想:
http://fakehost:8888/TheWorksPlumbing/home
http://fakehost:8888/TheWorksPlumbing/about
http://fakehost:8888/TheWorksPlumbing/services
Run Code Online (Sandbox Code Playgroud)
以下是theWorksPlumbingController控制器文件的代码:
class TheWorksPlumbingController extends CI_Controller {
public function index($page = 'home'){
if ( !file_exists('application/views/'.$page.'.php') ) {
show_404();
}
$this->load->view('templates/header');
$this->load->view($page);
$this->load->view('templates/footer');
}
}
Run Code Online (Sandbox Code Playgroud)
这是我的routes.php文件中的代码不起作用:
$route['default_controller'] = "theWorksPlumbingController";
$route['404_override'] = '';
$route['(:any)'] = "index.php/theWorksPlumbingController/index";
Run Code Online (Sandbox Code Playgroud)
我需要添加或更改以使网站只加载/ home或/ about或/ services?
我被困住了,似乎无法解决我的问题.我正在尝试首次使用Codeigniter编写基本的"联系我们表格".我的观点上的表格看起来像这样......
<div style='float: left; padding-right: 55px; padding-left: 35px;'>
<?php
$this->load->helper('form');
echo form_open('pages/emailsender'); ?>
Contact Us:<br />
<?php
echo form_input('name', 'Enter Your Name');
echo form_input('email', 'Enter Your Email');
echo "<br />";
echo form_textarea('message', 'Enter your message here, thanks for taking the time to contact us!');
echo "<br />";
echo form_submit('submit', 'Send Message!');
echo form_reset('reset', 'Reset Form');
echo form_close();
?>
</div>
Run Code Online (Sandbox Code Playgroud)
和我的控制器pages.php看起来像..
<?php
class Pages extends CI_Controller {
public function index(){
$this->load->view('templates/header');
$this->load->view('home');
$this->load->view('templates/footer');
}
public function home(){
$this->load->view('templates/header');
$this->load->view('home');
$this->load->view('templates/footer');
} …Run Code Online (Sandbox Code Playgroud)