Questions tagged as 'php'

2
answers

Insert record in bank by clicking div x

How can I insert a record into the database when I click on a div x I tried to use ajax but could not do the function I have the function $status = "on"; db::Query("UPDATE bdc SET status='$status'"); I wanted to insert this function b...
asked by 03.11.2015 / 17:56
1
answer

Problem getting access time

I'm trying to catch the time that the surfer remained on the page, however nothing is returned. Main php file: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&g...
asked by 25.12.2016 / 22:31
1
answer

How to save form data only if it comes from a particular site?

Hello, I have a form that is being used in another site and saving in my database, through a php action that is on my server. But I would just like to save the data if the form comes from the domain of this site. How can I do it?     
asked by 16.12.2016 / 20:29
1
answer

Get all the INNER JOIN data

My problem is that I'm making a query but I'm not able to list all the data in the table. SELECT * FROM suporte s INNER JOIN login l ON l.cliente_id = s.cliente_id INNER JOIN radius_acct r ON r.USERNAME = l.user WHERE s.CLOSEDATA = '0000-00-00...
asked by 24.12.2016 / 19:14
1
answer

Fill in PHP session via ajax

I'm having trouble solving a problem. I have a PHP application that needs to fill in some sessions I'm using this method to send. <script src="localhost:8080/painel_cop_mdu/js/jquery-3.1.1.min.js" type="text/javascript"></script...
asked by 15.12.2016 / 16:05
0
answers

How to make a form with the number of variable fields and insert this data in the database? [closed]

Hello. I want to create a CRUD that manages words and their synonyms. A word has multiple synonyms (1: N). I would like a solution to dynamically include the inputs, according to the demand of each user. For example, a word to be registere...
asked by 02.10.2015 / 19:20
6
answers

How to turn string into time in PHP?

I have 2 strings that represent times. How to calculate the difference between the two. $string1 = "12:04:32"; $string2 = "18:07:34";     
asked by 14.10.2015 / 20:50
2
answers

Identify differences between two similar projects

I have two projects in PHP: one is a store in Rio, and another is the store in São Paulo. Basically, SP is in the root, and Rio is "almost" a clone of the SP project. Each project is presented one way, the river is being loaded into a river su...
asked by 11.08.2016 / 21:33
0
answers

good practices in building a CRUD [closed]

ConnectionBanco.class.php class conexaoBanco{ private $host="asd"; private $login="a131"; private $senha="123123"; private $banco="asdasdasd"; private $conn; public function dbConexao(){ $this->conn = new PD...
asked by 08.10.2015 / 17:27
1
answer

CRUD - send selected line id to toolbar - CakePHP

I am beating myself for a while with the following problem: I set up a CRUD in CakePHP, I made the grid with css to be cool and ready. The problem is that it's nothing neat to have a stock column and the "View," "Add," "Promote," and "Decline...
asked by 23.09.2015 / 21:58