Questions tagged as 'php'

2
answers

problem with the accents in fpdf

I have this code and when I save the pdf I get some strange letters. someone who can help me with this. <?php if(strlen($_GET['desde'])>0 and strlen($_GET['hasta'])>0){ $desde = $_GET['desde']; $hasta = $_GET['hasta']; $verDesde = d...
asked by 17.06.2017 / 23:52
2
answers

Touring multidimensional array with foreach and its index.PHP

I have this code: for($i = 1 ; $i<=$jornadas;$i++){ $local = $equipos[rand(1,($jornadas-1))]; $partido = array ("local"=>$local); $ronda[$i][] = $partido; } foreach($ronda as $a){ echo "<p>Equipo Local ".$a['local'...
asked by 17.06.2017 / 17:22
1
answer

The action of my form does not work in HTML

Currently I have a problem because I create a form and within my form tag I added an action, the problem is that it does not execute the url of my action, when I click on my submit button, it does not execute no action and my file validar.php...
asked by 21.06.2017 / 23:47
3
answers

Error increasing the value of the viable Php / sql

Good day, from a php form I am capturing the information in phpmyadmin. In the background is the realization of a purchase that when stored in the database increases the purchase number (purchase 1, 2, 3 etc.). I have reviewed the code sev...
asked by 15.06.2017 / 10:37
1
answer

Query works in PHPMyAdmin but not in the PHP script

The query: SELECT 'morel_asigntura'.'asignatura', 'morel_asignaturas_ei'.'nombre_ei', 'morel_asignaturas_ei'.'activo_ei', (CASE WHEN 'morel_asignaturas_ei'.'activo_ei' =0 THEN "0" WHEN 'morel_asignaturas_ei'.'activo_ei' =1 THEN "1" ELSE "2" E...
asked by 12.06.2017 / 15:31
1
answer

Unserialize multidemensional array in PHP

Based on this post I am trying to send a result of a form in php to another php page that is responsible for exporting this result to word. For this first I get the result correctly, and to send it to the other page I do it like this: <...
asked by 05.05.2017 / 11:38
1
answer

Why does a while loop show no existing data when used in PHP 5.3.0?

I have a while cycle to show a list of data using the following code: <?php $stmt = $conexion->prepare("SELECT desc_unix ,cos_unix FROM unidadesx"); $stmt->execute(); $resultados = $stmt->get_result(); $contador =...
asked by 02.05.2017 / 14:50
2
answers

Query in laravel with Relationships from blade?

Good I have the following tables Users Requests Servers Which are related as follows. A User has several Requests A Server has several Requests Now what I need is to obtain all the servers associated with the requests that th...
asked by 02.06.2017 / 23:50
2
answers

Update div every X seconds

I need a function to recharge one every X seconds because the value of the BBDD can change. I have the following, but I do not update the value. What fails me? div: <div id="results">valor a cargar</div> The script: functio...
asked by 30.03.2018 / 21:30
1
answer

Value in particular within an array

I have a dilemma when printing a variable, you see, this is my query in SQL: SELECT MONTH(fecha_del_deposito) AS mes, SUM(importe) as monto FROM pago_cliente And it throws the following: Which happens to query in php: 'cantidadPa...
asked by 27.03.2018 / 20:04