Questions tagged as 'php'

2
answers

Bring an id from another sql table

I am working with php and I need to point to the id of a detail table, the problem is that I show information from the main table but my button must point to the table information here my problem: The id of the main table is 168 but...
asked by 20.04.2018 / 21:25
1
answer

Show all the images of a directory on my website

I have a solution in .Net which has a page that shows my images, I would like it to show all the images of a directory (folder), since there are so many I would not like to spend a lifetime referencing with an img src="" to each one of them I wo...
asked by 21.04.2018 / 17:12
1
answer

Export document to excel with PHP

Is it possible to export a table from a site to an excel document? But with the new format, I've seen codes similar to this: <?php header('Content-type: application/vnd.ms-excel'); header("Content-Disposition: attachment; filename=Infor...
asked by 24.04.2018 / 21:22
1
answer

Problem using $ this- Error: Using $ this when not in object- Yii2

I am currently using the framework yii2 , this one has a code generator called gii. When using the gii to generate the model, view and controller there is no problem, I create the 3 without problem, the real problem is when I want to see the re...
asked by 25.04.2018 / 12:19
1
answer

MVC: a controller and view by form?

from my index.php I call different options using mvc. For example customers: list the clients with listclient.php. But there I have edit and new client. The question is: I have to create a clientcontroller.php and a viewaggregate.php and v...
asked by 01.05.2018 / 08:29
1
answer

Pass variable from JS to PHP [duplicated]

How could the value of a variable in JS pass to php? I need to do an echo $ location; in php since it's easier for me than doing it with js I've tried something like that but it does not work. $localizacion = "<script> document.w...
asked by 02.05.2018 / 10:51
1
answer

Error downloading a file from my server with codeigniter

I am working on a project in codeigniter 3 , the problem I have is when downloading the file, when uploading the file to the server, I keep the path and the database in the database. name generated by the function do_upload of codeignit...
asked by 30.04.2018 / 22:13
1
answer

How to pass a data from Javascript to Php Laravel

What I'm trying to do is a function in javascript that sends a simple data to a laravel controller and then upload it to the database, the problem I have is that until now I could not find a way to send that data, I always get error 500. cont...
asked by 01.05.2018 / 15:25
3
answers

Pass data from JS to PHP

How can I not pass certain data from js to php: The structure of some radios buttons <input class="rad" name="1" id="106" value="0" type="radio"> <input class="rad" name="1" id="45" value="0" type="radio"> <input class="rad...
asked by 14.05.2018 / 16:56
1
answer

how to insert the value of a select into multiple columns of a table in MYSQL PHP

good day, I hope you can support me with this query, How can I insert the value of a select (combobox) php in multiple columns in a table in mysql depending on the selected data? . For example I have this form linked to nested combobox with...
asked by 14.05.2018 / 15:41