Questions tagged as 'php'

0
answers

Update within a mysql function

I have to do a process to perform an update on a given field in a table. I created a function in mysql. But within this function would need to perform an update, plus the function does not accept uptade would have any way to perform this proc...
asked by 14.06.2018 / 03:38
2
answers

How to send multiple values with inputs of the same name

The problem is as follows, I have an html table that is populated within a while in a query to DB, in that table some fields are inputs and I need to enter the data entered in this input into my DB. I was thinking of getting them in another ph...
asked by 16.11.2017 / 13:53
0
answers

Two databases with PHP PDO?

I'm trying to make a connection to two databases with PDO ta like this. Config.php <?php class config{ var $host = 'meuhost'; var $usuario = 'meuusuario'; var $senha = 'minhasenha'; var $db = 'banco1','banco2';...
asked by 15.11.2017 / 17:47
0
answers

How to open (execute) a .bat file by php?

I have a .bat file whose function is to send a .pdf file to the printer. In the same directory I have my .php file. I used the exec('imprimir.bat') function, and tried the same code from the .bat file only using system : syste...
asked by 08.06.2018 / 23:01
1
answer

PDF in Binary DOMPDF laravel

I have a problem with the laravel when mounting a PDF. It gives the output all in binary. I'm downloading the link See the code: public function relatorio($id) { $pedidos_id = Pedidos::find($id); $pedidos['ped...
asked by 07.12.2017 / 13:49
1
answer

Problem sending mail with PHPMAILER using a GMAIL account for sending [closed]

Code require("phpmailer/class.phpmailer.php"); $mail = new PHPMailer(); $mail->IsSMTP(); $mail->Charset = 'utf-8'; $mail->Host = 'smtp.gmail.com'; $mail->SMTPAuth = true; $mail->Username = '[email protected]'; $mail->Password =...
asked by 08.12.2017 / 13:01
0
answers

Complete expression

Well, I have something like this: /^perfil[\/]?([0-9]{3})?[\/]?([a-z]{4,5})?[\/]?/i You need to create a function that, when receiving the information, transform it into perfil/431/abcd/ perfil/431/abcd perfil/431/ perfil/431 perfil/ perf...
asked by 08.12.2017 / 14:22
1
answer

JSON Search for specific page data

Hello! I'm trying to pull data from an API I made in PHP to send in JSON to another website. I was able to pull the result of an entire employee table, however now I want when I click on the employees to appear the other data related to it as Ph...
asked by 03.12.2017 / 17:08
5
answers

str_split does not work well in UTF-8 containing string?

I want to iterate a string with foreach . For this, I learned that I should use the str_split function, which separates each character from the string into a array . But this operation does not work as expected when using str...
asked by 01.02.2016 / 19:50
2
answers

How to pass parameters to the direct resource controller of View with Helper url ()

I have the following route in my Laravel application (v5.5): Route::resource('tags', 'Painel\TagsController'); As official documentation , this gives me a route with action edit, verb GET and URI (/ photos / {photo} / edit). In my View I n...
asked by 21.09.2017 / 01:32