我正在尝试使用 FilePond 在我的网站上实现拖放功能。我已经下载了 filepond css 和 js 文件并正确附加它们。每当我尝试完成设置时,我都会收到“未捕获的引用错误:FilePond 未定义”的消息。
{% extends 'main/dashboardbase.html'%}
{% block content %}
{% load static %}
<!doctype html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-tofit=no">
<!-- Bootstrap CSS -->
<title>Hello, world!</title>
<link rel="stylesheet "type="text/css" href="{% static 'main/add.css'%}">
<link rel="stylesheet "type="text/css" href="{% static 'main/filepond.css'%}">
<link rel="stylesheet" type="text/css" href="{% static 'main/filepond-plugin-image-preview.css'%}">
</head>
<body>
<button type="submit" id="add">Save</button>
<a href="{% url 'main:products'%}">
<button id="cancel" >Cancel</button>
</a>
<div class="col-sm-12 col-lg-6" id="inner">
<form method="POST" …Run Code Online (Sandbox Code Playgroud) 我正在使用 VS 代码进行反应。我安装了实时服务器扩展,每当我尝试使用 VS 代码上线时,它都会在浏览器中显示一个包含我所有文件夹和文件的列表目录,而不是运行我的应用程序。关于为什么这样做的任何线索?
我希望当用户在一段时间内处于非活动状态时删除会话。
我尝试了set_expiry(300)和SESSION_COOKIE_AGE = 5 * 60,但即使用户处于活动状态,会话也不会延长。