Questions tagged as 'php'

2
answers

Problem with an array in a loop

I have a problem with an array in a loop and I wanted to simplify this code and they gave me a hand but I can not make the array correctly interpreted. $s = [0,0,0,0,0,0,0,0]; for ($i = 0; $i < count($Datos); $i++) { $s1 += $Datos[$i]...
asked by 06.11.2018 / 17:32
0
answers

Sum of results in a MySQL procedure

I have the following procedure in a DB in MySQL: BEGIN SELECT(vista_detalle.numero,vista_detalle.id_empleado, vista_detalle.nombre, COUNT( CASE WHEN vista_detalle.tipo = 'S' AND vista_detalle.estatus = 'F'...
asked by 06.11.2018 / 17:09
1
answer

Send information from one form to another form

I am trying to send information with hidden inputs of a result that I get from my query to another form, if I see the information but by clicking on the send button in the second form, the input information does not appear, I leave my code to se...
asked by 06.11.2018 / 17:39
0
answers

Open colorbox again when choosing option

I have the following code, whose objective is that when selecting a select option, open a colorbox with information. The problem that I present is that when you close the colorbox and select the same option again, the colorbox no longer opens, u...
asked by 06.11.2018 / 19:55
0
answers

How do I create a form on the client side with my wordpress plugin?

I'm new to creating wordpress plugins. I am trying to create a plugin that creates both the client side and the admin side. a form to fill out and insert the data into a table that my plugin automatically creates. for example: this is t...
asked by 06.11.2018 / 22:39
1
answer

How to Associate a Superclave in a Model in Laravel 5.6

I need to be able to create a Model in Laravel that allows the use of Superclaves to work with a table: <?php namespace app; use Illuminate\Database\Eloquent\Model; class Dpsector extends Model { protected $table='dpalmacen'...
asked by 06.11.2018 / 21:39
1
answer

How do I pass the value of an input :: file by ajax from the view to a controller

I have a script which sends the information of the form to the controller, but when using the value of the input file I get that the value of that field is null "message": "Call to a member function store () on null " <script>...
asked by 14.11.2018 / 15:59
1
answer

problem with excel

I'm trying to read an excel in php and this is my code: require_once 'Excel/Classes/PHPExcel/IOFactory.php'; $file = "currier.xls"; $objPHPExcel = PHPExcel_IOFactory::load($file, 'Excel2007'); $objPHPExcel->getSecurity()->...
asked by 06.11.2018 / 15:01
0
answers

Make a system to restore a database using $ _Files

An independent doubt. Is it possible to make a system that restores the database of a website using $ _FILES? The one way I managed to do it was using this open source tool.          <?php /** * This file contains the Restore_Datab...
asked by 06.11.2018 / 12:57
1
answer

Fatal PHP unknown error

Well, I was working on PHP and I get a message on line 69 of the current document:    Fatal error: in C: \ xampp \ htdocs \ test \ php_test \ app \ config \ database.php on line 69 public function Connect($host, $dbname, $user, $pass)...
asked by 09.11.2018 / 04:27