Posts by Marcos A. Silva • 421 points
16 posts
-
0
votes2
answers97
viewsA: Check if time interval is within another range
I temporarily assembled this solution $valor = 100;//valor a pagar de bônus $entrada_padrao = strtotime('08:00');//fixo como parâmetro $saida_padrao = strtotime('18:00');//fixo como parâmetro…
-
0
votes2
answers97
viewsQ: Check if time interval is within another range
I need to know if it was worked within a fixed interval $entrada_padrao = strtotime('08:00');//fixo como parametro $saida_padrao = strtotime('18:00');//fixo como parametro $entrada_trabalho =…
-
1
votes1
answer432
viewsA: How to make paging inside a modal in bootstrap?
Have you tried using the Tabs component of the bootstrap itself? Bootstrap TAB
-
1
votes1
answer401
viewsQ: Count record of two date fields grouping by year
I need to get the sum of records of two fields from the same table but grouping the year to assemble an Areachart chart -- -- Table structure cadastros CREATE TABLE IF NOT EXISTS `cadastros` ( `ID`…
-
5
votes1
answer358
viewsQ: What is the amount of $_POST records of a dynamic input form?
I have a form with dynamic fields but I realized that when sending it limits to 166 records. In my form the fields are inside a WHILE so: <input name="contagem[]" type="hidden" value="<?php…
-
0
votes1
answer59
viewsQ: List data from 2 tables linked to the parent table
ORDER TABLE --------------------------- | id_pedido | pedido_data | --------------------------- | 1 | 2016-01-01 | --------------------------- TABLE PEDIDO_ITENS…
-
1
votes1
answer981
viewsQ: Get complete XML content without removing tags
I need to get the full contents of an XML file to insert it into the database. I have tried fopen but it removes the tags, and with simplexml_load_file returns array. $ponteiro = fopen…
-
0
votes1
answer1992
viewsQ: Show profit or loss in negative percentage
Considering the following data: $despesas = 2000; $receitas = 100; $lucroprejuizo = ($receitas - $despesas) / $receitas)*100; I have a result of: -1900% But if any of the variable revenues or…
-
1
votes1
answer546
viewsQ: $_POST without closing modal bootstrap
I have to open a form in a modal using bootstrap and when sending it I want to receive the data without closing the modal I open the modal like this: <a data-toggle="modal"…
-
4
votes1
answer197
viewsQ: How to add unpaid installments with SQL?
I have 3 tables faturas, parcelas and pagamentos. Now I need to mount an SQL to count the installments that are not paid. I have tried a SUM(CASE but it didn’t work out. Table structure faturas:…
-
2
votes2
answers290
viewsQ: Secure Login with Remember
I need help with a login script. The problem is that the session is automatically expiring after a certain downtime. I would like to increase the native limit of session of my pages, because the…
-
4
votes3
answers907
viewsA: Sum array in javascript currency
Guys, the tips really helped me out. I was able to solve by removing the punctuation of the string and using the parseFloat inside the code itself so as not to have a huge code. var quant =…
-
5
votes3
answers907
viewsQ: Sum array in javascript currency
I need help to convert and add formatted currency fields coming in this format "1.568,78" I have a code that sums an array of parcels and checks if it is equal to the total value of the invoice that…
-
1
votes2
answers879
viewsA: Avoid more than one register in the database
If your function code exite_ja_registered() is in another file, you need to include it in Register.php the same way you did mysql-Connector.php To hide the button you can make a call in jquery to…
-
4
votes2
answers409
viewsQ: Convert date format
People, I need to convert the data format of my form fields to save in my database. As the data is coming from the form by array I am not able to capture them and convert before recording. The date…
phpasked Marcos A. Silva 421 -
2
votes1
answer400
viewsQ: Add records with type
I have 2 tables linked by id and need to add a field in table 2 grouping through a field in table 1 -----TABELA 1----- ID_tab1 - tipo_pgto -----TABELA 2----- ID_tab2 - ID_tab1 - valor_pago I want…