Jump to content

Downloader


Asheeown

Recommended Posts

Okay, User logs in, and goes to the log page. He or she defines a date with drop down menus to define what logs they want between one date and the next and it returns their results.  That part is done, however I can't write temp result files for every time the search, so how can I incorporate a choice to download what they have just searched.
Link to comment
Share on other sites

Well that is a good idea, just the database is very large and only getting bigger.  So we need to keep queries down to a minimum.  Would it be possible to have them click a link with the search filters in the URL and it open a new window and then it makes the temp file redirects to the file and then closes the pop up?
Link to comment
Share on other sites

For open/close the window you can use javascript, but there has to be some form of action for that to happen.

I am not 100% sure how your querie's, are saved.  If they are saved through a get query, they can just bookmark the page.
If you are wanting to allow them to generate a download temporarily, then delete it, You would have to somehow, unlink the file after they have downloaded it, by them giving some kind of signal, it was downloaded.  Or you could email them the file.

Create it, email it to them, and never save it anywhere.
Link to comment
Share on other sites

I still don't understand.

They are running searches from a database?
See generally to show a file, you just create the file, save it somewhere, present a download link.  Optionally you can delete it later, or when they are done, if you can.

[quote]Well the question was really how should I propose the download option? and really how should I go about creating a new file which the file name will already be provided[/quote]
The download option, can only really be offered as a direct link.  I guess you could start an auto-download when they do the search, but I really don'tt hink there is anything youc an do to start a download automatically, without them clicking on something, or something similar

As far as how to go about it, there is only 1 way.  Create the file.

you can create it, and save it, or create it, and maybe there is a way to offer it directly, but I think it has to be saved, before it can be offered for download.
Link to comment
Share on other sites

[quote author=businessman332211 link=topic=124760.msg517420#msg517420 date=1170190843]
[quote]i think what you may want to do is look into RSS feeds. converting the output of the search query into an XML format (temporarily) and then prompt the user to download the file.[/quote]
Actually that was a very good idea, and very valid point.
[/quote]
thanks businessman  ;D i try.
Link to comment
Share on other sites

Well what I mean is, I know how I will get them to the file but I can't create the file on the same page as the query.  Although if I were to use a pop-up I could transfer the query filters and do it there, however when the file creation is done, and the redirect script goes to the file url, how would the pop up know to close
Link to comment
Share on other sites

well, what i mean is, on the results page for your queries, have a small link or logo that says something like 'Convert to RSS'. the idea is, when the user clicks it, it will run the function that will convert the outputted HTML results into an RSS format, store it temporarily, and then javascript to popup a small window prompting the user to press 'OK' to download the RSS feed. then boom! you're done. the page doesn't even have to reload.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.