|
<! DOCTYPE html> |
|
lang= "en" > |
|
|
|
<meta charset= "UTF-8" > |
|
<title>arteditor</title> |
|
<meta http-equiv= "access-control-allow-origin" content= "*" > |
|
<!--forces the width of the document to remain at 1:1 of the width of the device, and the maximum width of the document is 1.0, and does not allow the user to tap the screen to zoom in. |
|
<meta name= "viewport" content= "initial-scale=1, Maximum-scale=1, User-scalable=no, width= Device-width, Minimal-ui "> |
|
<!--the safari private meta tag in the iphone device, which says: Allow full-screen mode to browse- |
|
<meta name= "apple-mobile-web-app-capable" content= "yes" > |
|
<link rel= "stylesheet" href= "Example/css/style.css" > |
|
|
|
<body> |
|
<div style= "width:320px;margin:0 auto;" > |
|
<div class= "publish-article-title" > |
|
<div class= "title-tips" > title </div> |
|
<input type= "text" id= "title" class= "w100" placeholder= " article title" > |
|
</div> |
|
<div class= "publish-article-content" > |
|
<div class= "title-tips" > Body </div> |
|
<input type= "hidden" id= "target" > |
|
<div class= "article-content" id= "content" > |
|
</div> |
|
<div class= "footer-btn g-image-upload-box" > |
|
<div class= "Upload-button" > |
&NBSP; |
<span class=" upload "><i class= "upload-img" > </i> Insert Picture </SPAN> |
|
<input class= "input-file" id= "imageupload" type= "file" name= "fileInput " Capture= "Camera" accept= "image/*" style= "position:absolute;left:0;opacity:0;width:100%;" > |
|
</div> |
|
</div> |
|
</div> |
|
</div> |
|
<script src= "Example/js/jquery-1.11.2.js" ></script> |
|
<script src= "ArtEditor.min.js" ></script> |
|
<script src= "Example/js/index.js" ></script> |
|
</body> |
|
|
|
JS Code Js: $ (' #content '). Arteditor ({imgtar: ' #imageUpload ', limitsize:5,//Mega Showserver:false,-- here to modify to True Uploadurl: ",-- Here's how to upload a picture data: {}, Uploadfie LD: ' Image ', Placeholader: ' <p> Please enter the article body Content </p> ', validhtml: [' BR '], uploadsuccess:function (res) { $ ("#demon"). Apppend (" ') here as the receive path }, Uploaderror:function (re s) {//Something error Console.log (res); }}); Function Demon01 () { get to the path to the SQL url= $ (' #demon '). GetValue ();//Detail Get Picture method $.post ('.. /.. /.. /path location '), { URL: url
}
}.function(data) {
}
估计很多人跟我差不多在传入CS层的时候会发现穿不进去,报错,等,或者是危险代码, 这时候介意在CS层的上方加入 [ValidateInput(false)] 字段。就可以完成路径的保存了
|