Posts by Angelo Soares • 366 points
21 posts
-
2
votes1
answer451
viewsA: PROXY IN NODEJS AXIOS
Hello, good night friend! You did not put the proxy the right way, you should put inside the same JSON in which one finds the headers, getting like this: axios.post('localhost:3000', postdata, {…
node.jsanswered Angelo Soares 366 -
0
votes5
answers431
viewsA: Go to certain link depending on the page
its conditions of if are incorrect... You just changed the value of the variable url under the conditions if, and the variable did not return any value booleano, therefore all conditions if were…
-
1
votes2
answers72
viewsA: Javascript help
You didn’t put the input and not the button on a form. Try to do so: let form_mes = document.getElementById("form_mes"); form_mes.addEventListener('submit', function() { let mes =…
-
0
votes3
answers63
viewsA: Sort table by date
A more ideal way would be to leave only one column to store this information... Using the type TIMESTAMP for the column. Try modifying your table like this: ALTER TABLE website_transactions DROP…
-
0
votes1
answer35
viewsA: Insert javascript value via php variable
If the file with your code is inside a tag <script> in a file with the extension . php, you can do so: window.addEventListener('DOMContentLoaded', function () { var image =…
-
-1
votes2
answers72
viewsA: Ranking PHP and SQL, without repeating database record
I suggest you do it this way, take the php block with the structure while and put inside the html, getting like this: <html> <body> <div style="background: lightgray;width:…
-
1
votes1
answer111
viewsA: Return txt lines to JSON in PHP
You can do it this way: <?php $arquivo = file("alunos.txt"); $json = json_encode($arquivo); The function file("alunos.txt") will be to take each row of the file and separate them within one array…
-
0
votes2
answers68
viewsA: move_uploaded_file saved in database, but not saved image in folder! Help
Hello, try it like this: File Upload Filing cabinet <?php $name = $_FILES["img"]["name"]; $temp = $_FILES["img"]["tmp_name"]; /*var_dump($name); var_dump($temp);*/ $banco = new…
phpanswered Angelo Soares 366 -
0
votes3
answers216
viewsA: How to take the value of a Database table field and use it in a PHP variable?
Hello, good afternoon buddy! First you must declare your variable at the top of the code: $clique = ""; Then carry out your consultation: $query = $conexao->prepare("INSERT INTO memprestimo…
-
2
votes2
answers35
viewsA: Help with php number_format
To get the return as a value float you can return like this: $subjects[$i]['mark_final'] = number_format(($final / 4), 1, ".");
phpanswered Angelo Soares 366 -
1
votes3
answers746
viewsA: How to change the color of several Ivs at the same time with Hover?
You can import the Jquery library and follow the following example: <!DOCTYPE html> <html> <head> <title>teste</title> <link rel="stylesheet" href="style.css">…
-
2
votes2
answers37
viewsA: Why are my boxes creating height?
Buddy, you set the other boxes to the same class as the <div> of the inputs have... <!DOCTYPE html> <html> <head> <title>Exemplo</title> <meta…
-
2
votes1
answer34
viewsA: hide a Featurediscovery boot when going to mobile and display any node for desktop
Friend... I haven’t looked at your code much but I understand your problem. I’ll show you an example of what to do to remove something for desktop or mobile: HTML: <div class="div-mobile">…
-
1
votes1
answer47
viewsA: php loop of images with bootstrap
The tag <img> of your code is not closed. Add a > at the end that will stay like this: echo '<img src="' . $return_user_insta->display_url . '" class="img-fluid">';…
-
0
votes1
answer59
viewsA: Doubt about SQL Injection/mysqli_real_escape_string
The way to escape string is depending on which method you are using to enter the data into the database. If it is PDO, it is putting values in bind: $stmt = $conn->prepare("INSERT INTO…
-
-2
votes1
answer180
viewsA: How to include a file from another directory in index.php
Friend, first of all, you should use Javascript... Follow the example: <!DOCTYPE html> <html> <head> <title>Teste</title> <!-- importe a biblioteca jquery para usar…
phpanswered Angelo Soares 366 -
0
votes3
answers1706
viewsA: How do I pass the time from one div to another?
Just put the height on both: #red, #gray{ height: ..; }
-
0
votes2
answers36
viewsA: Display number of comments from a single user table
Use the following: <?php $query = mysqli_query($conn, "SELECT COUNT(*) as total FROM tabela_comentarios WHERE posted_by = 'joao';"); $row = mysqli_fetch_array($query); echo "Joao comentou:…
phpanswered Angelo Soares 366 -
0
votes3
answers144
viewsA: force ssl with htaccess and angular7
Use the .htacess below, it will cause you to access any page of your site using http://seudominio.com, www.seudominio.com or seudominio.com will cause the URL to be converted to…
-
3
votes3
answers15114
viewsA: How to change the color of only one word in a paragraph?
You can do it like this <p id="paragrafo"> Bla bla bla banana <span style="color: #4286f4">uva</span> morango bla bla bla </p>
-
2
votes1
answer115
viewsQ: Add one column values to two tables in Mysql
I am a beginner in programming and I would like to know how to add values of 1 column in 2 tables, both with the same data. Just rename the table... For example: Table teste1: nome | pontos | Joao |…
mysqlasked Angelo Soares 366