Posts by Douglas Teles • 771 points
34 posts
-
2
votes1
answer107
viewsQ: Polyfill with Gulp and Babel
I’m trying to polyfill a script to work with IE8+, but it solves some problems but generates others: My configuration of .babelrc { "presets": [ [ "@babel/preset-env", { "targets": { "edge": "17",…
-
0
votes1
answer132
viewsA: Fs.readFile dropping server
Tidy, a callback was missing so that it did not fall into the object insertion when it has an equal already inserted. app.post('/api/salvar_modelo', function (req, res) { var nome =…
-
2
votes1
answer132
viewsQ: Fs.readFile dropping server
I’m using a server node.js with express and created an API to record content that arrived via POST in an archive .json. It does the process correctly to a certain extent: If the file does not exist,…
-
0
votes1
answer38
viewsQ: Insert content into Webcomponents template
I’m doing a Webcomponent and I came across a situation: Content is not inside the component template. If you inspect below, the "Alert Test" is positioned below the template instead of inside. I…
-
1
votes0
answers33
viewsQ: Run scripts on route when accessed directly
Well I have a little problem that when someone accesses http://www.meulink.com/route without having opened directly in the index (http://www.meulink.com/) and navigated by menu, the scripts…
-
0
votes1
answer116
viewsA: How to make the dropdown menu work?
Just activate via jquery if you have already added the bootstrap components $('.dropdown-toggle').dropdown() <link rel="stylesheet"…
-
2
votes2
answers68
viewsQ: Get only first item from a sublist Vuejs
Well, I’m only trying to return the first item of the sub-array but I’m not getting it, the natural method {{ itens[0].name }} doesn’t work: <script…
vue.jsasked Douglas Teles 771 -
0
votes1
answer286
viewsA: how do you call the angular click event using the datatable?
Try this way using the datatable api itself: Button off token = localStorage.getItem('token'); public REST_ROOT = `${environment.api_url}/forma`; options = { dom: "Bfrtip", ajax: (data, callback,…
-
0
votes1
answer36
viewsA: Customization of automatic emails wordpress
In the plugins section, search for Codup Wordpress Email Customizer, install and activate. A configuration section will appear in the side menu (in the admin panel). Edit the template in the HTML…
-
1
votes1
answer41
viewsA: Data loss while spinning screen
Use put methods to store values in onSaveInstanceState: protected void onSaveInstanceState(Bundle extra) { super.onSaveInstanceState(extra); extra.putString("text", "your text here"); } And restore…
androidanswered Douglas Teles 771 -
1
votes5
answers964
viewsA: How to progress steps using thread chart?
You can try using the Highcharts, is the most complete library today and vastly customizable. I remember having customized things inside a Chart once, but it was in bars, I believe it is possible…
-
4
votes2
answers441
viewsA: Show and hide button with jQuery
Hit add "Hidden" attribute to buttons: $(function () { setDisabled(true); $("#IniciarTarefa").on("click", function (e) { $("#IniciarTarefa").attr("hidden", "true");…
jqueryanswered Douglas Teles 771 -
2
votes2
answers60
viewsA: Infinite scroll does not update with CSS class
Your .append($("#regsadd").html()); is only capturing content text because table tags are not inside a table. Added tag <table> in the content, it is now possible to capture the internal…
-
1
votes5
answers388
viewsA: How to exclude only a certain data from a React state
Scan the array and search for Ids, then remove using delete const alunos = [{ id: 1, nome: 'Julia', curso: 'Enfermagem', }, { id: 2, nome: 'Isabela', curso: 'Veterinária' }]; for (var i =0; i <…
-
2
votes1
answer37
viewsA: Saving PHP images
Create a function to resize the image using Imagemagick or GD. Then make a copy of the file and resize. <?php error_reporting(E_ALL); $file = file_get_contents("php://input"); $id =…
phpanswered Douglas Teles 771 -
3
votes2
answers74
viewsA: Problem when displaying routes in Root Api
Create a list, add the urls to that list and after that you will have all the urls from django.contrib import admin from django.urls import path, include from django.conf import settings from…
-
3
votes1
answer4714
viewsA: What are the possible causes of "Connection reset by peer: Fastcgi: Comm with server aborted" error and how to fix it?
This error is generic and may vary depending on the situation: The response of the execution is very large and because of that the connection is interrupted; Server network problem (or limitation),…
-
5
votes3
answers470
viewsA: Real value (R$) for Javascript number
Change n = n.replace(".",""); for n = n.split('.').join(""); function campo6_10Up() { var campo1 = $('#campo1').val(); // transforma para numero campo1 = formataNumero(campo1); console.log(campo1);…
-
0
votes1
answer233
viewsA: Alert on html site
You can use a Sweetalert to create your alerts easily: function meuAlerta() { Swal.fire('Eu sou um alerta!'); } <script…
-
1
votes1
answer1915
viewsA: How to read a file . Json by Delphi
Try to store json content using a memo and a Listbox to list content var jsonObj, jSubObj: TJSONObject; JSArray : TJSONArray; JSValue : TJSONValue; i: Integer; j: Integer; begin jsonObject :=…
delphi-10answered Douglas Teles 771 -
2
votes2
answers837
viewsA: Add an array inside another already created Javascript
It’s very simple, use the push to do this: var meuArray = [["1","2","3"],["4","5","6"]]; var meuSegundoArray = ["7","8","9"]; meuArray.push(meuSegundoArray);…
-
1
votes2
answers336
viewsA: I’m having import and export problems using ES6
Go to your webserver setup in the webpack and add: headers: { 'Access-Control-Allow-Origin': '*' }
-
0
votes1
answer71
viewsA: Insert value received in javascript
Changes here: $teste4 = $_POST["fp"]; To $teste4 = $_POST["murmur"];…
-
2
votes1
answer187
viewsA: Dynamically search in Capable
With javascript would be this function myFunction() { var input, filter, table, tr, td, cell, i, j; input = document.getElementById("txt_consulta"); filter = input.value.toUpperCase(); table =…
-
1
votes1
answer563
viewsA: Jquery does not work in the Mobile Browser
You’ll probably have to use jQuery Mobile. To prevent the execution from happening again, add a preventDefault() and stopPropagation() $(document).on('click touchstart', '.mais', function(event) {…
-
0
votes2
answers1897
viewsA: How to get the last record of a table in Oracle
Select the last record by ordering by sequential number select distinct a.vl_recebido --a.nr_sequencia ,b.vl_lancamento ,b.nr_sequencia ,max(b.nr_seq_baixa) ,a.dt_recebimento ,a.dt_recebimento FROM…
oracleanswered Douglas Teles 771 -
1
votes1
answer50
viewsA: Enter the site already with the little dolls
Basically it is to run the Search function as soon as it loads, instead of waiting for the click: showPeople(); function showPeople() { var filtroFaixaEtaria = $("#FaixaEtaria…
-
1
votes2
answers178
viewsA: How to create event between sessions transition?
You’d have to do more or less that: var secs = document.querySelectorAll('section'); var currentSection = 0; document.querySelector('#arrow').addEventListener('click', move); function move(e) { if…
-
0
votes2
answers93
viewsA: Pass a list to another page - javascript
This probably can not do only with javascript. What you will have to do is create a json containing the data from the first page and adding a status to the object you clicked on remove, for example:…
-
0
votes3
answers75
viewsA: How to add dropdown to menu
Use Bootstrap and you will be able to do many things with ease: https://getbootstrap.com.br/ <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>…
-
2
votes1
answer83
viewsQ: Handle Multiplus elements by ID
My question is the following: I am customizing a bootstrap File Input, and at the same time transforming it into a plugin. The customization was done, but the problem now is to make the file removal…
-
0
votes2
answers157
viewsA: pick up text selected by the user
Try straight through: var string_texto_selecionado = document.querySelector('.mine-editor-de-texto').contentWindow.document.body.value;
-
2
votes2
answers374
viewsA: icone no accordion bootstrap 4.0
That’s what you want? <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> <meta…
-
1
votes3
answers1269
viewsQ: Get file folder with Nodejs
Hello, I am trying to get the file folder but without success. I’ve tried with path, with __dirname, process.cwd(), but all return the complete path, for example: C: Node folder where is the.js file…