Questions tagged as 'php'

1
answer

How to execute only one if without entering the other in PHP

I have two if parallels and I need to get into one OR on another, not both. However, since I was within while with the first if , I could not put just else , having to make another if out of while . So ever...
asked by 13.11.2014 / 23:53
1
answer

How can I detect and warn that a certain user is sending many messages in a row?

In a chat room, how can I detect and warn that a certain system user is sending lots of messages in a row?     
asked by 17.12.2013 / 05:48
2
answers

Import events into calendar JSON format

I want to import events from a non-private, server-side Google Calendar (PHP) into JSON format. Since I just want to receive information and do not need to edit / create events I assume there is a way that does not need authentication. I k...
asked by 04.02.2014 / 00:13
3
answers

What is a Resource type in PHP? What is it for?

I'm new to the PHP language, studying it, I came across a special type available through the language, type resource . I found a definition for it:    Resource       A resource is a special variable, which maintains a reference to a...
asked by 05.10.2015 / 19:08
2
answers

Laravel database connection error

Use mamp and set up the database.php file so 'mysql' => [ 'driver' => 'mysql', 'host' => env('DB_HOST', 'localhost:8889'), 'database' => env('DB_DATABASE', 'estoque_laravel'), 'username' =&...
asked by 13.11.2015 / 17:52
3
answers

How to put line break in a textarea?

When I change or include some data from a textearea I wanted it to save the line breaks. And also, when I show a textarea before the data that already exists I wanted it to show the line breaks. Then I put the two textarea...
asked by 29.09.2015 / 15:30
2
answers

How to invert values that are separated by commas in mysql

Photo from my base: Thedatalookslikethis:-46.63642120299626,-23.54854965191239,0Ineedtoselecttobeinverted:Ex:-23.54854965191239,0,-46.63642120299626Myselectioninphp:<?php$query=mysql_query("SELECT * FROM tabela")or die(mysql_error()); whi...
asked by 28.09.2015 / 17:35
1
answer

Using multiple namespaces weighs more?

Let's say I have these namespaces : use DataTables\Editor, DataTables\Editor\Field; DataTables\Editor\Format, DataTables\Editor\Mjoin, DataTables\Editor\Options, DataTables\Editor\Upload, DataTables\Editor\Validate...
asked by 17.08.2017 / 17:11
2
answers

How to display information from a JSON file in the browser in a friendly way?

The application receives a JSON file, already validated, and should display it to the user who is a programmer. I would like to display the JSON as in this validation site and beautify JSON . So I wanted this JSON: {"glossary": {...
asked by 19.07.2017 / 17:35
2
answers

Upload problem in PHP

In an input of the type file, the tmp file is not being generated. This is the array generated by PHP Array ( [name] => desin3.jpg [type] => image/jpeg [tmp_name] => C:\xampp\tmp\phpE0D5.tmp [error] => 0 [size] => 30420 )...
asked by 06.04.2014 / 20:09