Posts by Thales Morais • 125 points
13 posts
-
0
votes1
answer237
viewsQ: How to handle errors in sequelize create
Hello, I would like to know how I can treat possible errors when performing a create with sequelize for example considering the following insertion Livros.create({ BK_TITLE: data.title, BK_GENRE:…
-
1
votes1
answer1128
viewsQ: Pass parameters on express redirect + Node + ejs
Hello, I want to pass parameters in redirect the same way I do in render method, I need it redirect because I do not want to render a page but redirect to the API route that is already rendering the…
-
-1
votes3
answers157
viewsA: Why doesn’t View see the javascript file?
If you are using Node.js with express make sure you have put the new.js as Static file as below: app.use(express.static(path.join(__dirname, 'js/novo.js'))) And it is important that the file has…
-
0
votes2
answers1811
viewsA: I cannot access my Mysql Mariadb database
Try to open your terminal and use the command mysql -u root -p this command will prompt your mysql password after typing must access mysql from the terminal. If you normally access the error is in…
-
2
votes1
answer286
viewsA: How to check the Code status of an ajax request
I was able to solve the problem in question. I’ll leave the answer here in case anyone has any doubts solved using the third callback parameter of the ajax done function as below: register.done((e,…
-
1
votes1
answer286
viewsQ: How to check the Code status of an ajax request
I have a very simple AJAX request. But I wonder if you can read the status code returned within the method done. More or less like below: $('#form-aluno').submit(() => { let data =…
-
0
votes1
answer23
viewsA: Link string inserted in a 'sub-category' field to a category
If this is how to do this with php. Simply take the category input data with Get or Post and enter it into the database using a query by PDO or using ORM methods if you are using. If this is how to…
-
0
votes2
answers268
viewsA: Return data via Ajax
Apparently the ajax request is not wrong. There must be some error in your php script I did a simulation here with a similar code and it worked. Make sure you added jquery and javascript to your…
-
1
votes0
answers38
viewsQ: Limitation of 6 Requests followed in ajax
Hello, I’m making an application where I make an ajax request to register in the bank, the request is working smoothly. However I noticed that only accepts up to 6 requests in a row without updating…
-
0
votes1
answer266
viewsA: Save form output to txt
You can do this using the php fopen function and to take the data from the Voce form you will need a request of type Submit (get or post) it is not possible to take the data with php without…
-
1
votes0
answers1053
viewsQ: Pagination with sequelize + Node.js
Hello, I am developing an application Node.js where I have to list a register of classes. But as the number of records are many need to make a pagination, I achieved this by making a function with…
-
5
votes1
answer4672
viewsQ: How to use SQL "LIKE" in Sequelize?
I am developing using sequelize but as it is my first time using this ORM I am with some doubts. I have the code below to make a query in the database through an input type text but I am using the…
-
1
votes1
answer271
viewsQ: What use are the keys in the variables of Node.js
ola, I have a doubt a little amateur I’m starting with Node.js and through my learning I came across a situation and I would like to understand, in one of the codes I researched I found a variable…