Most voted questions
150,413 questions
Sort by count of
-
3
votes1
answer79
viewsAdding to a list itself. What happens?
l1 = [1, 2, 3] l2 = l1 l1.append(l2) print(l1) Why does this algorithm return a three-point list? What does this new list mean?
-
3
votes1
answer222
viewsHelp to get decimal value of mask input (Ionic 3 + br Masker)
I am having a hard time with a problem that I believe is very easy to solve, but I am struggling hard enough to reach such a solution. I have a simple input that format using the brmasker library…
-
3
votes2
answers58
viewsHow to use jquery in an Angularjs directive?
I tried to put a function in jQuery within a directive, but it’s not working. I searched and found in several places talking about jqLite, but I could not convert jQuery to jqLite.…
-
3
votes1
answer131
viewsAspnet Core API with Entityframework Core - Disconnected Entiades
My scenario is the following: I have an Aspnet core API that uses Entityframework for data access (postgree database). When I receive content in Json by the API (Put) and need to update the template…
-
3
votes2
answers2705
viewsHow to store an input value in a variable and show it
I’m trying to get a value from some inputs with Javascript to show them in a specific order. <form id="formulario" name="" method="" action=""> <p><h2 id="titulo-form">Dados do…
-
3
votes1
answer447
viewsMenu using Css Grid
I’m starting my studies with CSS Grid and to train I’m trying to make a simple menu, the structure of my grid has 4 columns for 4 lines, as defined in the code. I am trying to make the menu using a…
-
3
votes1
answer755
viewsGet path of valid files with regular expression
Context: I am monitoring file deletion and inclusion actions in a folder through Class FileSystemWatcher with the intention of registering a Log of the actions performed in it. Problem: This folder…
-
3
votes3
answers333
viewsReturn text between keys, without returning the keys themselves
I used the following java regular expression to return strings that are between keys: \\{[^\\}]+?\\} My program worked almost correctly, but it even returns the key. Algorithm: public static void…
-
3
votes1
answer106
viewsMysql - Phpmyadmin error running Trigger
Hello, when I try to run the following Rigger, I get this error: #1064 - You have a syntax error in your SQL next to line 11 Follow the Trigger: CREATE TRIGGER atualizacao after update ON cliente…
-
3
votes1
answer38
viewsQuery with AND operator in Elasticsearch
I have a query of Elasticsearch would be using the operator AND to find the two words (fast AND car) which must have the two words in the result, no matter if the two words are in the title or if…
elasticsearchasked 5 years, 4 months ago Jean 33 -
3
votes2
answers689
viewsDisable link with jquery
Good afternoon, you guys, I’m having a problem trying to disable a link using jquery. The problem is this, There is a table that lists the types of roles a user can have in the system that presents…
-
3
votes2
answers3143
views.antMatchers(). permitAll() does not seem to work
Edit02 Habilitei spring-security in my project, and now every API needs authentication, perfect was what I needed. But I want only one API not to need authentication. I tried to use…
-
3
votes0
answers98
viewsProblem when displaying image inside modal
I need to display a list of selected images in a modal, but it is displayed only after clicking (focusing) somewhere in the modal. Excerpts from the code: HTML: <label>Imagens: </label>…
-
3
votes2
answers51
viewsWhy doesn’t Event exist inside the lower block?
I’m having trouble accessing the event.target within the function setTimeout in the code below. const botao = document.querySelector('button'); botao.addEventListener('click', () => {…
-
3
votes1
answer40
viewsonKey() method is not triggered as desired
I’m trying to capture the enter key to jump from one EditText to another. The problem is that the method onKey() is not called when I press a key, for it to run I need to hold the key for a while.…
-
3
votes1
answer143
viewsBeautify inline review
I am using the extension Beautify in Vscode to better organize my code, however I found a problem and I did not find the solution, it always plays the comment to next line. How to fix this?…
-
3
votes2
answers79
viewsUse user, email or one of the two for authentication?
I am developing an application that, like all others, will need the user’s email for some purposes. Each user will also have a unique username for their profile page: /u/:username The question is:…
-
3
votes2
answers37
viewsDoubt as to whether to exclude specific elements of the clone() function
I have a doubt about the exclusion of specific elements when I use the function clone(). I wonder if I can rule out the elements <b> when I call the function. That is, what is written "Item",…
-
3
votes1
answer47
viewsWhat is the difference between 'CSS Filter Effects' and 'CSS filter() Function'?
I’m researching about browser support for the property filter of CSS and the tag <filter> of SVG. My search link: https://caniuse.com/#search=filter What’s the difference between CSS Filter…
-
3
votes2
answers626
viewsWays to initialize struct’s
I know these two ways to boot struct's. #include <stdio.h> typedef struct { char s[10]; int a, b; double x; } TIPO; int main(){ TIPO v1[10]={"foo", 5, 13, 4.3, "bar", 0, 0, 2.3}; TIPO…
-
3
votes1
answer171
viewsPython isset check (details)
My question is this, in PHP I have a code curl that returns some json as you can see in the code: $response = curl_exec($request); $header_size = curl_getinfo($request, CURLINFO_HEADER_SIZE);…
-
3
votes1
answer122
viewsC# How to change value within Parallel.Foreach
I am performing a processing inside an array of strings (lines of a file . txt). For performance reasons, I’m using the Parallel.ForEach, but there was a need to change the values of some lines that…
-
3
votes1
answer64
viewsLoop command to group values from a database into a new list
Good afternoon, everyone! I’m starting in R (starting well) and tried to make a script to solve a simple operation that, however, was performed entirely in excel during a mini-course I did, giving a…
-
3
votes1
answer59
viewsDifferent ways to do a query that performs an SQL merge
I learned to do SQL queries with joins as follows: SELECT u.NOME, e.RUA FROM usuarios u, endereco e WHERE e.ID_USUARIO = u.ID ORDER BY u.NOME As you can see, the query searches the name of users and…
-
3
votes1
answer464
viewsError importing image: Allowed memory size
I’m using a simple script to crop the image, while cropping some images it gives this error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 155648 bytes) in…
-
3
votes1
answer62
viewsDoubt with Viewdata using Asp.net core 2
I made an example for testing using Viewdata, apparently it should work, but it is generating me a reference error, as message below. The type or namespace name 'Student' could not be found I made a…
-
3
votes3
answers93
viewsAlignment of photons
I’m trying to align my form this way: But I can’t get the inputs Yes and No to line up on the right. I tried to use bootstrap and split it into cols but unsuccessfully as well. Follows html and css…
-
3
votes1
answer545
viewsCreate new column from existing column in R
I have a database in which the first column has the code of the disciplines of my institution and the second column has the name of the respective discipline. I want to create a third column where…
-
3
votes1
answer94
viewsGrouping of values
I have an application that generates the following results: I would like to know how I can arrange the object in only 1 line, say have only one date, and within the date have the schedules, to have…
-
3
votes1
answer922
viewsWhy is it not possible to use an "alias" in the WHERE clause in Mysql?
I need to wear a alias in the clause WHERE, but keeps telling me it’s an "unknown column". I need to select records that have a higher rating than X. The rating is calculated as the following alias:…
-
3
votes2
answers642
viewsWhat is SQL dialect 1 and dialect 3?
I don’t understand very well with these database deals but it made me curious these SQL dialect. What SQL dialect? What is the difference between SQL dialect 1 and SQL dialect 3? And what’s the…
-
3
votes1
answer61
viewsWhy do I need to add a parenthesis under multiple conditions of a ternary operator?
Let’s start from the following values: $foo = 1; $bar = 1; As the extra condition placed on else without parentheses, the result does not match the intention of the operator: echo ($foo &&…
-
3
votes1
answer40
viewsHow to reference columns in a R function?
My question is how to announce a column in the Arglist of a Function.Example: I want to do this library(data.table) a<-mtcars data.table::setDT(a) a[,.( disp2 = sum(disp), cyl2 = mean(cyl) ), by…
-
3
votes1
answer555
viewsProblems with Python3 in connection with Firebird2.5
I made this Python code (basic connection with Firebird): import fdb con = fdb.connect( host='192.168.1.17', database='/home/firebird/questor.fdb', user='sysdba', password='masterkey' ) cur =…
-
3
votes1
answer183
viewsIs it possible to define async as the initializer method of a Python class?
Let’s say I have a class where I need to initialize a field with the return of a corotina: import asyncio class Server: def __init__(self): self.connection = await self.connect() async def…
-
3
votes1
answer62
views -
3
votes3
answers165
viewsreturn values of a javascript object
I have this object in which I need to take the largest portion with the rate 0 (without interest) and its value, and also take the largest number of installment available and its value.. I’ve tried…
-
3
votes1
answer1209
viewsPOST communication Ajax for Flask
I would like a help with a Python application using the Flask framework, I want to send and receive data via Javascript using Ajax, but I’m not sure how to do, all I got was a collection of…
-
3
votes1
answer1548
viewsHow do I place Text inside a Shape made with CSS? Is it possible to place text inside a circle?
I know CSS evolves slowly, but I’ve seen a lot of new things out there, especially with the more modern browsers that accept very new properties. My question is whether there is already any way to…
-
3
votes1
answer14667
viewsREACT-JS - Warning: Each Child in a list should have a Unique "key" prop
Problem in rendering my state always gives error: Warning: Each Child in a list should have a Unique "key" prop. Check the render method of Main. See https://fb.me/react-warning-keys for more…
-
3
votes1
answer285
viewsDoes the Python Tkinter library still exist?
I use Ubuntu and as this library does not come installed by default on linux, I was trying to install it via Pip but I can not find it on the official Python site.
-
3
votes1
answer280
viewsWhere x whereRaw What’s the difference?
I tried to read Laravel’s documentation, but I didn’t really understand the difference. I also tried to search for other links but, I usually see topics in forums asking for help on the use and…
-
3
votes1
answer99
views"For" 'lagando' interface
I have a JSON I’m using to generate an HTML in a app Cordova as follows: function gerarLista(lista) { strHtml = ""; for(item in lista) { strHtml += '<div class="item">'; strHtml += '<div…
-
3
votes0
answers100
viewsHow to export . csv with Django-Tables2?
I am trying to export a table with Django-Tables2, I have done the following so far. Tables py. class ClienteTable(ColumnShiftTable): class Meta: model = Cliente sequence = ('id',…
-
3
votes3
answers279
viewsRegular expression to ignore quote separator
I have to read a csv file with delimiter ;. Only it has lines with values """Analize;Distribuição""", only that it creates another column in this ;. How can I read so he won’t accept ; in quotes as…
-
3
votes1
answer495
viewsCreate an executable in R through the Shiny package
I wonder if it is possible to create an executable that goes directly to the panel generated by Shiny code without having to open the R and execute the codes library(shiny) # Define UI for…
-
3
votes1
answer585
viewsJoin two arrays in one with PHP
I have the following PHP: <?php $itens1= array("fruta1"=>"laranja", "fruta2"=>"morango"); $itens2= array("fruta3"=>"goiaba", "fruta4"=>"uva"); array_push($itens1, $itens2); echo…
-
3
votes2
answers450
viewsBar graph with ggplot2
How can I make a graph with the data below comparing the two areas? I would like to leave the Cerrado bars on the side of the Bosque bars. I tried many times, but I could only build the chart for…
-
3
votes1
answer516
viewsHow to solve "Clean your tree for work"?
Me and the team I’m with, we work with GIT + Visual Studio Code... When we touch the same file, when we commit/pull the files, the following error occurs: There is some way to solve this, because…
-
3
votes2
answers1083
viewsPasses template content to view Django
Well I know it is possible to take content from a view and move to a template. But the doubt would be like taking the "value" of an input and passing to a view, an example of the use would be.…