Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: How to implement downloading files with h5b


This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 3 - Last Post: Jun 25, 2014 7:18 AM Last Post By: Eduardo Nunes
Vladimir frolov

Posts: 9
Registered: 8/24/12
How to implement downloading files with h5b  
Click to report abuse...   Click to reply to this thread Reply
  Posted: May 16, 2014 11:51 PM
Dear Colleagues,
Please suggest how to implement downloading files with users of my site using h5b.
--
Vladimir Frolov

Edited by: Vladimir frolov on May 16, 2014 11:52 PM
Thomas Feichten...

Posts: 4
Registered: 1/20/10
Re: How to implement downloading files with h5b  
Click to report abuse...   Click to reply to this thread Reply
  Posted: May 20, 2014 6:51 AM   in response to: Vladimir frolov in response to: Vladimir frolov
Hello Vladimir,

I'm not quite familiar with H5B (I like the tool very much, but have too less time to increase my knowledge).
But for download I would add the URL of the file to download to the property link of a Label.
I'm pretty sure there are a lot of other/better ways but I guess this might work also...

Regards, Tom

Vladimir frolov wrote:
Dear Colleagues,
Please suggest how to implement downloading files with users of my site using h5b.
--
Vladimir Frolov

Edited by: Vladimir frolov on May 16, 2014 11:52 PM
Rolf Fankhauser

Posts: 22
Registered: 9/3/01
Re: How to implement downloading files with h5b  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 1, 2014 7:43 AM   in response to: Vladimir frolov in response to: Vladimir frolov
Hello Vladimir

I tried Tom's suggestion with the link property of a label. Text and png files are directly shown but with pdf you can choose to open or download. I guess that this behaviour also depends on the browser. There is a component for upload but I couldn't find an explicit component for download.

Rolf

Vladimir frolov wrote:
Dear Colleagues,
Please suggest how to implement downloading files with users of my site using h5b.
--
Vladimir Frolov

Edited by: Vladimir frolov on May 16, 2014 11:52 PM
Eduardo Nunes

Posts: 4
Registered: 5/1/07
Re: How to implement downloading files with h5b  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 25, 2014 7:18 AM   in response to: Vladimir frolov in response to: Vladimir frolov
Hi,

This works fine,

function btnAbrirJSClick($sender, $params)
{
?>
//begin js

var file = findObj('Edit1').value;
file = './docs/notificacao/' + file;
window.open(file, "window22", "height=800,width=1024,toolbar=yes,scrollbars=yes,resizable=1");

return false;

//end
<?php
}

// some comments
// it opens jpeg, pdf, word, excel, etc...

// drop a button on the form
// on jsclick put the code above
// Edit1 is an hidden edit that contain the name of file that i want to open.
// './docs/notificacao/' is a folder that stays in apache and contain files that i want to open

Enjoy and share


Vladimir frolov wrote:
Dear Colleagues,
Please suggest how to implement downloading files with users of my site using h5b.
--
Vladimir Frolov

Edited by: Vladimir frolov on May 16, 2014 11:52 PM
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02