Questions tagged as 'php'

1
answer

Multidimensional Array PHP

Well, I have created loops to make the inputs of matriz into html with the following code. for($I=0; $I<5;++$I){ for($J=0;$J<3;++$J){ print" Matriz A: <input class='_InpText2' type='text' name='Matriz".[$...
asked by 23.01.2017 / 14:15
1
answer

How to make a "link format" (a system that reads the content of other websites)? [closed]

I would like to integrate a facebook-like system for reading external links in my project. Type when posting a "www.un-site-qualquer.com" link on my site I would like to get a result like the picture below!     
asked by 23.01.2017 / 08:58
2
answers

How to remove mysql records for half an hour (or more) ago [closed]

I need to remove mysql records that have been made half a hour (or more) ago. That is, leave only the records of the last 30 minutes. This every time a certain php script runs. How do I?     
asked by 30.01.2017 / 02:37
1
answer

Rollback method does not work in mysqli extended class

Hello, Because of the PHP version on the server, the fetch all and mysqli begin_transaction methods do not work. To solve this, I created another connection class by extending the MySQLi class and instantiating it. <?php namespace App\DB;...
asked by 17.01.2017 / 19:05
2
answers

Attachment submission with PHPMailer

I'm using PHPMailer to send attachments via contact form. Form front end: <form action="mail.php" method="POST" enctype="multipart/form-data"> <input type="hidden" name="tipo" value="trabalhe-conosco"> <input class="input_1...
asked by 16.08.2017 / 22:51
2
answers

Avoid error retrieving Json field

Well I need to make a handling of an error while retrieving a field from a json. I have the following Json: { "Autenticacao": { "login": "123", "senha": "123" } } I'm recovering the data like this: // Decodifica...
asked by 14.08.2017 / 18:09
2
answers

How do I create a page that displays data registered in a bank? [closed]

I have a system with a registration page, I would like another page that shows all the registrations that have already been made, cute as an array. EXAMPLE:    E-MAIL ID       01 Mariana [email protected]   02 Bayonetta [email protected]...
asked by 14.08.2017 / 14:16
2
answers

Sort foreach in php

I made a page that shows the hash in several hash_algos in order to study their differences, however I would like to sort by the size of the hash and not by the name of the hash_algos, the code is this, <?php foreach (hash_algos() as $hash_...
asked by 12.10.2017 / 18:12
2
answers

Make array search using more than one word

I want to search a array and use more than one word, the problem is that I want it to only return something if all words in array exist and not just one, I'm doing the following form but it is not working: <?php if(isset($_P...
asked by 26.09.2016 / 18:56
2
answers

How to relate two records elegantly?

At some point in my application I'm creating a post and relating it to the session user: public function adicionar(CadEditPost $request) { $request->merge(['user_id' => Auth::user()->id]); if(Post::create($request->...
asked by 17.12.2016 / 20:14