Posts by Guilherme Nascimento • 98,651 points
2,383 posts
-
2
votes2
answers136
viewsA: What does test_size = 20 mean?
I believe this API is about https://scikit-learn.org/ So this using the function https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.train_test_split.html The description…
pythonanswered Guilherme Nascimento 98,651 -
0
votes1
answer38
viewsA: Mcrypt PHP exention Missing! Error installing application
The extension=php_intl.dll has nothing to do with Mcrypt API or mysql API, requirements or mention: https://www.php.net/manual/en/mcrypt.requirements.php…
-
1
votes1
answer152
viewsA: Translate at angular 6
If Translate isn’t added to the modules, there’s no way the service starts or recognizes it, then in the app.modules add: import {TranslateModule} from '@ngx-translate/core'; ... @NgModule({…
-
2
votes1
answer16
viewsA: How to stop running function setinterval when I call another?
Using clearInterval, thus: var intervalAum, intervalDim; function aum(){ clearInterval(intervalDim); //Para as repetições de "dim" intervalAum = setInterval(aumenta,200) } function dim(){…
javascriptanswered Guilherme Nascimento 98,651 -
2
votes1
answer30
viewsA: How to set a fixed key for an array?
Simply iterate with a for or foreach and add to a new array, it’s the basics of the language: $trackers = array( 'udp://9.rarbg.to:2970', 'udp://tracker.coppersurfer.tk:6969/announce',…
-
3
votes2
answers80
viewsA: Where do I add the ". py" calculations to the HTML page?
Python scripts do not run directly on the "frontend" and even if someone says it is possible, it will not in fact be what happened, what can be at most is that executed something like the @utluiz…
-
1
votes2
answers709
viewsA: HOW TO APPLY A BACKGROUND COLOR TO AN ANGULAR COMPONENT?
This is wrong: *margin{ margin: 0; padding: 0; } The right thing would probably be this *, which is the global selector, so: * { margin: 0; padding: 0; } But you don’t really need to take the…
angularanswered Guilherme Nascimento 98,651 -
1
votes1
answer32
viewsA: Exchange export version of Excel with PHP/Mysql
This is not EXCEL, is an HTML that by coincidence has a reasonable support in Office programs like Msexcel, but it is not actually excel, nor XLS nor XLSX, it is only HTML, so it has no version. No…
-
1
votes1
answer83
viewsA: xampp error on linux Ubuntu
The coffecode/uploader this making it clear, need to enable GD, GD is native to PHP. If it’s PHP 5.6 install it like this: sudo apt-get install php5.6-gd If it’s 7.0 PHP: sudo apt-get install…
-
1
votes1
answer29
viewsA: How to take 6 photos In a row just using Kivy?
And it’s not just calling 6 times the function? camera = Camera(play=False) camera.export_to_png('c:/fotos/1.png') camera.export_to_png('c:/fotos/2.png') camera.export_to_png('c:/fotos/3.png')…
kivyanswered Guilherme Nascimento 98,651 -
2
votes1
answer49
viewsA: How to detect joystick events from the browser?
The event itself keydown takes the events of the buttons of some joysticks/controls, in case could enumerate them so: document.addEventListener("keydown", function(event) {…
-
1
votes1
answer29
viewsA: My Flexslider video is starting automatically, but I don’t want it!
The video has nothing to do with the slide, only this contained inside it, you could put anything inside the slide, expect the slide control beyond what it was programmed to do makes no sense, so…
-
0
votes1
answer21
viewsA: How to fix the error of storing a Select in an Array?
If $lista_datas is an array, so you have to use the [] or array_push, thus: while($row = $result->fetch_assoc()) { $lista_datas[] = $row['XDaTas']; } Or with the function: while($row =…
phpanswered Guilherme Nascimento 98,651 -
3
votes1
answer61
viewsA: Php Login Screen Not Authenticate
session_start is missing, sessions only work with session_start, so: <?php include('conexao.php'); if (empty($_POST['usuario']) || empty($_POST['senha'])){ header('Location: index.php'); exit();…
phpanswered Guilherme Nascimento 98,651 -
6
votes1
answer241
viewsA: Onkeydown event does not work in full-screen (F11) mode in Chrome
Detect the F11 with the event keydown is working perfectly in Firefox, apparently the fault occurs only in Google Chrome (and in Chromium-based browsers), although it has not found anything in…
-
3
votes1
answer133
viewsA: Extract part of URL with PHP
You can simply use regex, as long as the site URL is "fixed", doing something like: <?php $url = 'https://www.localhost.com/desconto/nome-da-loja/'; if…
-
2
votes1
answer81
viewsA: I cannot use the global var $_SERVER['PATH_INFO']
The variable PATH_INFO is even common in Apache, but not every server will own it, because it is not always configured (depending on each server), basically you have to configure it manually, in…
phpanswered Guilherme Nascimento 98,651 -
4
votes2
answers126
viewsA: PHP Exec Returning unknown characters when executing commands
The commenting and the another answer are mistaken, it has no sense to force encoding in this case, you can even choose to use iso-8859-1 or utf-8 in your page’s HTTP response, but simply what the…
-
2
votes1
answer99
viewsA: Find widget from code
You can use the selector element[atributo*=valor], he will search anywhere, example: using OpenQA.Selenium; using OpenQA.Selenium.Support.UI; using SeleniumExtras.WaitHelpers; ... var wait = new…
-
1
votes1
answer141
viewsA: Error "content-type is not allowed by Access-Control-Allow-Headers in preflight Response." -API Climatempo
They don’t accept the contentType: "application/json", in the configuration of Cors, in fact it is not necessary, because the contentType does not say what you expect from reply, it only states that…
-
1
votes1
answer78
viewsA: Rule for . htaccess
Rewrite need not "escape" the / with \ (also does not affect anything to have) in this specific case, your middle bar does not even need the ? (indicating the previous group or character as…
-
2
votes1
answer99
viewsA: Future of Javascript, how can I know about possible language innovations/abilities?
First you need to understand that it is not because a new function, method, API or syntax are set that this will exist magically in all browsers, define something only says as something should be,…
javascriptanswered Guilherme Nascimento 98,651 -
3
votes1
answer78
viewsA: How to predict next results from an array within the foreach
Before answering I need to warn you, your Theads are being generated on the same level as the other Trs that do not belong to the Theads themselves, there should be a TBODY in each, but the main…
phpanswered Guilherme Nascimento 98,651 -
6
votes1
answer2989
viewsA: What is the key:generate command for Laravel?
The command key:generate is used to set a new key in your file .env, that is located in the home folder, it arrow the value within .env in: APP_KEY=<chave gerada> Note that when running:…
-
2
votes1
answer38
viewsA: Get User Directories (Windows)
In Dart as far as I have seen there is no way to dynamically get directories like: /home/<usuario>/* (generally linux) /Users/<usuario>/* c:\Users\<usuario>\* At least not with…
dartanswered Guilherme Nascimento 98,651 -
0
votes1
answer34
viewsA: syntax error, Unexpected 'function_construct' WEB SERVICE PHP
XML is not being generated in index.php, if you access yourself directly would notice the error message, then the problem is not in the simple_load_xml, you wrote in the index.php: public…
-
1
votes1
answer37
viewsA: The password reconfiguration link cannot be clickable in the user’s email
If your message is actually coming in "HTML" it is likely that the email client will not accept the link without HTTP, because it thinks it is an attempt to redirect to something internal from the…
phpanswered Guilherme Nascimento 98,651 -
8
votes2
answers176
viewsA: I can’t redirect with PHP using header()
The whole problem is that you don’t understand HTTP yet, I’ll tell you something, most say understand HTTP, think that studying a day or two dominates it, but it’s pure illusion, it’s necessary to…
phpanswered Guilherme Nascimento 98,651 -
1
votes1
answer47
viewsA: Calculate the difference of months
I got the error: PHP Fatal error: Cannot redeclare geraTimestamp() This is clear because if you use more than once the function it will call the statement again every time you use the function,…
phpanswered Guilherme Nascimento 98,651 -
3
votes2
answers78
viewsA: Using Promise Javascript
The question isn’t even the Promise, the question is you understand the fetch API, understood the basics then will be able to use, since Promise is something more general and "changes the behavior"…
-
1
votes3
answers291
viewsA: Asp:Textbox type="date" is not completed
The format of the attribute value= to the type=date should be this: <input type="date" value="2020-02-05"> And not this: <input type="date" value="02/05/2020"> See that the second does…
-
1
votes1
answer40
viewsA: preg_match to pick words between single quotes and remove blanks from the end of match[1] with the same Pattern is possible?
Just for the record, your codes here don’t print arrays: print_r ($s1); print_r ($s2); Although you state that the output is an array, and something else, in the variable name is $pattern, but you…
-
2
votes2
answers34
viewsA: How to solve a depreciated each() problem?
It’s not necessary foreach to perform an operation so simple which can be written, if image is an array of 2 values (probably more, and probably used getimagesize), if you have this: array(7) {…
phpanswered Guilherme Nascimento 98,651 -
5
votes2
answers634
viewsA: How to use different . Kv files in a Kivy application?
Because of your need it appears that you need not only to load the next phase, but also to close/download the previous one, because in case you don’t, it will take up memory in your project, so to…
-
2
votes2
answers105
viewsA: fopen(/home/loyusgyp/public_html/logs/log_jurosefine/log_2020-02-02_18-00-01.txt): failed to open stream: No such file or directory in (Cpanel)
The mistake failed to open stream: No such file or directory is about the location below not existing: ../logs/log_jurosefine The problem Has nothing to do with the opening mode of fopen ("a means…
-
2
votes1
answer83
viewsA: How to filter and sort rewritten JSON elements with PHP?
I found no question about filtering and ordering the output of a rewritten JSON. There is no such thing as filtering JSON, you write already filtering the object, it is you who is controlling the…
-
1
votes1
answer141
viewsA: PHP - How to receive a data stream from a Python post?
First, reading the documentation helps a lot, rather than programming by kicking how things work. According to, is so much error in your code, You can see right away that this is wrong:…
phpanswered Guilherme Nascimento 98,651 -
4
votes3
answers171
viewsA: Is there a native Javascript method that returns the sum of the elements of an Array ? How does array_sum() do in PHP
When something is that simple I really don’t see any reason to exist native and probably the developers of Ecmascript (aka Javascript) probably "agree", not that they haven’t created functions for…
javascriptanswered Guilherme Nascimento 98,651 -
1
votes1
answer809
viewsA: Create a Javascript input Mask to accept values up to 4 decimals
You don’t need scary plugins and you don’t need to use jQuery for something so trivial, you can do it by hand, learning the basics for real, of course. An example of mask I made with pure JS helps…
-
1
votes2
answers915
viewsA: Error "Property 'REDUX_DEVTOOLS_EXTENSION_COMPOSE' does not exist on type 'Window & typeof globalThis'."?
This mistake, like me commented, is a compiler/transpilator problem (call as you wish) that runs "out" of the browser, every time the Typescript transpilator notices an update in their sources it…
-
1
votes1
answer86
viewsA: Access specific folder project
Just don’t use RewriteCond before, just point everything to ./frontend directly and then in the next rule you write the "routes" of the Angular, so: RewriteEngine On # Redireciona tudo RewriteRule ^…
-
1
votes1
answer77
viewsA: System.Typeloadexception
As the discussion cited by Felipe: https://github.com/dotnet/efcore/issues/17788 is in fact a BUG, in case the official fix has not yet come out, however it is suggested to install the package. With…
-
2
votes1
answer385
viewsA: Fatal error: Uncaught Error: Call to a Member Function bind_param() on Boolean in C: xampp Stack trace: #0 {main} thrown in C
That is typo your. In the middle of your Insert has several ??, or is missing commas between them, you’re passing 97 parameters, but in the interrogations you only passed 91, counting by the commas,…
-
2
votes1
answer93
viewsA: Access denied to directory
If it were possible to edit what is inside program files without permission it would be a huge security breach, which I recommend at least is you use the user level folder, but for each user will be…
-
3
votes2
answers659
viewsA: What is the print(' a') function in python
This probably only works on some terminals because the developers keep it for some interest or compatibility and of course this can only run in terminal, if you try to run elsewhere, like pycharm,…
python-3.xanswered Guilherme Nascimento 98,651 -
3
votes3
answers343
viewsA: How to view docx and pdf directly in the browser?
Nothing guarantees that it will be viewed, even if you force via .htaccess all documents of the type docx using this: <FilesMatch "\.(?i)(doc|doc|xls|xlsx)$"> Header set Content-Disposition…
phpanswered Guilherme Nascimento 98,651 -
13
votes1
answer181
viewsA: CSS writing methodology using : in class name ( Tailwind CSS )
The exhaust is used for years, but in most cases it is unnecessary, if you can write something simpler separated by hyphen (-) or by underscore (_) why appeal to something like this? So almost…
-
1
votes1
answer35
viewsA: Dict with repeated Python attributes
Probably this: formdata = { 'data': '', 'controle': 'ADMIN', 'g-recaptcha-response': 'recaptcha_response', 'nu_dam' : [ '123456', '123457', '123458', '123459' ] } But it depends on the HTTP lib you…
-
1
votes1
answer30
viewsA: my express server does not find the Javascripts and style files contained in html
If you do not configure to access the files of course it will not find, because your Express code only provides the index.html, is not configured anything else besides that. To resolve "quickly"…
expressanswered Guilherme Nascimento 98,651 -
3
votes1
answer2496
viewsA: Change Pgadmin4 default browser
To change the browser, right-click the pgAdmin icon in systemTry: Selects Configure... and then in the field Browser Command: Place the path of your browser followed by %URL%, example: "C:\Program…