Questions tagged as 'php'

2
answers

Send a variable from PHP to HTML?

I have a problem. I need to send a variable of a file in PHP on my site1, to an html file on my site2. this is the code that I have so far PHP site1 = header ('Location: https://www.sitio2.xyz/ads/ad1/ad'.$variable.'.html'); this...
asked by 05.09.2018 / 14:21
2
answers

Help with Routes in Laravel 5.6

I've been working on a web application through Laravel in Windows (using Laragon ). I am new to using this framework and I have found an inconvenience: When I use Routes as for example: Route::get('/', 'PagesController@home'); It'...
asked by 23.08.2018 / 12:59
4
answers

Concatenate two conditions in an if

I am developing a small script for woocommerce, where according to the geolocation and product category, show or hide the price. In this case I managed to make it work by means of geolocation to hide the price, but this is very generic becaus...
asked by 09.01.2018 / 13:11
3
answers

Undefined offset when passing data from a checkbox

When executing this code, it indicates Undefined offset. Doing a dump of variables, I discovered that the problem is in a checkbox $informarUP[$fila] , that if it is selected it does not give the error and if it is not selected, it gives t...
asked by 01.12.2018 / 00:56
2
answers

PHP: Take value of an arrangement inside a while and send it to another page

I have a problem. I need help to traverse a while and take the value of an array that is full of data from a database. I need to take some value and send the data of that arrangement to another page. I leave my code here: <?php while($ro...
asked by 01.08.2018 / 18:17
2
answers

Take a row of Mysql with PHP without while

Hi, if you could help me, I'm trying to take a row from a Mysql table, I do not need to go through the table I just want to take a single row. $consulta_precio_seco="SELECT * FROM secos WHERE codigo=10" ; $resultados_precio_seco=mysqli_query($...
asked by 22.07.2018 / 20:35
2
answers

Create CSV automatically in PHP

I have a function that creates a .csv file with data from the database and I wanted it to be generated automatically and saved in a project folder. The thing is that I can not find anywhere how it is generated automatically, the function works c...
asked by 25.07.2018 / 17:27
3
answers

Help with the validation of a login with user privileges [closed]

I want to login with user privileges, I have a database called login , with a table accounts with the user fields, password and type_count . In the forms to log in I only have 2 inputs: user and password . When creating the accounts I...
asked by 22.03.2018 / 16:23
3
answers

Store in a variable a data of the option marked in a select to then show it dynamically

I have a select where I complete the options with the data of the products that I have stored in my bbdd. The code is as follows: <select name="p1" id="select1" required /> <option selected="true" disabled="disabled">Elige...
asked by 25.03.2018 / 15:23
2
answers

Identify Click of Inputs dynamically created by means of a query

I am trying to generate a code for certain dynamic queries, the specific case is the following, I have my users.php page, which will have registered users in a system, for this a search of users is done in a way dynamic and I put them in a div a...
asked by 27.03.2018 / 18:41