Undefined property: Index::$load

2014-07-17 11:05:35

I just started to develop a new site with CI.  For now, I only have three view files loaded on my index pages which are made strictly with HTML.  When I visit the index page, I get the following error:

*A PHP Error was encountered
*

*Severity: Notice
*

*Message: Undefined property: Index::$load
*

*Filename: controllers/index.php
*

Line Number: 7

And my controller index.php page as follows:

[php] load->helper(‘url’); $this->load->view(‘index’); } } ?>

[/php]

So i just checked, and i found class such Controller,CIBase,ci_initialize,Default and index are reserved words .

http://codeigniter.org.cn/userguide/general/reservednames.html

Of course, you can also use index as your class name, before your use,add the follow code  is OK:

[php]

load->helper(‘url’); $this->load->view(‘index’); } } ?>

[/php]

清除所有默认的CSS样式

做前端的必备,有朋友问我这个,我也刚好没有整理过,就攒了一下~应该挺全的,留着以后方便用: html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, font, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, center,

基于微信的【点歌台】功能开发

微网站,微社区,微店铺……现在是实打实的微时代啊。据我观测,随着移动互联时代的推进,web app将会走红,人们习惯于APP的操作界面,又不喜欢安装各种APP,所以基于云端的web app势必要走红,而微信的火热恰好为微网站提供了大显身手的舞台~废话太多了,进入主题吧,好久没写时间写博客了。 思路是用户提交关键字后,利用百度音乐API取出音乐地址,然后以音乐的格式返回。 百度API:http://box.zhangmen.baidu.com/x?op=12&count=1&title=小苹果$筷子兄弟$$ 可见API中需要提交音乐名称和歌手名字,而且歌手名字需要准确。像我这种只听歌,不记歌手的人来说,这接口基本算是废了。怎么办?easy,我的思路是先到比较大的音乐站点,提交歌名,然后抓取到返回结果中第一首歌的歌手名,其实一般大家熟知的歌,在搜索结果中排名都是第一位的。所以这样返回的歌手基本上90%就是你所需要的。 既然有了思路就开工呗,