Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

"One Click" export to Excel?

Guest
Dec 07, 2007 Dec 07, 2007
Not sure if this is the correct forum so please excuse me if I got it wrong.

I am wondering if there is a way to download the contents of a table (mysql/php) by placing a link or button on a webpage?
Currently I am able to export the table from within phpMyAdmin as a .xls file but it is a rather circuitous process and I was wondering if there is a way to set this up to work from a link or button within a DW8 page?

Again sorry if this is not the right place to ask such a question.
thanks for any help that may be forthcoming,
Graham
TOPICS
Server side applications
576
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Deleted User
Dec 13, 2007 Dec 13, 2007
Hi folks,
Thanks for the replies, I have managed to solve this by using a php class that generates a csv file.
Appreciate the suggestions. 🙂
Translate
New Here ,
Dec 07, 2007 Dec 07, 2007
Hi Graham,

You can export the table in a csv format and then open up Excel and Import that CSV file inside excel that is about it for the solution part.

If you want an application created (PHP FILE) which will just have a button when you click that the file gets exported into excel I can do that for you (just private message me).

Let me know if it helps.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Dec 13, 2007 Dec 13, 2007
HI,

I don't know PHP, but, in VBScript, you can add the following:

<% Response.ContentType = "application/vnd.ms-excel" %>

at the top of a page, then, simply lay out a table with headers, plainly, the way the Excel columns would look...and, this will prompt you for a filename to save, and will generate an excel spreadsheet for you from the data you display in the table layout.

Hope this helps!

Juan C. Vega
Intelligentsia
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Dec 14, 2007 Dec 14, 2007
LATEST
I like the answer provided by JuanCVegaPR, But i would like to be able to create a excel file and have the name be generated by a variable like this, Report_MonthValue_for_PersonName.xls where MonthValue is the current month and PersonNAme is the name selected from a menu. I can do all of it except save the excel file, any suggestions. Using ASP at my day job.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Dec 13, 2007 Dec 13, 2007
Hi folks,
Thanks for the replies, I have managed to solve this by using a php class that generates a csv file.
Appreciate the suggestions. 🙂
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines