Questions tagged as 'php'

1
answer

How do you get points of interest between two moments in time?

Consider that there are two moments in time, represented in the standard format (HH: mm: ss). And consider that a point of interest is any time that is represented by at most two different digits (eg: 12:12:11 or 15:15:51) If I wanted to g...
asked by 05.11.2015 / 12:58
1
answer

Create an associative array from another array with foreach?

I'm trying to create a array() from other arrays using foreach . I have 3 arrays, and these arrays have values that repeat themselves and I want to create only 1 array with the values I need based on these arrays. I need to creat...
asked by 25.10.2015 / 08:52
1
answer

Sending an object through Session

I have the following object $compra = new Compra($usuario, $produto_comprado, $cep['cep'], $soma_produtos); When I try to add it to a $_SESSION[] and try to get it on another page, it returns me it returns __PHP_Incomplete_Class...
asked by 14.11.2015 / 21:32
1
answer

How to return all data from a SQL query out of function?

I have a function that aims to show all the results of an SQL query to the database and need to mount a view with the data of that query. The function is as follows: function buscar_banner(){ global $pdo; $sql = "SELE...
asked by 16.11.2015 / 10:58
1
answer

Check connection closed

How can I check if a connection has actually been closed? $con = new Conexao(); $con->abrirConexao(); ... $con->fecharConexao(); I use a variable to instantiate the Conexao class that is in another file. I would...
asked by 19.11.2015 / 04:29
1
answer

Maintenance environment for ecomerce - PrestaShop

I've taken a service to support e-commerce on the PrestaShop platform. I found the environment configured this way: The main application files are on bitbucket. To do maintenance, I change the files via git and do the deploy of th...
asked by 13.03.2017 / 17:25
1
answer

How to send a file larger than 10MB without having access to php.ini?

It is as follows: My free file hosting gives me access to see php.ini file information, but I can not modify it, I already tried to create a php.ini in the htdocs folder but it did not work, I tried to add it to the .htaccess and d...
asked by 22.02.2017 / 20:42
1
answer

How to connect a script made in PHP LDAP with Windows AD using SSL connection?

I have the PHP code in LDAP to change password in Active Directory: <?php $usuario="xxx"; $senha_atual="0000"; $senha_nova="11111"; $pessoas="casa.cafe.br"; $servidor="1.1.1.1"; $porta=389; $portas=636; $base="CN=$usuario,CN=Users,DC=casa,...
asked by 05.05.2017 / 18:44
1
answer

Upload Video by PHP (only one part)

I have some .MP4 files When I want to display them, I create a html video tav and point to this mp4. Sometimes I would like to broadcast only part of the video. Ex: The video has 10min. But I want to display in the player only the 9th m...
asked by 02.05.2017 / 06:02
4
answers

function_exists fatal error

Hello, I need help solving this problem. I have the following code snippet (I put the line number to facilitate): **186** if ( function_exists( self::$function_val() ) === TRUE ){ **187** call_user_func( self::$function_val() ); **188**...
asked by 03.04.2017 / 16:01