Questions tagged as 'php'

2
answers

How to show date and time in php

How do I show the date and time after the user sends a message? I created a column named 'date' of type 'DATETIME' in the database. In php I used the following code to insert the data: Inserir.php $sql = "INSERT INTO autoriza (...
asked by 04.05.2014 / 22:59
2
answers

Login with PHP + MYSQL + MD5

I created a login form with the following code: Login.html: <form action="login.php" method="post"> <input type="hidden" name="id" value=''> Usuário<input type="text" name="usuario" id="usuario" > Senha<input type="pass...
asked by 06.05.2014 / 23:21
1
answer

How to show the number of page views of the site with PHP?

In my database in the paginas table I have the fields pagina_1 , pagina_2 and pagina_3 representing the three pages of my site. In these fields I'll insert the page views as below. In my "page one" code, for exam...
asked by 01.05.2014 / 17:30
2
answers

How to make an empty select to pull all column results

I'm trying to make an empty select, which if not selected no option pulls all the results, using the AND in SELECT the form forces me to choose some option, how can I solve this? Here are the codes: <form action="index2.php" method="post" &...
asked by 15.05.2014 / 17:01
1
answer

Separation of fields in array

I have a string that consists of (included quotation marks): "campo","outrocampo","maisumcampo" I need to separate these fields, without the quotation marks, into an array. What I'm doing is a $string = str_replace('"', NULL, $string)...
asked by 23.05.2014 / 17:03
1
answer

How to leave the negative operator after using diff () in php

Good afternoon. I do not know if it was very clear but the following, date_diff() , the problem is what, when I convert the interval $intervalo = date_interval_format($resultado, '%a') if the result is less than 0 the number is posi...
asked by 23.12.2018 / 18:24
1
answer

Autocomplete with data coming from PHP

I'm trying to create a form to register services performed, so I came across the first problem, I'm trying to keep it as light as possible because a lot of data. I want to store the "employee", "client", "services" ... I chose to use an autocomp...
asked by 30.10.2018 / 07:13
1
answer

How to do multiple simultaneous inserts with php

I need to go through a json and get the values and insert into the bank but I think it would be a bad idea to put an insert inside a loop. I would like to know how to do multiple simultaneous inserts with php.     
asked by 17.02.2014 / 20:36
2
answers

Problem with date Laravel

My problem is with date conversion, see: echo date('Y-m-d', strtotime(Input::get('data_evento'))); echo of Input::get('data_evento') : 14/02/2014 echo of date('Y-m-d', strtotime(Input::get('data_evento')))...
asked by 14.02.2014 / 18:15
1
answer

conflict with googleapis jquery

I am importing several apis to the same site, the problem is some cease to work. For example, one api to do an autocomplete, another to make an effect in the menu and another to a feedback box. Is there any way around these conflicts? I'm callin...
asked by 12.02.2014 / 17:43