忘记他 关淑怡

In: 个人

9 2010

下载Generic Syntax Highlighter-》GESHi:http://sourceforge.net/projects/geshi/files/

上传:geshi.php 和geshi目录到 extensions /geshi

创建GeSHiHighlight.php 文件到extensions,内容如下:

 

[php]

地址:http://embedded.seattle.intel-research.net/wiki/index.php?title=GeSHi#GeshiHighlight.php

在:LocalSettings.php添加下面一行代码

include("extensions/GeSHiHighlight.php");

这样就可以在页面里面使用

<php><?php echo "Hello World!"; ?></php>

 

 

fckeditor安装:http://mediawiki.fckeditor.net/index.php/FCKeditor_integration_guide

 

 

Yii 是什么

Yii 是一个基于组件、用于开发大型 Web 应用的高性能 PHP 框架。它将 Web 编程中的可重用性发挥到极致,能够显著加速开发进程。Yii(读作“易”)代表简单(easy)、高效(efficient)、可扩展(extensible)。
需求

要运行一个基于 Yii 开发的 Web 应用,你需要一个支持 PHP 5.1.0 (或更高版本)的 Web 服务器。

对于想使用 Yii 的开发者而言,熟悉面向对象编程(OOP)会使开发更加轻松,因为 Yii 就是一个纯 OOP 框架。
Yii 适合做什么?

Yii 是一个通用 Web 编程框架,能够开发任何类型的 Web 应用。它是轻量级的,又装配了很好很强大的缓存组件,因此尤其适合开发大流量的应用,比如门户、论坛、内容管理系统(CMS)、电子商务系统,等等。
Yii 和其它框架比起来怎样?

和大多数 PHP 框架一样,Yii 是一个 MVC 框架。

Yii 以性能优异、功能丰富、文档清晰而胜出其它框架。它从一开始就为严谨的 Web 应用开发而精心设计,不是某个项目的副产品或第三方代码的组合,而是融合了作者丰富的 Web 应用开发经验和其它热门 Web 编程框架(或应用)优秀思想的结晶。

 

首先,我们来安装Yii框架。请在www.yiiframework.com上下载Yii框架文件(1.0.3版本或以上),下载后解压到/wwwroot/yii目录。确认加压后目录是这样的/wwwroot/yii/framework。

设置环境变量到 我的电脑-》右键属性-》高级-》环境变量

里面添加php到环境变量PATH里面,也就是php.exe存放路径 ,如 “C:/www/php5.3/”,这样就可以在cmd上面运行你的php命令


cmd执行:% YiiRoot/framework/yiic webapp WebRoot/testdrive 创建一个网站

 

数据库:

执行完后打开: /wwwroot/blog/protected/config/main.php

可以配置表前缀

 

首先在我们的配置文件中 /wwwroot/protected/config/main.php 中添加下面的代码:

<?php
return array(
    "params" => array(
        "dbPrefix" => "e_",
    ),
);
?>

 

return array(
    ......
    'components'=>array(
        ......
        'db'=>array(
            'class'=>'CDbConnection',
            'connectionString'=>'sqlite:/wwwroot/blog/protected/data/blog.db',
        ),
    ),
    ......
);

利用命令行创建 数据库操作

 

% /wwwroot/yii/framework/yiic shell /wwwroot/blog/index.php
Yii Interactive Tool v1.0
Please type 'help' for help. Type 'exit' to quit.
>> model User
......
>> model Post
......
>> model Tag
......
>> model Comment
......
>> crud Post
......
>> crud Comment
......
>> exit   

</p>
<h1>图片列表</h1>
<p><style>
    .dataView {
        width: 100%;
        height: 150px;
    }

    .dataView dl {
        border: 1px solid #dddddd;
        width: 130px;
        margin: 5px;
        float: left;
    }

    .dataView dl dt {
        text-align: center;
        padding: 5px;
    }

    .dataView dl a:hover img {
        border: 3px solid #dddddd;
    }

    .dataView dl dd {
    }
</style></p>
<div class="dataView">
	<dl>
		<dt><a href="#"><img src="test1.jpg" /></a></dt>
		<dd>标题</dd>
		<dd>其他</dd>
	</dl>
	<dl>
		<dt><img src="test1.jpg" /></dt>
		<dd>标题</dd>
		<dd>其他</dd>
	</dl>
</div>
<p>

</p>
<h1>左右表格</h1>
<p><style>
    .dataList {
        width: 100%;
        height: 150px;
    }

    /*DL, DT, DD TAGS LIST DATA*/
    .dataList dl {
        margin-bottom: 50px;
    }

    .dataList dl dt {
        background: #5f9be3;
        color: #fff;
        float: left;
        font-weight: bold;
        margin-right: 10px;
        padding: 5px;
        width: 100px;
    }

    .dataList dl dd {
        margin: 2px 0;
        padding: 5px 0;
    }
</style></p>
<div class="dataList">
	<dl>
		<dt>Name:</dt>
		<dd>John Don</dd>
		<dt>Age:</dt>
		<dd>23</dd>
		<dt>Gender:</dt>
		<dd>Male</dd>
		<dt>Day of Birth:</dt>
		<dd>12th May 1986</dd>
	</dl>
</div>
<p>

 <style type="text/css">
    .margins-removed {
        width: 100%;
        height: 150px;
    }

    .margins-removed dl {
        margin: 0;
        padding: 0;
    }

    .margins-removed dt {
        margin: 0;
        padding: 0;
        font-weight: bold;
    }

    .margins-removed dd {
        margin: 0 0 1em 0;
        padding: 0;
    }
</style></p>
<h1>文件列表</h1>
<div class="margins-removed">
	<dl>
		<dt>Green and Golden Bell Frog</dt>
		<dd>Nisl ut aliquip ex ea commodo consequat</dd>
		<dt>Bull Frog</dt>
		<dd>Lorem ipsum dolor sit amet elit...</dd>
		<dt>Spotted frog</dt>
		<dd>Facilisis at vero eros et accumsan</dd>
	</dl>
</div>
<p>

 <style>
    .border-around {
        width: 200px;
    }

    .border-around dl {
        margin: 2em 0;
        padding: 0;
        width: 20em;
    }

    .border-around dt {
        background-color: #131210;
        color: #959289;
        padding: .5em;
        font-weight: bold;
        text-align: center;
        text-transform: uppercase;
        border-left: 1px solid #131210;
        border-right: 1px solid #131210;
        border-top: 1px solid #131210;
    }

    .border-around dd {
        margin: 0 0 1em 0;
        background: #DBD8D8;
        text-align: center;
        padding: 1em .5em;
        font-style: italic;
        border-left: 1px solid #131210;
        border-right: 1px solid #131210;
        border-bottom: 1px solid #131210;
    }
</style></p>
<h1>&nbsp;</h1>
<div class="border-around">
	<dl>
		<dt>Green and Golden Bell Frog</dt>
		<dd>Nisl ut aliquip ex ea commodo consequat</dd>
		<dt>Bull Frog</dt>
		<dd>Lorem ipsum dolor sit amet elit...</dd>
		<dt>Spotted frog</dt>
		<dd>Facilisis at vero eros et accumsan</dd>
	</dl>
</div>
<p>

 <style>
    .table-display {
        width: 100%;
        height: 150px;
    }

    .table-display dl {
        float: left;
        width: 520px;
        margin: 1em 0;
        padding: 0;
        border-bottom: 1px solid #999;
    }

    .table-display dt {
        clear: left;
        float: left;
        width: 200px;
        margin: 0;
        padding: 5px;
        border-top: 1px solid #999;
        font-weight: bold;
    }

    .table-display dd {
        float: left;
        width: 300px;
        margin: 0;
        padding: 5px;
        border-top: 1px solid #999;
    }
</style></p>
<div class="table-display">
	<dl>
		<dt>Green and Golden Bell Frog</dt>
		<dd>Nisl ut aliquip ex ea commodo consequat</dd>
		<dt>Bull Frog</dt>
		<dd>Lorem ipsum dolor sit amet elit...</dd>
		<dt>Spotted frog</dt>
		<dd>Facilisis at vero eros et accumsan</dd>
	</dl>
</div>
<p>

 <style>
    .float-right {
        width: 100%;
        height: 150px;
    }

    .float-right dl {
        border: 1px solid #000;
        background-color: #ddd;
        width: 142px;
        text-align: center;
        padding: 0 0 10px 0;
        float: right;
        margin: 0 0 1em 1em;
    }

    .float-right dt {
        font-weight: bold;
        background-color: #131210;
        color: #959289;
        padding: 5px 10px;
        margin-bottom: 10px;
    }

    .float-right dd img {
        border: 1px solid #000;
        width: 100px;
        height: 100px;
    }

    .float-right dd {
        margin: 0;
        padding: 0 10px 5px 10px;
        font-size: 85%;
    }
</style></p>
<div class="float-right">
	<dl>
		<dt>Banksia flower</dt>
		<dd><img alt="" src="test1.jpg" /></dd>
		<dd><em>Banksius maximus</em></dd>
		<dd>Found off the coast of Australia</dd>
	</dl>
</div>
<p>

 <style>
    dl.event {
        margin: 2em 0;
        padding: 0;
        font-family: georgia, times, serif;
    }

    .event dt {
        position: relative;
        left: 0;
        top: 1.1em;
        width: 5em;
        font-weight: bold;
    }

    .event dd {
        border-left: 1px solid #000;
        margin: 0 0 0 6em;
        padding: 0 0 .5em .5em;
    }
</style></p>
<dl class="event">
	<dt>23 March</dt>
	<dd>Car club meeting</dd>
	<dd>7pm</dd>
	<dd>See a wide range of classic cars on display...</dd>
	<dt>13 June</dt>
	<dd>Cake stall</dd>
	<dd>12pm</dd>
	<dd>Cakes of every type. All proceeds go to the...</dd>
</dl>
<p>

var w=Ext.getCmp('east');
w.collapsed=w.collapse(); /*控制关闭*/
w.collapsed=w.expand();/*控制打开*/

/*页面判断你现在的是否显示缩略图*/
 if($.tooltip.blocked)
 {
                $("#你的ID").attr("checked", false);
 }
else{
                $("#你的ID").attr("checked", true);
}
/*页面判断你现在的是否显示缩略图*/

 /*通过block()方法开启与关闭*/
$("#你的ID").click(
          function(){
                        $.tooltip.block();
          }
);

把jquery.Galleria.js “[@rel=” 替换成 “[rel=” 就可以

只需要修改 472行:

return this.unbind('mouseover'.mouseover(_initialize));

基于JQUERY  swfupload : Multiple File Upload With Progress Bar Using jQuery
演示地址:http://demo.webdeveloperplus.com/jquery-swfupload/

http://webdeveloperplus.com/jquery/multiple-file-upload-with-progress-bar-using-jquery/

SWFUPLOAD 不依赖任何库

http://code.google.com/p/swfupload/downloads/list

CSS标准化命名规则

In: HTML

24 2010

About this blog

QK31欢迎你的到来.

Photostream

Flash MP3 Player JW

Here is the Music Player. You need to installl flash player to show this cool thing!

search_extends

 

2010年三月
« 二    
1234567
891011121314
15161718192021
22232425262728
293031  

分类目录

标签云


28
Unique
Visitors
Powered By Google Analytics