6,470 questions
0
votes
0
answers
15
views
CSS Flexbox Issue
I have a container with multiple items displayed using CSS Flexbox, with flex-wrap: wrap and justify-content: center so that the items are visually centered and wrap responsively. Each item has a ...
1
vote
1
answer
45
views
EJS including static html pages from "public"
I'm trying to include an html file in my ejs templates. Not working.
Everything else works.
Tried a million different paths in my Include
Wrong approach? Wrong syntax? Use the "path" ...
0
votes
2
answers
128
views
CSS page counters not visible in generated PDF using @page rule
I'm developing a feature to generate a PDF health report from an EJS template. I'm trying to add page numbers (e.g., "Page 1 of 10") to the footer of each page. I'm using the CSS Paged Media ...
0
votes
0
answers
34
views
issues with google oauth2 access token
So i am new to programming so pardon me. I am building a blog app with ejs and node js that has a google sign in functionality through passport js.. the functionality works, however when i click on ...
0
votes
0
answers
57
views
My browser is not showing some of the content i write inside my ejs file
i am working on a full stack web developement project and i'm stuck where localhost:3000 in my browser can't show the before and after mentioned in the layout.ejs file, which are outside the <%- ...
0
votes
0
answers
87
views
When submitting data through an EJS form, all data get returned as "undefined"
I'm currently trying to make a login and signup form using EJS, Express, Node, etc. However Whenever I submit data from a form, all data is being returned as "Invalid"
I've checked my user ...
0
votes
1
answer
45
views
Ejs won't allow me to project import statements in my template
I'm trying to make my component generator more flexible by adding in an option to make it a custom form control. I have the options set up in the schema along with an x-prompt object to provide the ...
0
votes
3
answers
77
views
getting NaN value some times and some times not
I get NaN value when I try to show the value of (item.total_amount,item.price,item.addtional_price) in ejs page but when I debug the variables some time I get the value and some time not!!
this is the ...
1
vote
2
answers
93
views
How do I render .ejs files without having to create a route for each one?
Server:
import express from 'express';
const app = express();
app.set('views', './public');
const PORT = 3002;
app.get('/', (req, res) => {
res.render('index.ejs', { title: 'Page Title'});
});
...
1
vote
1
answer
43
views
The home route is triggered several times when running nodeJs by using expressJs to get JSON data from an API, and render to the ejs file
I created a simple web application that fetches data from an API but when I get a response and render the result to ejs file it seems the route is called multiple times
Here are my codes:-
index.js ...
0
votes
1
answer
161
views
dateTime working properly in localhost but not working properly after deployment even after ist date management using date-fns-tz
I'm using node JS for the backend and ejs template for my frontend. Basically, I'm making a salon appointment system where users will select a date and based on the selected date, in next form they ...
0
votes
1
answer
51
views
EJS Syntax issue Could not find matching close tag for "<%-" in node js
I am creating dashboard where I have created a layout for sidebar and different pages of sidebar have different content.
here is the layout.ejs:
<!DOCTYPE html>
<html lang="en">
&...
1
vote
2
answers
69
views
Set the view directory and layout in ejs based on the path of the request
I have a little dilemma, where I am trying to make a website with a function for changing the views directory and the layout of a node.js server:
app.use((req, res, next) => {
const segments = ...
1
vote
1
answer
85
views
Why can't I filter posts in my postgreSQL database by author? (Issue Resolved)
So I have a service where I let users post book reviews. I myself have posted two. In my database I keep track of the user names that they input when submiting a post.
for some weird reason, it will ...
0
votes
0
answers
207
views
NestJS: Instance of INestApplication does not have setBaseViewsDir?
I would just like to set up a template engine locally, as my workflow now is rendering the tempalte and having to go to my aws-s3 bucket to see the results.
In the NestJS docs the hace an example ...
0
votes
1
answer
96
views
Issues Rendering Plotly OHLC Plot with EJS and Passing Data
I am trying to render a Plotly OHLC plot in my chart.ejs file and pass a variable called result to it. However, when I attempt to use EJS templating to include result in the chart.ejs file, the plot ...
1
vote
1
answer
71
views
Not defined error in Node.js + Express.js + Ejs project
I'm building website based on node.js(express.js), MYSQL and Ejs.
And I was trying to present graph with d3.js
This is part of script in mainpage.ejs
<script src="https://d3js.org/d3.v6....
0
votes
0
answers
39
views
Sidebar under stuff on small screens
Am making a archive.org like website but the sidebar is a sidebar on desktop but going to localhost on my phone is under everything else am using node.js and EJS the header is just a title and ...
2
votes
0
answers
81
views
EjsAdapter marked as Open handler in Jest test running
I am trying to run my tests on cloud using ci gh actions but due to that open handler issue the pipeline keeps loading forever and does not stop. how can I resolve that issue of EjsAdapter open ...
0
votes
1
answer
109
views
node.js ejs template with datatables not passing variables to if statements
Good evening all, I know this is using an older stack; however, it is my starting spot to get something working before moving to a different stack with more features.
I have a Node.JS application ...
1
vote
2
answers
71
views
How to connect HTML button to Express server delete route?
I have an Express server with a route for deleting a (psychology) experiment. (I have split my routes into multiple files. This route is in admin.js and thus its full route path is /admin/experiments/:...
0
votes
2
answers
77
views
Rendering user.ejs file into dashbord.ejs file but user.ejs file's javascript is not working after rendering it in dashbord.ejs
I am making a web based chat app like whatsapp web. When clicking on an user then I want to render user.ejs file inside dashbord.ejs.
I am able to load the html and css from user.ejs but js is not ...
-1
votes
1
answer
47
views
How to link my JS file from a different directory to my EJS file
I have an ejs file in the following directory:
./admin/admin.ejs
and i have plain old JS file in the following directory:
./public/client.js
and an express app in the following directory:
./app.js
...
-1
votes
1
answer
85
views
how to render a specific piece of data from Mysql database to my front end html using Js and node
so i am building a note system and how i have it setup is that on the home page it gives you a preview of the note and if you want to see the whole note you click on it and it pulls up a modal pop-up ...
0
votes
1
answer
36
views
facing issue while uploading project it on render
enter image description here
this is my rander log screen
//navbar.ejs
<% if(!currentUser) {%>
<a class="nav-link" href="/signup"><b>Sign Up</b&...