12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316 |
- <!DOCTYPE HTML>
- <html lang="zh-hans" >
- <head>
- <meta charset="UTF-8">
- <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
- <title>留言投稿 · 梦想家内容管理系统(Dreamer CMS)</title>
- <meta http-equiv="X-UA-Compatible" content="IE=edge" />
- <meta name="description" content="">
- <meta name="generator" content="GitBook 3.2.3">
- <meta name="author" content="王俊南">
-
-
-
- <link rel="stylesheet" href="../gitbook/style.css">
-
-
-
- <link rel="stylesheet" href="../gitbook/gitbook-plugin-anchors/plugin.css">
-
-
-
- <link rel="stylesheet" href="../gitbook/gitbook-plugin-highlight/website.css">
-
-
-
- <link rel="stylesheet" href="../gitbook/gitbook-plugin-search/search.css">
-
-
-
- <link rel="stylesheet" href="../gitbook/gitbook-plugin-fontsettings/website.css">
-
-
-
-
-
-
-
-
-
-
-
- <meta name="HandheldFriendly" content="true"/>
- <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
- <meta name="apple-mobile-web-app-capable" content="yes">
- <meta name="apple-mobile-web-app-status-bar-style" content="black">
- <link rel="apple-touch-icon-precomposed" sizes="152x152" href="../gitbook/images/apple-touch-icon-precomposed-152.png">
- <link rel="shortcut icon" href="../gitbook/images/favicon.ico" type="image/x-icon">
-
- <link rel="next" href="Search.html" />
-
-
-
- <link rel="shortcut icon" href="./source/images/favicon.ico" type="image/x-icon">
-
-
-
-
- <link rel="apple-touch-icon-precomposed" sizes="152x152" href="./source/images/favicon.png">
-
-
-
-
-
-
-
- </head>
- <body>
-
- <div class="book">
- <div class="book-summary">
-
-
- <div id="book-search-input" role="search">
- <input type="text" placeholder="输入并搜索" />
- </div>
-
- <nav role="navigation">
-
- <ul class="summary">
-
-
-
-
- <li>
- <a href="http://www.iteachyou.cc" target="_blank" class="custom-link">I Teach You,我教你!</a>
- </li>
-
-
- <li>
- <a href="https://gitee.com/iteachyou/dreamer_cms" target="_blank" class="custom-link">Dreamer CMS(Gitee)</a>
- </li>
-
-
- <li>
- <a href="https://github.com/iteachyou-wjn/dreamer_cms" target="_blank" class="custom-link">Dreamer CMS(Github)</a>
- </li>
-
-
-
- <li class="divider"></li>
-
-
-
-
-
- <li class="chapter " data-level="1.1" data-path="../">
-
- <a href="../">
-
-
- 封面
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="1.2" data-path="../COPYRIGHT.html">
-
- <a href="../COPYRIGHT.html">
-
-
- 版权
-
- </a>
-
-
- </li>
-
-
-
- <li class="divider"></li>
-
-
-
- <li class="chapter " data-level="2.1" >
-
- <span>
-
-
- 前言
-
- </span>
-
-
- <ul class="articles">
-
-
- <li class="chapter " data-level="2.1.1" data-path="../preface/">
-
- <a href="../preface/">
-
-
- 简介
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="2.1.2" data-path="../preface/Topic.html">
-
- <a href="../preface/Topic.html">
-
-
- 主题
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="2.1.3" data-path="../preface/Publish.html">
-
- <a href="../preface/Publish.html">
-
-
- 发行方法
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="2.1.4" data-path="../preface/Online.html">
-
- <a href="../preface/Online.html">
-
-
- 在线手册
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="2.1.5" data-path="../preface/Last.html">
-
- <a href="../preface/Last.html">
-
-
- 最后
-
- </a>
-
-
- </li>
-
- </ul>
-
- </li>
-
-
-
- <li class="divider"></li>
-
-
-
- <li class="chapter " data-level="3.1" data-path="../chapter01/">
-
- <a href="../chapter01/">
-
-
- 第一章 模板设计师要求
-
- </a>
-
-
- <ul class="articles">
-
-
- <li class="chapter " data-level="3.1.1" data-path="../chapter01/Designer.html">
-
- <a href="../chapter01/Designer.html">
-
-
- 设计师
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="3.1.2" data-path="../chapter01/Developer.html">
-
- <a href="../chapter01/Developer.html">
-
-
- 开发者
-
- </a>
-
-
- </li>
-
- </ul>
-
- </li>
-
-
-
- <li class="divider"></li>
-
-
-
- <li class="chapter " data-level="4.1" data-path="../chapter02/">
-
- <a href="../chapter02/">
-
-
- 第二章 模板制作流程
-
- </a>
-
-
- </li>
-
-
-
- <li class="divider"></li>
-
-
-
- <li class="chapter " data-level="5.1" >
-
- <span>
-
-
- 第三章 模板文件及目录结构
-
- </span>
-
-
- <ul class="articles">
-
-
- <li class="chapter " data-level="5.1.1" data-path="../chapter03/">
-
- <a href="../chapter03/">
-
-
- 模版目录
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="5.1.2" data-path="../chapter03/Description.html">
-
- <a href="../chapter03/Description.html">
-
-
- 模板文件与功能说明
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="5.1.3" data-path="../chapter03/DesignAndUse.html">
-
- <a href="../chapter03/DesignAndUse.html">
-
-
- 概念,设计和使用模板
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="5.1.4" data-path="../chapter03/NamingRules.html">
-
- <a href="../chapter03/NamingRules.html">
-
-
- 命名规则
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="5.1.5" data-path="../chapter03/Other.html">
-
- <a href="../chapter03/Other.html">
-
-
- 其它模板说明
-
- </a>
-
-
- </li>
-
- </ul>
-
- </li>
-
-
-
- <li class="divider"></li>
-
-
-
- <li class="chapter " data-level="6.1" data-path="../chapter04/">
-
- <a href="../chapter04/">
-
-
- 第四章 模板引擎介绍
-
- </a>
-
-
- <ul class="articles">
-
-
- <li class="chapter " data-level="6.1.1" data-path="../chapter04/CoreDoc.html">
-
- <a href="../chapter04/CoreDoc.html">
-
-
- 核心文件
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="6.1.2" data-path="../chapter04/Grammar.html">
-
- <a href="../chapter04/Grammar.html">
-
-
- 模板语法
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="6.1.3" data-path="../chapter04/LabelCategory.html">
-
- <a href="../chapter04/LabelCategory.html">
-
-
- 标签分类
-
- </a>
-
-
- </li>
-
- </ul>
-
- </li>
-
-
-
- <li class="divider"></li>
-
-
-
- <li class="chapter " data-level="7.1" >
-
- <span>
-
-
- 第五章 标签参考
-
- </span>
-
-
- <ul class="articles">
-
-
- <li class="chapter " data-level="7.1.1" >
-
- <span>
-
-
- ▶全局标签
-
- </span>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.2" data-path="../chapter05/GlobalLabel.html">
-
- <a href="../chapter05/GlobalLabel.html">
-
-
- Global全局配置标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.3" data-path="../chapter05/VariableLabel.html">
-
- <a href="../chapter05/VariableLabel.html">
-
-
- Variable全局变量标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.4" data-path="../chapter05/TemplateLabel.html">
-
- <a href="../chapter05/TemplateLabel.html">
-
-
- Template模版路径标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.5" data-path="../chapter05/IncludeLabel.html">
-
- <a href="../chapter05/IncludeLabel.html">
-
-
- Include引入文件标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.6" data-path="../chapter05/TypeLabel.html">
-
- <a href="../chapter05/TypeLabel.html">
-
-
- Type栏目调用标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.7" data-path="../chapter05/ChannelLabel.html">
-
- <a href="../chapter05/ChannelLabel.html">
-
-
- Channel频道列表标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.8" data-path="../chapter05/ListLabel.html">
-
- <a href="../chapter05/ListLabel.html">
-
-
- List文章列表标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.9" data-path="../chapter05/CategoryArtListLabel.html">
-
- <a href="../chapter05/CategoryArtListLabel.html">
-
-
- CategoryArtListLabel栏目内容列表标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.10" data-path="../chapter05/TagLabel.html">
-
- <a href="../chapter05/TagLabel.html">
-
-
- TagLabel标签列表标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.11" data-path="../chapter05/TreeLabel.html">
-
- <a href="../chapter05/TreeLabel.html">
-
-
- TreeLabel栏目树标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.12" data-path="../chapter05/AttachmentLabel.html">
-
- <a href="../chapter05/AttachmentLabel.html">
-
-
- AttachmentLabel附件标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.13" data-path="../chapter05/SqlLabel.html">
-
- <a href="../chapter05/SqlLabel.html">
-
-
- SqlLabel SQL标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.14" data-path="../chapter05/IfLabel.html">
-
- <a href="../chapter05/IfLabel.html">
-
-
- IfLabel判断标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.15" >
-
- <span>
-
-
- ▶分页标签
-
- </span>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.16" data-path="../chapter05/CategoryLabel.html">
-
- <a href="../chapter05/CategoryLabel.html">
-
-
- Category分页栏目标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.17" data-path="../chapter05/TopCategoryLabel.html">
-
- <a href="../chapter05/TopCategoryLabel.html">
-
-
- TopCategory分页顶级栏目标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.18" data-path="../chapter05/LocationLabel.html">
-
- <a href="../chapter05/LocationLabel.html">
-
-
- Location当前位置标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.19" >
-
- <span>
-
-
- ▶列表标签
-
- </span>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.20" data-path="../chapter05/PageListLabel.html">
-
- <a href="../chapter05/PageListLabel.html">
-
-
- PageList文章分页标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.21" data-path="../chapter05/PaginationLabel.html">
-
- <a href="../chapter05/PaginationLabel.html">
-
-
- Pagination显示分页标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.22" >
-
- <span>
-
-
- ▶内容标签
-
- </span>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.23" data-path="../chapter05/ArticleLabel.html">
-
- <a href="../chapter05/ArticleLabel.html">
-
-
- Article文章页标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.1.24" data-path="../chapter05/PrevNextLabel.html">
-
- <a href="../chapter05/PrevNextLabel.html">
-
-
- PrevNext上一篇、下一篇标签
-
- </a>
-
-
- </li>
-
- </ul>
-
- </li>
-
- <li class="chapter " data-level="7.2" data-path="../chapter06/DataBase.html">
-
- <a href="../chapter06/DataBase.html">
-
-
- 第六章 数据库
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.3" >
-
- <span>
-
-
- 第七章 模板扩展
-
- </span>
-
-
- <ul class="articles">
-
-
- <li class="chapter active" data-level="7.3.1" data-path="Message.html">
-
- <a href="Message.html">
-
-
- 留言投稿
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.3.2" data-path="Search.html">
-
- <a href="Search.html">
-
-
- 网站搜索
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.3.3" data-path="DefineLabel.html">
-
- <a href="DefineLabel.html">
-
-
- 定义标签
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.3.4" data-path="Regexp.html">
-
- <a href="Regexp.html">
-
-
- 正则工具类
-
- </a>
-
-
- </li>
-
- </ul>
-
- </li>
-
- <li class="chapter " data-level="7.4" >
-
- <span>
-
-
- 第八章 部署上线
-
- </span>
-
-
- <ul class="articles">
-
-
- <li class="chapter " data-level="7.4.1" data-path="../chapter08/Environment.html">
-
- <a href="../chapter08/Environment.html">
-
-
- 环境准备
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.4.2" data-path="../chapter08/Packaging.html">
-
- <a href="../chapter08/Packaging.html">
-
-
- 应用打包
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.4.3" data-path="../chapter08/Online.html">
-
- <a href="../chapter08/Online.html">
-
-
- 项目上线
-
- </a>
-
-
- </li>
-
- </ul>
-
- </li>
-
- <li class="chapter " data-level="7.5" >
-
- <span>
-
-
- 第九章 常见问题
-
- </span>
-
-
- <ul class="articles">
-
-
- <li class="chapter " data-level="7.5.1" data-path="../chapter09/Business.html">
-
- <a href="../chapter09/Business.html">
-
-
- 商业授权
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.5.2" data-path="../chapter09/ResourceDir.html">
-
- <a href="../chapter09/ResourceDir.html">
-
-
- 资源目录
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.5.3" data-path="../chapter09/RichTextEditor.html">
-
- <a href="../chapter09/RichTextEditor.html">
-
-
- 富文本编辑器
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.5.4" data-path="../chapter09/NavActive.html">
-
- <a href="../chapter09/NavActive.html">
-
-
- 导航Active
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.5.5" data-path="../chapter09/CategoryPage.html">
-
- <a href="../chapter09/CategoryPage.html">
-
-
- 栏目分页
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.5.6" data-path="../chapter09/CategoryFilter.html">
-
- <a href="../chapter09/CategoryFilter.html">
-
-
- 多级栏目筛选
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.5.7" data-path="../chapter09/MutipleLanguage.html">
-
- <a href="../chapter09/MutipleLanguage.html">
-
-
- 多语言网站
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.5.8" data-path="../chapter09/UploadContrl.html">
-
- <a href="../chapter09/UploadContrl.html">
-
-
- 上传大小控制
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.5.9" data-path="../chapter09/ResourceNotFound.html">
-
- <a href="../chapter09/ResourceNotFound.html">
-
-
- 上线图片404
-
- </a>
-
-
- </li>
-
- <li class="chapter " data-level="7.5.10" data-path="../chapter09/Favicon.html">
-
- <a href="../chapter09/Favicon.html">
-
-
- 站点Favicon
-
- </a>
-
-
- </li>
-
- </ul>
-
- </li>
-
- <li class="chapter " data-level="7.6" >
-
- <span>
-
-
- 第十章 关于捐赠
-
- </span>
-
-
- <ul class="articles">
-
-
- <li class="chapter " data-level="7.6.1" data-path="../chapter10/DonationList.html">
-
- <a href="../chapter10/DonationList.html">
-
-
- 授权和捐赠
-
- </a>
-
-
- </li>
-
- </ul>
-
- </li>
-
-
- <li class="divider"></li>
- <li>
- <a href="https://www.gitbook.com" target="blank" class="gitbook-link">
- 本书使用 GitBook 发布
- </a>
- </li>
- </ul>
- </nav>
-
-
- </div>
- <div class="book-body">
-
- <div class="body-inner">
-
-
- <div class="book-header" role="navigation">
-
- <!-- Title -->
- <h1>
- <i class="fa fa-circle-o-notch fa-spin"></i>
- <a href=".." >留言投稿</a>
- </h1>
- </div>
- <div class="page-wrapper" tabindex="-1" role="main">
- <div class="page-inner">
-
- <div id="book-search-results">
- <div class="search-noresults">
-
- <section class="normal markdown-section">
-
- <div style="display: flex;">
- <img src="https://oss.iteachyou.cc/logo.png" height="30">
- <div style="margin-left: 5px; font-size: 30px; line-height: 30px; font-weight: bold;">梦想家内容管理系统</div>
- </div>
- <hr>
- <h3 id="留言投稿"><a name="留言投稿" class="plugin-anchor" href="#留言投稿"><i class="fa fa-link" aria-hidden="true"></i></a>留言投稿</h3>
- <p>在网站开发时,难免会有留言投稿的需求,Dreamer CMS考虑到这点,为大家提供了留言投稿的功能。以下内容详细介绍在自定义模板中,如何使用留言投稿的功能。</p>
- <p>模板文件:</p>
- <pre><code>新版:default_v2/list_case.html
- 旧版:default/list_message.html
- </code></pre><h4 id="前端表单"><a name="前端表单" class="plugin-anchor" href="#前端表单"><i class="fa fa-link" aria-hidden="true"></i></a>前端表单</h4>
- <p>在使用留言投稿功能时,为了防止恶意留言,我们必须要使用图形验证码功能进行校验。</p>
- <ol>
- <li><p>网站后台</p>
- <pre><code class="lang-javascript?linenums">在网站后台栏目管理中,要针对留言的栏目,必须要开启允许投稿。
- </code></pre>
- <p><img src="https://oss.iteachyou.cc/20230227082602.png" alt="list标签" title="留言投稿"></p>
- </li>
- <li><p>验证码地址</p>
- <pre><code class="lang-javascript?linenums">var captchaURL = "/getKaptcha?t=" + new Date().getTime();
- // 建议每次切换都加上时间戳作为参数,避免缓存
- </code></pre>
- </li>
- <li>表单定义<pre><code class="lang-html?linenums"><form action="/input" method="post">
- <input type="hidden" name="typeid" value="wqz18j7q" />
- <input type="hidden" name="formkey" value="8t2lkr8d" />
- <div class="item">
- <input type="text" id="title" placeholder="填写您的姓名" name="title">
- </div>
- <div class="item">
- <input type="text" id="telephone" placeholder="填写您的联系电话" name="telephone">
- </div>
- <div class="item">
- <textarea id="content" name="content" class="form-control" placeholder="填写您的需求"></textarea>
- </div>
- <div class="captcha">
- <div class="login-form-vcode"><img alt="图片验证码" width="120" height="46" src="" id="vcode"></div>
- <div class="login-form-vcode-input"><input type="text" name="captcha" placeholder="验证码" required="required" class="form-control" /></div>
- <div class="clearFix"></div>
- </div>
- <div class="form-btn-group-left">
- <div class="submission set_5_button" id="essentialInformation">提交</div>
- </div>
- </form>
- </code></pre>
- </li>
- </ol>
- <p>注意:</p>
- <ol>
- <li>提交地址必须为/input,方式必须为POST。</li>
- <li>captcha: 验证码字段名,不可改变。</li>
- <li>typeid:使用隐藏域来定义该留言提交后,要提交到后台的哪一个栏目中,不可改变。</li>
- <li>formkey:该栏目所使用的表单模型,指定后可使用表单模型中定义的字段名,不可改变。</li>
- <li>title:公共字段,文章标题,不可改变。</li>
- <li>telephone|content:表单模型中定义的字段。</li>
- </ol>
- <h4 id="后端接收"><a name="后端接收" class="plugin-anchor" href="#后端接收"><i class="fa fa-link" aria-hidden="true"></i></a>后端接收</h4>
- <pre><code class="lang-java?linenums">cc.iteachyou.cms.controller.FrontController
- </code></pre>
- <p>在该类中的input方法,为后端接收前台留言的控制器。返回JSON数据,格式如下:</p>
- <pre><code class="lang-javascript?linenums">{
- "success": true,
- "state": "200",
- "data": null,
- "info": "操作成功"
- }
- // 前台只需要判断response.state === "200"即可,其它结果均为失败。
- </code></pre>
- <h4 id="范例"><a name="范例" class="plugin-anchor" href="#范例"><i class="fa fa-link" aria-hidden="true"></i></a>范例</h4>
- <p><img src="https://oss.iteachyou.cc/20230227083501.png" alt="list标签" title="留言投稿"></p>
-
- </section>
-
- </div>
- <div class="search-results">
- <div class="has-results">
-
- <h1 class="search-results-title"><span class='search-results-count'></span> results matching "<span class='search-query'></span>"</h1>
- <ul class="search-results-list"></ul>
-
- </div>
- <div class="no-results">
-
- <h1 class="search-results-title">No results matching "<span class='search-query'></span>"</h1>
-
- </div>
- </div>
- </div>
- </div>
- </div>
-
- </div>
-
-
-
- <a href="Search.html" class="navigation navigation-next navigation-unique" aria-label="Next page: 网站搜索">
- <i class="fa fa-angle-right"></i>
- </a>
-
-
-
- </div>
- <script>
- var gitbook = gitbook || [];
- gitbook.push(function() {
- gitbook.page.hasChanged({"page":{"title":"留言投稿","level":"7.3.1","depth":2,"next":{"title":"网站搜索","level":"7.3.2","depth":2,"path":"chapter07/Search.md","ref":"chapter07/Search.md","articles":[]},"previous":{"title":"第七章 模板扩展","level":"7.3","depth":1,"ref":"","articles":[{"title":"留言投稿","level":"7.3.1","depth":2,"path":"chapter07/Message.md","ref":"chapter07/Message.md","articles":[]},{"title":"网站搜索","level":"7.3.2","depth":2,"path":"chapter07/Search.md","ref":"chapter07/Search.md","articles":[]},{"title":"定义标签","level":"7.3.3","depth":2,"path":"chapter07/DefineLabel.md","ref":"chapter07/DefineLabel.md","articles":[]},{"title":"正则工具类","level":"7.3.4","depth":2,"path":"chapter07/Regexp.md","ref":"chapter07/Regexp.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["anchors","favicon-absolute","highlight"],"styles":{"website":"./styles/website.css"},"pluginsConfig":{"favicon-absolute":{"appleTouchIconMore":{},"appleTouchIconPrecomposed152":"./source/images/favicon.png","appleTouchIconPrecomposedMore":{},"favicon":"./source/images/favicon.ico"},"anchors":{},"highlight":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","author":"王俊南","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"梦想家内容管理系统(Dreamer CMS)","language":"zh-hans","links":{"sidebar":{"I Teach You,我教你!":"http://www.iteachyou.cc","Dreamer CMS(Gitee)":"https://gitee.com/iteachyou/dreamer_cms","Dreamer CMS(Github)":"https://github.com/iteachyou-wjn/dreamer_cms"}},"gitbook":"3.2.3","description":"Dreamer CMS,梦想家内容管理系统官方使用文档"},"file":{"path":"chapter07/Message.md","mtime":"2023-09-28T07:00:56.535Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2024-05-14T01:34:04.807Z"},"basePath":"..","book":{"language":""}});
- });
- </script>
- </div>
-
- <script src="../gitbook/gitbook.js"></script>
- <script src="../gitbook/theme.js"></script>
-
-
- <script src="../gitbook/gitbook-plugin-search/search-engine.js"></script>
-
-
-
- <script src="../gitbook/gitbook-plugin-search/search.js"></script>
-
-
-
- <script src="../gitbook/gitbook-plugin-lunr/lunr.min.js"></script>
-
-
-
- <script src="../gitbook/gitbook-plugin-lunr/search-lunr.js"></script>
-
-
-
- <script src="../gitbook/gitbook-plugin-sharing/buttons.js"></script>
-
-
-
- <script src="../gitbook/gitbook-plugin-fontsettings/fontsettings.js"></script>
-
-
- </body>
- </html>
|