当前位置:首页 » 操作系统 » fh源码模版

fh源码模版

发布时间: 2023-07-12 18:56:01

1. asp的网站答题之后才能注册的源码

<%
wt1="中国是那年主办奥运会?"
wt2="香港是那年回归的?"
hd1="2008"
hd2="1997"
filename=Request.ServerVariables("URL")

if request("action")="" then

%>

<table align="center" width="80%" height="101" border="0" cellspacing="1" cellpadding="6" class="a2">
<FORM name="form" onsubmit="return Check();" action="<% =filename %>?action=new" method="post">
<tr height="25"><td>网站需要设置若干问题来有选择性的限制会员注册 最好是每一个或者两个问题回答之后引导进入注册页面</td></tr>
<tr><td>

问题1:<%=wt1%><BR>
回答1<INPUT type=text name=f_hd1 maxLength=5 size=18><BR>
问题2:<%=wt2%><BR>
回答2<INPUT type=text name=f_hd2 maxLength=5 size=18><BR>
<input type="submit" name="cm" value="下一步" ></td></tr>
</table>
</FORM>

<% end if
if request("action")="new" then

f_hd1=trim(Request("f_hd1"))
f_hd2=trim(Request("f_hd2"))

if f_hd1<>hd1 and f_hd2<>hd2 then
Response.Write "<script language=javaScript>{alert('对不起,问题回答错误。');location.href = 'javascript:history.go(-1)';}</script>"
Response.End
else
Response.Redirect "1.asp" '如果问题都回答准确后转到正式的用户注册页
end If

End If
%>

2. 汇编语言问题 在单片机LED上显示数字(0~9)的源代码是什么啊

这个有查表的方法来做:
;;8051
;;晶体振荡F=12Mhz
;;;
KEY32
REG
P3.2
;
ORG
0000H
AJMP
MAIN
ORG
0003H
RETI
RETI
ORG
000BH
RETI
ORG
0013H
RETI
RETI
ORG
001BH
RETI
ORG
0023H
RETI
DB
C0H
;0
ADRRESS
0024H
DB
F9H
;1
DB
A4H
;2
DB
B0H
;3
DB
99H
;4
DB
92H
;5
DB
82H
;6
DB
F8H
;7
DB
80H
;8
DB
90H
;9
MAIN:
MOV
R0,#7FH
;
CLR
A
;
$CL
MOV
@R0,A
;
DJNZ
R0,$CL
;初始化
MOV
SP,#60H
;初始化
MOV
20H,#00H
;最开始设定为0
MOV
DPTR,#0024H
;指向数据表首地址
;;
$0
JB
KEY32,$0
MOV
A,20H
INC
A
CJNE
A,#10D,$1
;不相当则转移
MOV
A,#00H
$1
MOV
20H,A
;保存数据
MOVC
A,@A+DPTR
MOV
P1,A
;DISPLAY
$2
CALL
DLY
;调用延时等待
KEY
起来
JNB
KEY32,$2
AJMP
$0
;;
DLY:
MOV
R7,#00
;DELAY
$A
MOV
R6,#00
;
$B
DJNZ
R6,$B
DJNZ
R7,$A
RET
;

3. 易语言制作一个自动后台下载安装的源码或者教程也可以

http://..com/link?url=kdNiQ-U4_WaXFE6KBy7p6glxrNyqw3s3HxO8u---ZFe6RlQn79qQYzK

4. java代码生成器怎么用

zip包,然后自动下载下来

1.预先定义好模板

最后放出源代码:

package com.et.controller.system.createcode;

import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import com.et.controller.base.BaseController;
import com.et.util.DelAllFile;
import com.et.util.FileDownload;
import com.et.util.FileZip;
import com.et.util.Freemarker;
import com.et.util.PageData;
import com.et.util.PathUtil;

/**
* 类名称:FreemarkerController
* 创建人:Harries
* 创建时间:2015年1月12日
* @version
*/
@Controller
@RequestMapping(value=”/createCode”)
public class CreateCodeController extends BaseController {

/**
* 生成代码
*/
@RequestMapping(value=”/proCode”)
public void proCode(HttpServletResponse response) throws Exception{
PageData pd = new PageData();
pd = this.getPageData();

/* ============================================================================================= */
String packageName = pd.getString(“packageName”); //包名 ========1
String objectName = pd.getString(“objectName”); //类名 ========2
String tabletop = pd.getString(“tabletop”); //表前缀 ========3
tabletop = null == tabletop?””:tabletop.toUpperCase(); //表前缀转大写
String zindext = pd.getString(“zindex”); //属性总数
int zindex = 0;
if(null != zindext && !””.equals(zindext)){
zindex = Integer.parseInt(zindext);
}
List<String[]> fieldList = new ArrayList<String[]>(); //属性集合 ========4
for(int i=0; i< zindex; i++){
fieldList.add(pd.getString(“field”+i).split(“,fh,”)); //属性放到集合里面
}

Map<String,Object> root = new HashMap<String,Object>(); //创建数据模型
root.put(“fieldList”, fieldList);
root.put(“packageName”, packageName); //包名
root.put(“objectName”, objectName); //类名
root.put(“objectNameLower”, objectName.toLowerCase()); //类名(全小写)
root.put(“objectNameUpper”, objectName.toUpperCase()); //类名(全大写)
root.put(“tabletop”, tabletop); //表前缀
root.put(“nowDate”, new Date()); //当前日期

DelAllFile.delFolder(PathUtil.getClasspath()+”admin/ftl”); //生成代码前,先清空之前生成的代码
/* ============================================================================================= */

String filePath = “admin/ftl/code/”; //存放路径
String ftlPath = “createCode”; //ftl路径

/*生成controller*/
Freemarker.printFile(“controllerTemplate.ftl”, root, “controller/”+packageName+”/”+objectName.toLowerCase()+”/”+objectName+”Controller.java”, filePath, ftlPath);

/*生成service*/
Freemarker.printFile(“serviceTemplate.ftl”, root, “service/”+packageName+”/”+objectName.toLowerCase()+”/”+objectName+”Service.java”, filePath, ftlPath);

/*生成mybatis xml*/
Freemarker.printFile(“mapperMysqlTemplate.ftl”, root, “mybatis_mysql/”+packageName+”/”+objectName+”Mapper.xml”, filePath, ftlPath);
Freemarker.printFile(“mapperOracleTemplate.ftl”, root, “mybatis_oracle/”+packageName+”/”+objectName+”Mapper.xml”, filePath, ftlPath);

/*生成SQL脚本*/
Freemarker.printFile(“mysql_SQL_Template.ftl”, root, “mysql数据库脚本/”+tabletop+objectName.toUpperCase()+”.sql”, filePath, ftlPath);
Freemarker.printFile(“oracle_SQL_Template.ftl”, root, “oracle数据库脚本/”+tabletop+objectName.toUpperCase()+”.sql”, filePath, ftlPath);

/*生成jsp页面*/
Freemarker.printFile(“jsp_list_Template.ftl”, root, “jsp/”+packageName+”/”+objectName.toLowerCase()+”/”+objectName.toLowerCase()+”_list.jsp”, filePath, ftlPath);
Freemarker.printFile(“jsp_edit_Template.ftl”, root, “jsp/”+packageName+”/”+objectName.toLowerCase()+”/”+objectName.toLowerCase()+”_edit.jsp”, filePath, ftlPath);

/*生成说明文档*/
Freemarker.printFile(“docTemplate.ftl”, root, “说明.doc”, filePath, ftlPath);

//this.print(“oracle_SQL_Template.ftl”, root); 控制台打印

/*生成的全部代码压缩成zip文件*/
FileZip.zip(PathUtil.getClasspath()+”admin/ftl/code”, PathUtil.getClasspath()+”admin/ftl/code.zip”);

/*下载代码*/
FileDownload.fileDownload(response, PathUtil.getClasspath()+”admin/ftl/code.zip”, “code.zip”);

}

}

热点内容
压缩油19 发布:2025-03-17 12:25:29 浏览:854
linux上网代理 发布:2025-03-17 12:23:56 浏览:358
c是高级语言吗 发布:2025-03-17 12:16:31 浏览:522
python泛型 发布:2025-03-17 12:15:01 浏览:481
编程猫被盗 发布:2025-03-17 12:02:18 浏览:130
海关锁密码箱如何设置新密码 发布:2025-03-17 11:53:50 浏览:559
农业卡号的密码在哪里改 发布:2025-03-17 11:48:57 浏览:966
杨澜超级访问 发布:2025-03-17 11:47:17 浏览:237
数据库无损连接 发布:2025-03-17 11:47:16 浏览:13
memcachephp类 发布:2025-03-17 11:40:04 浏览:829