ejs

Adding Background image to EJS file

大城市里の小女人 提交于 2020-12-16 08:05:49
问题 I seem to be fine getting an image to render from my app.js file to the main ejs file, but when i change it to a background image, it does not display. Any idea whats up? my app.js const express = require("express"), app = express(), bodyParser = require("body-parser"), jade = require("jade"), path = require('path'), redis = require('redis'); images = [{image:"http://nuvotera.com/wp-content/uploads/2013/10/email-protection-banner-2.jpg"}]; app.use(bodyParser.urlencoded({extended:true})); app

Adding Background image to EJS file

谁说我不能喝 提交于 2020-12-16 08:05:08
问题 I seem to be fine getting an image to render from my app.js file to the main ejs file, but when i change it to a background image, it does not display. Any idea whats up? my app.js const express = require("express"), app = express(), bodyParser = require("body-parser"), jade = require("jade"), path = require('path'), redis = require('redis'); images = [{image:"http://nuvotera.com/wp-content/uploads/2013/10/email-protection-banner-2.jpg"}]; app.use(bodyParser.urlencoded({extended:true})); app

Deno JWT token 应用

流过昼夜 提交于 2020-10-16 13:26:18
视频演示: https://www.bilibili.com/video/BV1BT4y1E7Nh/?p=12 一起来完成以下步骤: 引用之前的工程代码 创建员工信息interface和员工数组array 生成token 校验token是否正确 运行命令: deno run --allow-net --allow-read main.ts import { Context } from "https://deno.land/x/oak/mod.ts" ; import { key } from "../middlewares/key.ts" ; //引入jwt 模块功能 import { makeJwt, setExpiration, Jose, Payload } from "https://deno.land/x/djwt/create.ts" import employees from "../models/employees.ts" ; //获取工程目录方法 const { cwd } = Deno; //jwt头部 const header: Jose = { alg: "HS256" , typ: "JWT" , } /** * 定义Controller */ class Controller { /** * 首页 * @param ctx */ static