Questions tagged as 'php'

1
answer

How to change the colors of the columns of my graphics in High Charts

I have the following code, which is double Y axis ... but what I'm looking for is that when the columns are greater than 100, I change color, but I do not know how to introduce a color to a bar , since in the code of highcharts the color is the...
asked by 19.10.2018 / 19:53
1
answer

how to send the value of a for from one php to another

I would like to know how I could send the value of $ sumatotal from this php to another $Sumatotal=0; for($sum=0; $sum<12; $sum++){ $Sumatotal+=$sumames[$sum]; echo '<td>' . $sumames[$sum].'</td>'; } echo '<td>' .$...
asked by 11.10.2018 / 23:08
1
answer

Save to output file .txt

I have a code that reads a file and does a series of functions to it. I do not know very well how I could save the file once its modifications were made in a file.txt. Can you guide me? Here I leave my code <?php $fp = fopen("archivo.txt",...
asked by 11.10.2018 / 17:37
1
answer

There is some way to put this MySqli query together

$pro1="Tubo Estructural"; $pro2= "Protector De Corriente"; $sql= "SELECT producto, SUM(cantidad) as monto FROM grafica WHERE producto = '$pro1' "; $query= mysqli_query($conexion,$sql); $sql1= "SELECT producto, SUM(cantidad) as mo...
asked by 11.10.2018 / 16:09
1
answer

How to upload files ".zip" with php?

I use this library to upload images: piramideUploader . Upload the images without problem, the problem is when I try to upload a file ".zip". My PHP is as follows: if(isset($_FILES['uploads'])){ $piramideUploader = new PiramideUplo...
asked by 11.10.2018 / 18:45
2
answers

PHP color tables, rows and columns

How could I structure the following code adequately to achieve these results? I'm a bit lost with the PHP theme to "merge" with the html. If it is 4x4 it shows 16 numbers, the odd ones in green and the pairs in red. <html> <...
asked by 26.10.2018 / 14:17
1
answer

PHP Error Undefined offset: 2

When programming this code, the following error appears: Undefined offset: 2 . What could be the cause? function checkCourt($fecha,$pista){ //Entorno: $coincidencias;$fp;$nombre_archivo;$linea; //Algoritmo:...
asked by 27.10.2018 / 21:49
2
answers

Upload File Server PHP

I have to upload 2 images. One is a product image and another is a QR. Also the code I want to insert in a MySQL database the URL of each image. I managed to get the URL of each image registered in the database and upload one of the two images,...
asked by 28.10.2018 / 23:43
1
answer

More than two variables in .htaccess

It's the first time I have to work with .htacces to make friendly URLs. With the following code I have been able to make this URL link become link Options -MultiViews RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUE...
asked by 18.10.2018 / 17:22
1
answer

Go through an array of a query in PHP

I have the following function in PHP: function ListarDependencias() { $db = new Conexion(); $sql = $db->query("SELECT Id, Nombre FROM Dependencias;") or die (mysqli_error($db)); if($db->mysqli_num_rows($sql) > 0) { $result...
asked by 09.10.2018 / 19:24