1.在建数据库时要用如下语句:
Create DATABASE JForum DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
For detailed error information, please see the HTML source code, and contact the forum Administrator.
java.sql.SQLException: Illegal mix of collations (latin1_swedish_ci,COERCIBLE) and (utf8_general_ci,IMPLICIT) for operation 'UNION'
Query being executed when exception was thrown:
Create DATABASE JForum DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
For detailed error information, please see the HTML source code, and contact the forum Administrator.
java.sql.SQLException: Illegal mix of collations (latin1_swedish_ci,COERCIBLE) and (utf8_general_ci,IMPLICIT) for operation 'UNION'
Query being executed when exception was thrown:
Tags: jforum
使用html:radio做选中常用两种方法,一种是order中属性给其默认值,二种在js页面使用js赋值
还有一种更加简单的,使用传统html表单的type=radio,修改name成相应属性,一样可以在action中拿到值,如下:
姓名:<html:text property="order.uname"></html:text>
性别:男<input type="radio" name="order.sex" value="男" checked="checked"></input>
女<input type="radio" name="order.sex" value="女"></input>
还有一种更加简单的,使用传统html表单的type=radio,修改name成相应属性,一样可以在action中拿到值,如下:
姓名:<html:text property="order.uname"></html:text>
性别:男<input type="radio" name="order.sex" value="男" checked="checked"></input>
女<input type="radio" name="order.sex" value="女"></input>
Tags: radio
dede的代码:几好用的...
//此函数在UTF8版中不能直接调用
function cn_substrGb($str,$slen,$startdd=0){
$restr = "";
$c = "";
$str_len = strlen($str);
if($str_len < $startdd+1) return "";
if($str_len < $startdd + $slen || $slen==0) $slen = $str_len - $startdd;
//此函数在UTF8版中不能直接调用
function cn_substrGb($str,$slen,$startdd=0){
$restr = "";
$c = "";
$str_len = strlen($str);
if($str_len < $startdd+1) return "";
if($str_len < $startdd + $slen || $slen==0) $slen = $str_len - $startdd;
Tags: dede