fold all codes

11 2011 档案

摘要:/home/hylent/cpp/socket/login.cpp#include<iostream>#include<fstream>#include<string>#include<cstring>//memset#include<sys/types.h>#include<sys/socket.h>#include<arpa/inet.h>//in_addr#include<netdb.h>//hostentusingnamespacestd;constintHostPort=80;constc 阅读全文
posted @ 2011-11-05 20:52 hylent 阅读(1070) 评论(0) 推荐(0) 编辑
摘要:太简单了,功能也就不完善。拖动的时候,如果鼠标移动的太快,就乱了。/htdocs/html/dd.html<html><head><metahttp-equiv="Content-Type"content="text/html;charset=utf-8"/><title>js拖动</title><styletype="text/css">#test{width:200px;height:150px;border:1pxsolid#ccc;position:abs 阅读全文
posted @ 2011-11-03 13:03 hylent 阅读(178) 评论(0) 推荐(0) 编辑
摘要:/qt/musicplayer/main.cpp#include<QtGui/QApplication>#include"widget.h"intmain(intargc,char*argv[]){QApplicationa(argc,argv);a.setApplicationName("musicplayer");Widgetw;w.show();returna.exec();}/qt/musicplayer/widget.h#ifndefWIDGET_H#defineWIDGET_H#include<QWidget>#inc 阅读全文
posted @ 2011-11-03 11:59 hylent 阅读(1525) 评论(0) 推荐(0) 编辑
摘要:/htdocs/h/index.php<?phpset_time_limit(100);$baseUri=substr($_SERVER['SCRIPT_NAME'],0,strrpos($_SERVER['SCRIPT_NAME'],'/')+1);if(!isset($_GET['id'])||intval($_GET['id'])<1){echo'<?xmlversion="1.0"encoding="UTF-8"?><!DOCTY 阅读全文
posted @ 2011-11-03 11:44 hylent 阅读(1815) 评论(0) 推荐(0) 编辑
摘要:/cgi-bin/getfile.cpp#include<iostream>#include<fstream>#include<string>#include<cstdlib>usingnamespacestd;voidhtmlspecialchars(conststring&s,string&ret){ret="";for(string::const_iteratori=s.begin();i!=s.end();i++){switch(*i){case'<':ret+="&am 阅读全文
posted @ 2011-11-03 11:38 hylent 阅读(405) 评论(0) 推荐(0) 编辑
摘要:m.cpp#include <iostream>#include <fstream>#include <string>#include <sstream>using namespace std;int main(){ ifstream in("in.txt"); string s; getline(in, s); // read for length int length; { istringstream sin(s); sin >> length; } // dim array double** arr = n. 阅读全文
posted @ 2011-11-02 23:31 hylent 阅读(158) 评论(0) 推荐(0) 编辑
摘要:a.cpp#include <iostream>#include <vector>#include <fstream>using namespace std;int ne, nj, njt;vector<int*> jh; // 2vector<int*> jtx; // 4vector<int*> jw; // 3vector<int*> mw; // 6void qjw(){ int counter = 1; for (int i = 0; i < nj; ++i) { int *toAdd = ne 阅读全文
posted @ 2011-11-02 23:13 hylent 阅读(265) 评论(0) 推荐(0) 编辑
摘要:不错,可以自定义许多东西。 阅读全文
posted @ 2011-11-02 22:32 hylent 阅读(105) 评论(0) 推荐(0) 编辑