Posts by LucaoA • 658 points
29 posts
-
0
votes1
answer33
viewsQ: Consultation Entity without its Associations
I’m creating an app with JAVA SE + HIBERNATE. I am having a "problem" in making a query to a single Entity. Then, it would be possible to make a query in the entity(TABELA) without the relational…
-
3
votes2
answers302
viewsQ: Questions about the Spring XML file?
I am developing an application that uses JAVA SE + SPRING. I have some questions regarding XML: Where I create the file xml of Spring ? What name do I give to the arquivo xml ? XML would be the…
-
1
votes1
answer314
viewsQ: Mapping the same entity class to two banks
Good afternoon Earthlings, I am a beginner in java and I have the following situation. I have two databases, where I will transfer the records from one database to the other. There is the…
-
2
votes1
answer397
viewsQ: @Onetomany without Primary Key
There is the possibility of making a relationship @OneToMany without Primary Key on the daughter table? Follow my two entities. Entity Noticia: @Entity @Table(name = "NOTICIA") @NamedQueries({…
-
-1
votes1
answer721
viewsQ: Creating Thread Dynamically with Spring-boot
Good morning earthlings, There is the possibility to make spring-boot create thread when needed and also kill the same ?
-
0
votes1
answer129
viewsQ: Passing a variable to Annotation
I’m reading a JSON (using Jackson) and wanted to take that value and assign it to Spring-Boot Annotation. Would it be possible ? Follow the example below: @Scheduled(fixedRate = 14400000) public…
-
1
votes1
answer51
viewsA: What is the procedure for entering 1 only 1 checkbox value in mysql with php?
<form method="post" action="trata_check.php"> <input type="checkbox" name="um" value="1" id="" <?= (isset($dados['um']) && $dados['um'] == 1) ? 'checked' : '' ?> >Um…
-
3
votes2
answers1597
viewsA: Query per month and year (Php + SQL)
The code below will return all records that are between this date range SELECT suascolunas FROM sau tabela WHERE colunaData BETWEEN dataInicio AND dataFinal;
-
3
votes1
answer493
viewsQ: Finding out which value is higher
Follow the code below: <?php $timeZone = new DateTimeZone('UTC'); $dataInicio = new DateTime('2016-06-14', $timeZone);//dataFinal do evento $dataFinal = new DateTime('2016-06-25',…
-
2
votes3
answers119
viewsA: Error in the Checkbox
Try it that way > $rz = mysql_query("select * from mulempresa where id_contrato = $id2 "); $ck1 = mysql_fetch_array($rz); while ($lo = mysql_fetch_array($ro)) { $id3 = $lo["id"]; $nome_menor =…
-
2
votes2
answers577
viewsA: How does Alert show when marking checkbox in a table?
Follow the example. This way it will work for all checkboxes $(document).ready(function() { $("input[type='checkbox']").on('click', function() { if (!$(this).prop('checked')) { alert('Tem certeza de…
-
1
votes0
answers33
viewsQ: Using TAGS in PHP
Use of TAG <?= On the PHP website, it says is not recommended use this tag syntax. Below is the excerpt. When PHP interprets a file it looks for the opening tags and closing, which tell PHP to…
-
1
votes2
answers624
viewsA: Call javascript by passing php variable
Good I would recommend you assign the variable for an input and there in javascript you do the value capture. <input type="hidden" value="<?= $suavarial ?>" id='cidadeClima'/>…
-
1
votes1
answer159
viewsA: How to change the text of a <p> inside php? Can you insert a snippet in Javascript?
$(document).ready(function() { $("input[type='text']").on('change', function() { $.ajax({ type: "POST", url: "suaurl.php", data: { 'nickName': $.trim($(this).val()) }, dataType: 'json'…
-
9
votes2
answers19928
viewsQ: Difference between file_get_contents and Curl ?
I wonder if there is any difference between using Curl and file_get_contents and which is safer ? Thank you in advance.
-
0
votes1
answer61
views -
2
votes1
answer781
viewsA: How to get the name of the month in an input type=Month?
Below I will cite some possible ways => <?php ############################################################ ############## Essas configurações podem ser settadas no seu servidor Web…
-
2
votes2
answers1706
viewsA: How to exchange the checkbox value with jquery
As you are working with ID selector, the code below is only for a checkbox. $(document).ready(function() { $('input[id="checkbox"]').on('change', function() { $(this).val(2); alert($(this).val());…
-
1
votes1
answer61
viewsA: Doubt to use combobox
Here’s a very basic example. I think this will solve your problem, but understand the logic. Javascript is responsible for hiding the selected option and replicating in the other selects. That way…
-
1
votes1
answer383
viewsA: Return php to Jquery
In Javascript: function produto(data, callback) { $.ajax({ type: "POST", url: "_required/sessaoCarrinho.php", data: {idProduto: idCampo, novaQuantidade: novaQuantidade}, dataType: 'json'…
-
0
votes2
answers72
viewsA: Show Div if note is less than 8
Follow the script using jquery $(document).ready(function() { showDiv('.select'); $('.select').on('change', function() { showDiv('.select'); }); }); function showDiv(selector) {…
javascriptanswered LucaoA 658 -
0
votes2
answers794
viewsA: Radio button check with BD data
I checked that if you upload the page by F5 in the Firefox, it does not obey the stipulated rule, but leaves selected always the last (should cache). But if you reload with ENTER or CTRL+F5, it…
-
2
votes1
answer44
views -
1
votes2
answers1839
viewsA: Switch Alternative Inside Switch
Could leave with default values $valores = array( 'carro' => array('item1' => 'pneu', 'item2' => 'pneu','item3' => 'pneu'), 'moto' => array('item1' =>'gidao', 'item2' => 'pneu',…
-
1
votes1
answer7655
viewsA: String replace with single quotes - php/mysql
php accepts both double quotes and single quotes for a string. In your case it will not work with simple quotes, because the compiler will interpret that you are opening one more quote. The…
-
0
votes2
answers298
viewsA: How to insert a javascript generated html variable
In my opinion, avoid mixing html with javascrip... var resultado = [{ Nome: 'Ana' }, { Nome: 'Maria' }]; var divClone = null; var children = null resultado.forEach(function(pessoa) { divClone =…
-
1
votes0
answers61
viewsQ: PHP5.6 SSL Protocol
Can anyone explain to me the possible reasons for this mistake: Unable to connect: 35 Unknown SSL Protocol error in Connection to apisandbox.braspag.com.br:443 I’m using the Httful…
-
-1
votes2
answers672
viewsQ: Can I use IF inside FROM in Mysql?
It would be possible to do IF within the FROM? I looked but couldn’t find anything about it. Follow an example of what I want to do: SELECT usuario.* FROM ( SELECT IF( (SELECT COUNT(*) FROM pessoa)…
-
1
votes1
answer42
viewsQ: Records with close values
I need a light, I have to make an appointment to bring me registration with values close. I tried using SOUNDEX and even the phonetics function, but I did not succeed. Example: Let’s say the user is…