javascript - 使用 bootstrap-markdown 上传图像

标签 javascript twitter-bootstrap markdown image-uploading

我正在使用bootstrap-markdown ,当我尝试插入图像时,我只能从网络插入它,是否有任何解决方案无法从本地计算机上传?

    <form>
        <input name="title" type="text" placeholder="Title?" />
        <textarea id="myEditor" name="content" data-provide="markdown" rows="10"></textarea>
        <label class="checkbox">
          <input name="publish" type="checkbox"> Publish
        </label>
        <hr/>
        <button type="submit" class="btn">Submit</button>
    </form> 

最佳答案

使用此模块: https://github.com/inacho/bootstrap-markdown-editor

以下是激活上传的示例:

$('#myEditor').markdownEditor({
  imageUpload: true, // Activate the option
  uploadPath: 'upload.php' // Path of the server side script that receive the files
});

这是一个documentation

关于javascript - 使用 bootstrap-markdown 上传图像,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29284569/

相关文章:

javascript - jquery模态超时后自动显示

html - 无法在全宽上定义我的网站 - bootstrap

javascript - 具有指向代码查找 block 的内部链接

github - 如何在 Bitbucket 和 github markdown 中显示数学表达式?

javascript - 带有 protractorjs 的 Angular 2 失败 : Error while waiting for Protractor to sync with the page: "window.getAllAngularTestabilities is not a function"

javascript - 如何在 Javascript 中最佳地交错相同固定 N 长度的 K 个数组

javascript - 类型错误 : "this..." is not a function

javascript选择更改字段价格与折扣onchange

javascript - 移动 Bootstrap 导航栏测量等于它的高度

github - 如何在 Github 中创建带有标签的代码片段?