text.attr("disabled",true);
text.attr("disabled",false);
text.attr("disabled",true);
text.attr("disabled",false);
第一種方法
$("#id").css('display','none');
$("#id").css('display','block');
第二種
$("#id")[0].style.display = 'none';
第三種
$('#mySelect')
.find('option')//找到option的元素
.remove()//刪除
.end()//結束
.append('<option value="whatever">text</option>')//新增一個元素
.val('whatever')//設定選取此元素
;
select
now()=>2012-05-21 15:31:49
CURDATE()=>2012-05-21
一般設定: opacity:0.8;
IE系列:filter:alpha(opacity=80);
$(document).bind("contextmenu",function(event){
return false;
});
//------------建立名叫temp_test的temptable 然後給值 來源是table1
$set_table='CREATE TEMPORARY TABLE `temp_test` ENGINE = MYISAM
SELECT a, b, c, d, e FROM `table1`';
//------------------------------------------------------------
mysql_query($set_table) or die(mysql_error().$set_table);
//--------------------------------寫入另一個表格資料
$set_table2='insert into `temp_test` SELECTa, b, c, d, e FROM `table2`';
mysql_query($set_table2) or die(mysql_error().$set_table2);
這通常是不經意的小錯誤
ex:你有載入其它js檔裡面有用到$()等相關語法,但你在主頁的時候
<script type="text/javascript" src="../js/xxx.js"></script><=這裡就會跳出error msg 因為裡面有用到$
<script type="text/javascript" src="http://www.google.com/jsapi"></script><=這兩段應該放在最上面
<script type="text/javascript">google.load("jquery","1");</script>
<input onkeydown= "if(event.keyCode==8) return false ">
<?php
if(isset($_GET['f'])){
$str=urldecode($_GET['f']);//解碼
$filename=substr($str,strrpos($str,'/')+1,strlen($str)-strrpos($str,'/'));//取出檔案名稱
$file="../xxx/".$filename;//檔案相對路徑
//指定類型