Questions tagged as 'php'

2
answers

Three points in the parameter of a function in a class, what is it?

I was inspecting a class from a phpoffice vendor called phpspreadsheet and found the following function in the Calculation.php module ... not a problem, but I would like to understand the meaning of this function, I have programmed it in php for...
asked by 02.02.2018 / 13:50
3
answers

How to know the amount of memory used by my PHP application?

I would like to know if there is any way to know how much my PHP application is consuming from memory. For example: I want to know at the end of the script how much PHP spent in the process of running a particular script. Is there a functi...
asked by 18.01.2017 / 18:32
1
answer

What is the difference between sanitize and filter in PHP?

Making a security class for PHP I noticed the existence of two similar constants, such as: FILTER_SANITIZE_NUMBER_INT and FILTER_VALIDATE_INT . The pattern follows in email , string and other validations. What is the differ...
asked by 08.07.2016 / 16:39
2
answers

How to know the array key of the 3 biggest results?

I have this array $qtd = array( 'acao' => $acao, 'aventura' => $aventura, 'comedia' => $comedia, 'drama' => $drama, 'faroeste' => $faroeste, 'ficcao' => $ficcao, 'suspense' => $suspense, 'terror' => $terror, 'romance' =...
asked by 08.11.2016 / 17:40
3
answers

Query two tables in Mysql

My situation is this: I have several tables that have some information in common, such as UNIT. In one of these tables I have all my units and I need to check if this same UNIT also exists in another table, and if there is, display the inform...
asked by 24.11.2014 / 19:11
2
answers

How to display quotation marks in echo in PHP?

I'm developing an application that uses PHP + AJAX and I came across a boring problem. AJAX only recognizes the function if it is like this: onclick="remover_musica_ftp('0','Deposito de bebida' );" I'm using PHP to "print" these values in t...
asked by 16.08.2014 / 09:46
3
answers

How to do PHP and MySQL pagination?

I want to make a pagination on my blog. I will not have 50 posts on the first page, so I want to limit the page to the last 15 posts added and then clicking the "older posts" button will show me the oldest posts. In the background I do not want...
asked by 23.07.2014 / 16:14
4
answers

Team Synchronization () PHP and JavaScript

If I generate a time() on the PC purchased in Brazil it will result in a team according to our time and such, if I repeat the process in China, USA or any other location with a local PC time() will be different. My doubts are: H...
asked by 14.04.2015 / 01:20
1
answer

Source code is displayed on screen and does not run

A code of mine gave me a problem and a few excerpts from it appeared on a blank screen when I ran: Thecodewasright,Ididnotknowwhattheproblemwas,soIwenttotestanothercodethatafewdaysagohadworkedperfectly(Ididnotmodifyitinanyway,Ididnotevenopent...
asked by 28.04.2015 / 01:58
8
answers

PHP does not send accents to Mysql bank

Good afternoon, guys! I installed the OCOMON 2.0-RC6 Help-Desk system and I'm having the following problem: PHP looks for the bank's accented words and displays them normally, this proves that the bank accepts accents and 'ç' and PHP displ...
asked by 07.08.2014 / 20:48