Kevin Powell - Community

KPC

Kevin Powell - Community

A friendly place for developers to meet other devs, ask questions, get help, and just have a good time ๐Ÿ™‚.

Join
ZZomaTheMasterOfDisaster5/13/2024

How do you properly close a php session before closing the browser?

say the user closes your site (tab or browser) and you want the session to be destroyed because you dont want an active session when the user turns their browser back on and goes to your page. How do you detect them leaving your site to close the active session?
Ttaj00235/9/2024

Where to declare a types file

Is there a convention to place a types.d.ts file? My project structure looks like this: - client folder and server folder are kept inside the root folder (.git). - These folders have their own package.json and tsconfig.json files....
IItsAmjed5/6/2024

How to link PHP with ReactJs

does anyone know how to link reactJs with PHP or have course about this i wanna know about it
Ppain25_5/6/2024

can anyone help me to deploy this on vercel plz?

and my vercel.json code is { "version": 2, "builds": [{ "src": "./app.js", "use": "@vercel/node" }], "rewrites": [{ "source": "/(.*)", "destination": "/" }] }...
GGhost_5/4/2024

Error - self-signed certificate in certificate chain in postgres

getting this error while using pg library in postgress in nodejs app how to fix it pls help !!!
No description
ZZomaTheMasterOfDisaster5/3/2024

The best way to implement a "Remember Me" function for login in php

I'm currently working on a remember me functionality for my login page and i know the common way is to use setcookie() then $_COOKIE['<some field here>] and assign a value and check that to login, but is there a better way or a safer way?
SShane5/1/2024

Confused by Kysely

I'm using kysely for a project and I'm using it to create tables, however now that I create the tables with the columns and behaviors I want, I need to essentially do the same by writing the typescript type, which seems bad. Am I missing something or is that really how I'm expected to do this? for example here is a users table ...
โ˜ขโ™ฌ ล•ฮ”ฤป๐”ญแ•ผ__ั˜๐š๐“ƒ ๐Ÿ‘ฝโ˜น4/30/2024

Css issue

How can I fix those white space between the words ?
No description
DDilliwala4/29/2024

Login Error

Hello friends, I have created a MERN stack website with a login feature, and the login feature is fully implemented using Auth0. The login is working fine, but when I refresh the page, it automatically logs me out. Can anyone tell me why this is happening and how I can solve this problem? I have been working on this for the past 3-4 days, but I haven't been able to solve the problem yet. Please, if anyone can help me, it would be greatly appreciated...
Mmdrizwan07124/28/2024

Failed to load resource: the server responded with a status of 404 ()

how to solve this error this is a youtube clone project help me to solve this Failed to load resource: the server responded with a status of 404 ()...
No description
Ggreenleaf024/26/2024

trouble using express.js

i have a js file that im using express.js code using the nodemailer module. What im trying to do is have a user enter their details in a form and when they press a button i receive details that they entered as an email, but i dont seem to understand what the problem is. in my browser im getting this error
Uncaught ReferenceError: require is not defined
at app.js:1:20
Uncaught ReferenceError: require is not defined
at app.js:1:20
i did some searching and it said the browser cannot understand node.js files or something like that, Does anyone know what the actua problem is...
DDimitriUI4/25/2024

React + PHP - How to deploy the API files

Hello i created a litle webpage with React and made an PHP API. Everything works on my PC, but i don't understand where i should upload my PHP files. First of all, when i make a call with axios i should put the url of the API, i can't write simple localhost. Example: "http://www.test.com/api/engines.php" Correct? I made different Routes in react with react-router-dom and i don't understand how i should be able to access these PHP files and where to put them. They shouldn't be also private from extern? I want to upload the webpage to test it on cPanel and i got stuck with this litle detail and i can't find any youtube video and chatgpt isn't helping me....
No description
Aavi124/23/2024

How to model the data?

I'm working on a Chrome extension that lets users get deeper insights into their YouTube watch time habits I'm looking to use Firestore with Google auth to store the user's data, though I'm not proficient with the back end nor with databases, I just think that NoSQL is convenient enough The current data format that's stored locally: ```yaml [yyyy-mm-ddThh:00:00]:...
SShane4/20/2024

next auth help

does anyone have experience with next auth? I'm finding the documentation to be sub par. Currently I'm struggling to figure out how to handle signin errors using the credentials provider.
โ˜ขโ™ฌ ล•ฮ”ฤป๐”ญแ•ผ__ั˜๐š๐“ƒ ๐Ÿ‘ฝโ˜น4/19/2024

PHP server

What is the best server to use for php ?
SSantos.4/17/2024

Best start language

Hi guys, I would really appreciate your help, basically I already have a few hours when it comes to HTML CSS and a little bit of Laravel but I would like to start focusing on a language and learn a lot about it because despite knowing how to use Laravel a little, it doesn't give me much code logic and I really need to learn this and I would like to hear your opinion on what would be the best language to give me this knowledge, as it doesn't necessarily have to be in the web area, it can be any language and I have started to have a greater taste in back end parts than front end Thankss...
No description
TTenkes4/14/2024

Next.js v14 | Issue with intercepting and parallel routes

Hello. I'm working on social media app. Here's file/folder structure of my app directory: ``` app โ”‚ favicon.ico โ”‚ globals.css...
Sskywizard4/12/2024

Why did redis change my c drive name

Pretty much what is says in the title, does anyone know why redis would change the name of my c drive? I've looked it up online to no avail...
Yyogi4/11/2024

I cannot see the cookies using fetch in react but I can see the cookies in thunderclient

```jsx <Button onClick={async () => { console.log("log bth clk"); const response = await fetch("http://localhost:3000/login", {...
No description
Next