webdoc.c

来自「单片机控制RTL8019AS的程序,C语言编写,仿真通过.」· C语言 代码 · 共 58 行

C
58
字号
//-----------------------------------------------------------------------------
// Net WEBDOC.C
//
// This module contains web pages and headers
//-----------------------------------------------------------------------------
#include <net.h>


// This is the header for web text pages.  LENGTH is the body
// length, needed because in HTTP 1.1 we leave connection open
// Includes control statements to prevent browser from caching page
char code html_header[] = {
"HTTP/1.1 200 OK\n"
"Cache-control: no-cache\n"
"Connection: Keep-Alive\n"
"Content-Length: TAG:LEN1\n"
"Content-Type: text/html\r\n\r\n" };



// This page displays a table with weather data and a switch
// to turn a port pin on and off. 
char code web_page[] = {"<HTML><HEAD><TITLE>&#22522;&#20110;&#21333;&#29255;&#26426;&#30340;Web&#26381;&#21153;&#22120;</TITLE>\n"
"<META http-equiv=Content-Type content=\"text/html; charset=gb2312\">\n"
"</HEAD>\n"
"<BODY>\n"
"<br>\n"
"<br>\n"
"<br>\n"
"<br>\n"
"<br>\n"
"<blockquote>\n"
"<blockquote>\n"
"<blockquote>\n"
"<blockquote>\n"
"<blockquote>\n"
"<blockquote>\n"
"<blockquote>\n"
"<blockquote>\n"
"<blockquote>\n"
"<FORM action=/index.html method=post>\n"
"<font size=\"4\">&#22522;&#20110;&#21333;&#29255;&#26426;&#30340;Web&#26381;&#21153;&#22120;&#28436;&#31034;&#31243;&#24207;</font>\n"
"<BR><BR><BR><BR>LED&#25351;&#31034;&#28783;:&nbsp;&nbsp;\n" 
"<INPUT type=radio TAG:CHK1 value=1 name=switch>&#28781; \n"
"<INPUT type=radio\n"
"value=0 name=switch TAG:CHK2>&#20142;&nbsp;&nbsp;&nbsp;&nbsp; \n"
"<INPUT type=submit value=&#21457;&#36865;>\n"
"</FORM>\n"
"</blockquote>\n"
"</blockquote>\n"
"</blockquote>\n"
"</blockquote>\n"
"</blockquote>\n"
"</blockquote>\n"
"</blockquote>\n"
"</blockquote>\n"
"</blockquote>\n"
"</BODY></HTML>\n"};

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?