
[CodeIgniter] Web Framework 非官方繁體中文討論區成立

介紹一堆美食日記,生活日記,電腦筆記
$(":input[value=delete]").click( function(e){ $(this).parent().parent().remove(); } );原來看 Tony 是直接網頁載入 button,而我的狀況是後來人工點選產生的 button 跟 tr 標籤,所以問了一下 Tony,發現了一個解決方法,那就是利用 Events/live,這是新增在 1.3 版本的,他可以 bind 在現有的標籤,或者是未來新增的標籤上面,可以榜定的事件如下:
click, dblclick, mousedown, mouseup, mousemove, mouseover, mouseout, keydown, keypress, keyup沒有支援底下的事件:
blur, focus, mouseenter, mouseleave, change, submitContinue reading “[jQuery] Events/live Click”
$query = $this->db->query("SELECT a.news_id, a.news_name, a.add_time FROM project_news a left join project_news_categories b on a.categories_id = b.categories_id where news_id = '".$id."' order by news_top DESC, a.add_time DESC ");利用 Active Record Class 可以改寫成:
$this->db->select('a.news_id, a.news_name, a.add_time'); $this->db->from('project_news a'); $this->db->join('project_news_categories b', 'a.categories_id = b.categories_id', 'left'); $this->db->order_by("news_top DESC, a.add_time DESC"); $this->db->where('news_id', $id);Continue reading “[PHP] Web Framework : CodeIgniter MySQL Database 使用教學”
#!/usr/local/bin/python for i in range(1,10): for j in range(1,10): print "%d*%d=%s" % (i,j,i*j), print ""Continue reading “[高雄] Python 入門 – Python tutorial”