Posts by Weslley C X Sardinha • 1,427 points
29 posts
-
0
votes1
answer325
viewsA: How to make modal appear only once according to check?
You can use localStorage for this task: checkbox.onclick = function(){ if(!this.checked) localStorage.mostrarModal = false; } And in the function that runs automatically for modal opening, case…
-
0
votes4
answers124
viewsA: Insert Parentheses between an acronym in the input field
For a function to be executed at each key typed, we use the event oninput: document.getElementById("quadro").oninput = function(){ var value = this.value; var arr = value.split(' '); if(arr[0]…
-
1
votes1
answer211
viewsA: change the style of a tag within another tag
The css of a parent page is not propagated to a child iframe, so don’t worry about simply putting: document.querySelectorAll('div > a').forEach(function(elm){ elm.style.color = 'white' }); So we…
-
-1
votes4
answers260
viewsA: Send data to server even if window is closed
Use web sockets! Although it seems controversial, given the previous answers, the use of sockets is the best option, since, you can check if the socket is still connected. An example using socket.io…
-
3
votes0
answers128
viewsQ: How do I exchange an HTTPS certificate without impacting old users
I own a site that was hosted on firebase, with the option for HTTPS active. One day, I decided to host it in a resale of my own, with a certificate Let’s Encrypt issued for that domain. In the new…
httpsasked Weslley C X Sardinha 1,427 -
2
votes3
answers11268
viewsQ: How to Install . ipa without using the Appstore
I have an application with approval pending at Appstore, but I need to provide a demo for a customer. What I have is . app ipa. I’ve used Diwai, but the error that always appears is: Could not…
-
0
votes2
answers526
viewsA: Update balance with revenue and expense
Instead of registering the expense with the value 10, for example, register as -10. In addition to saving a database column, it contributes to a better understanding. Return the sum of everything…
-
0
votes0
answers32
viewsQ: Is it better to leave logic in PHP or Database?
I am creating an application together with another person, she thinks it is better to put all the logic of the system directly in the database (Mysql), under the pretext that it will help if we use…
-
14
votes2
answers3112
viewsQ: What would Win32 be?
In many places on the internet, I see the expression Win32 but never an explanation about. Applications Win32, etc. I’ve always associated with 32 bits, but I don’t think it has to do. A Windows…
-
2
votes2
answers260
viewsQ: How do programs store saved passwords?
On the internet it is common to have the "remember password" in the login fields. I know this is done by the developers of the application, but how google Chrome, for example, stores a saved…
-
2
votes1
answer1150
viewsQ: Coding in C++
Hi, I would like to know how to change the output encoding of C++, knowing that the default encoding is ASCII. I’ve tried with the libraries <windows.h> and <tchar.h>,in the following…
c++asked Weslley C X Sardinha 1,427 -
5
votes3
answers1021
viewsQ: Iterated inline functions
In several articles, I read that adding an inline function within an iteration(while,for) generates an unnecessary consumption of system resources. Write down: #include <iostream> inline int…
c++asked Weslley C X Sardinha 1,427 -
3
votes1
answer128
viewsQ: Smallest unit of time possible
What would be the smallest unit of time that is currently possible to measure using ordinary computers? As far as I can tell,.
benchmarkasked Weslley C X Sardinha 1,427 -
26
votes3
answers568
viewsQ: Compute secure data randomly
Random functions are not entirely random in computation. I wonder if there is a safe way to generate a salt, or any other random string safely, without using external hardware. Can randomization be…
-
15
votes2
answers921
viewsQ: What is the use of pointers?
What is the use of pointer pointers, example: int var; int *p; int **pp; var = 50; I even understand the use of the simple pointer(*), but why use another pointer to reference this?…
c++asked Weslley C X Sardinha 1,427 -
-3
votes3
answers5650
viewsA: Regular expression to pick up the value after the comma
Just use (,25),takes all occurrences of ,25. \w,(25*) to the full number. Test in Regexr
regexanswered Weslley C X Sardinha 1,427 -
3
votes1
answer386
viewsA: PHP session is not configured
session_start() means telling the page that you are willing to deal with sessions. To access sessions, it is also necessary to session_start(). Add on your.php panel page, at the beginning of the .…
-
3
votes1
answer587
viewsA: How do I eliminate the Focus "shadow" from a <button></button>?
The button stays focused. Use CSS: *:focus{ outline:0; }
-
23
votes5
answers2310
viewsQ: Why are other encodings used besides UTF-8?
If UTF-8 encoding can represent all Unicode characters, why are there still applications that adopt other encoding standards such as ANSI? It would not be easier to abandon all those that do not…
-
0
votes1
answer580
viewsQ: How to fix a website’s indexing on Google
I have a site that is already indexed by Google, but as I already posted at the address when the site was still in tests, Google indexed some results like broken Urls, test pages, wrong…
-
4
votes1
answer92
viewsQ: Use of meta Keywords
Searchers continue to use the meta tag as relevant? There are several articles on the internet saying no,others that yes,.
-
4
votes3
answers5939
viewsA: What are the techniques for making scroll-based animations?
You can use an animation of several frames and images, this would not be very efficient in terms of internet usage, but could determine which frame should be the current with the current scroll…
-
0
votes3
answers12215
viewsA: Calculate distances between two coordinates
To calculate the distance between two points, use the following formula: Square root of: ( Xa - Xb )^2 + ( Ya - Yb )^2 Example 12, 14 is coordinate A. 4, 3 is coordinate B. The first value of the…
-
2
votes3
answers138
viewsA: Does every DIV have a relative position?
No, because when you apply: div{ top:100px; left:200px; } to div does not appear to change, whereas in: div{ position:relative; top:100px; left:200px; } is noticeable.…
-
0
votes1
answer471
viewsA: Use Fade Out/In effects when changing CSS
Instead of fade in by javascript, toggleClass Jquery along with css3 Transition, example: CSS: #imagem{ webkit-transition:1s all; opacity:0; } .visivel{ opacity:1; } Javascript:…
-
10
votes2
answers2117
viewsQ: Procedural generation
In games such as Minecraft, Cube world and Starbound there is the term "procedurally generated map". As you walk through the game, the map is created, but with a "Seed" that will always generate the…
gamesasked Weslley C X Sardinha 1,427 -
1
votes1
answer96
viewsQ: Auto benchmarking with moon
A script in C or C++ could write algorithms in Lua (by Brut force, that is, test several possible combinations) based on a database with the results of the algorithms. The idea is to get to the most…
-
1
votes3
answers1097
viewsA: Automatic file upload
Do you want the form to be self submitted? If so: <form id="formulario" method="post" enctype="multipart/form-data"> <input type="file" onchange="formulario.sumbit()" name="arquivos[]"…
phpanswered Weslley C X Sardinha 1,427 -
4
votes1
answer293
viewsQ: Assembly compatibility and architectures
I have no experience with low-level Assembly language. What is required to obtain the maximum of cross Platform with that language? I mean, if I just focus on AMD64 (x86-64) I’ll get compatibility…