接上回,上回我们讲到MainActivity里面将所有的宋词标题和作者显示到界面的ListView中去,我们接下来的工作是通过点击ListView的Item跳转到ContentActivity里面去显示单个宋词的全部内容,跳转代码如下:
// 为ListView的Item设置点击监听器
mListView.setOnItemClickListener(new OnItemClickListe...
分类:
移动开发 时间:
2014-05-08 11:14:25
阅读次数:
519
@using(Html.BeginForm("AddNews","NewsMgr",FormMethod.Post,new{enctype="multipart/form-data"}))前台页面上使用form提交,但是HtmlAttribute必须有这个属性enctype="multipart/form-data"否则上传时提交到后台的Request.Files一直为空,count是0.后台页面收到请求后便可以..
分类:
Web程序 时间:
2014-05-08 10:52:02
阅读次数:
765
/* 内存管理原则: 1.谁alloc,new或copy,谁就进行一次release
2.谁retain,谁release */#import @interface Person : NSObject { Car * _car; int
_age;}- (void)setCar:(Car *)car...
分类:
其他好文 时间:
2014-05-08 10:18:57
阅读次数:
284
#import @interface Person : NSObject{ /*
成员变量作用域有四种: 1.@public:能在程序中任何地方直接访问成员变量 2.@protect:能在当前类和子类中直接访问成员变量(默认情况下)
3.@provate:只能在当前类中直接访问成员变量(@prope...
分类:
其他好文 时间:
2014-05-08 09:14:29
阅读次数:
500
1.AJAX
是一种在无需重新加载整个网页的情况下,能够更新部分网页的技术。2.XMLHttpRequest 是 AJAX 的基础。3. 创建 XMLHttpRequest
对象的语法: variable=new XMLHttpRequest();.老版本的 Internet Explorer (....
分类:
其他好文 时间:
2014-05-08 08:54:14
阅读次数:
287
题目链接Given a set of non-overlapping intervals,
insert a new interval into the intervals (merge if necessary).You may assume
that the intervals were ini...
分类:
其他好文 时间:
2014-05-08 08:40:51
阅读次数:
367
Intent intent = new Intent();ComponentName cmp =
new
ComponentName("com.sina.weibo","com.sina.weibo.EditActivity");intent.setAction(Intent.ACTION_MAIN...
分类:
微信 时间:
2014-05-08 08:35:41
阅读次数:
736
一次通过: 1 public class Solution { 2 public int
romanToInt(String s) { 3 int sum = 0; 4 int[] num = new int[s.length()]; 5 if...
分类:
其他好文 时间:
2014-05-08 08:24:26
阅读次数:
233
解决V9缩略图模糊/libs/classes/image.class.php注释掉elseimagecopyresized($thumbimg,$srcimg,0,0,$psrc_x,$psrc_y,$width,$height,$srcwidth,$srcheight);另将102行的$image...
分类:
Web程序 时间:
2014-05-08 07:43:20
阅读次数:
391
//初始化对象并发出XMLHttpRequest请求var xmlHttp;function
getXmlHttp(){ if(window.ActiveXObject){ xmlHttp = new
ActiveXObject("MICROSOFT.XMLHTTP"); ...
分类:
其他好文 时间:
2014-05-08 07:19:46
阅读次数:
378