I am using PHPExcel to read an excel template, populate the data, and ask the user to download the file. generate_excel.php When I open generate_excel.php directly from the browser, the result file is downloaded. But if I make an ajax call to the generate_excel.php, I don’t get the download prompt. Using chrome developer tools, I can see from the Network
Tag: ajax
Add radio button selection to database via ajax?
When I test my form it adds data successfully to my database table but the radio button selection is always “Ungrouped” which is the first radio button in the group. I tried giving them separate id’s, but in my ajax.js file my function uses this: Which means that now I am calling an id that doesnt exist (I think thats
loading a view after an ajax call, CodeIgniter
I have an ajax call from javascript to a method in a controller, the method in the controller should be loading a view(like, show a new page on the screen), Although everything seems ok, the new view doesn’t seem to load on the screen. I cannot use header or windows.location because, i am passing an array variable, containing data to
Creating a table with mysql, php and ajax (with jquery)
For my new project i want the so modern approach of not needing to reload a page on every database request. 🙂 I want the script to query the database and create a table with the query information. I have tried different scripts i have found on the internet. The one below was closest to my needs. index.php getdata.php But
How to save an HTML5 Canvas as an image on a server?
I’m working on a generative art project where I would like to allow users to save the resulting images from an algorithm. The general idea is: Create an image on an HTML5 Canvas using a generative …
Send the download link of the uploaded file in a mail
I am using the “jquery file upload plugin” in my website. The plugin give me a feature to download the file after uploaded it, and here’s the code
Simulating a command shell output in a web browser
BACKGROUND: Right now, in our company we have a PHP based app to automate our report building. It works like this: A webpage with a form generates a ini file with some configurations that is saved localy a PHP CLI script accepts the ini file generated on step 1 and based on it, creates a directory with documents whose data
Create an XML file in server using SimpleXML and jQuery Ajax
What I want to do surely can be accomplished but I’m doing something wrong: I want to create an XML file when I use an Ajax call. I got the following code (synthesized). Maybe this example doesn’t work, it’s just to exemplify: HTML PHP in server In this example the PHP code works as is, the other one not. But
Symfony 2 dynamically change form based on a selected value
I have the following table: EventType can have a few values i.e check-in, checkout, room rent, misc, etc. I want to make a form that will change the field type of “Value” to text, date, or entity based on the selected type in “EventType”. I tried to find some solutions but didn’t succeed. The only thing I found is that
Jquery ajax get request
I am new to jquery and php, I have two input fields, zip and city, the city shall output a value based from the zip that the user input. The jquery script shall call a URL: http://domain.com/city?zip.php=”zip; so that zip.php will return an echo value that will output to the city input field. I tried using ajax getXMLHTTP. some times