关于页面切换有很多种方法,我这里只介绍我用的一种:
利用addSubview方法切换视图
example:
//跳转到投票主页
zcListViewController = [[ZcpsZcListViewController alloc] initWithStyle:UITableViewStyleGrouped initParameters:resultJSON];
// 导航控制类 manages the navigation of hierarchical content
UINavigationController *masterNav = [[UINavigationController alloc] initWithRootViewController:zcListViewController];
// 将导航控制类视图覆盖掉当前view
[[self view] addSubview:masterNav.view];