Welcome, Guest. Please login or register.
Did you miss your activation email?
May 27, 2012, 06:01:21 AM

Login with username, password and session length
Search:     Advanced search
Wollen Sie dem WebsiteBaker Team beitreten?
Nähere Informationen finden Sie unter hier und auf unserer neuen Webseite.
155555 Posts in 21715 Topics by 7737 Members
Latest Member: gx-world
* Home Help Search Login Register
Pages: [1]   Go Down
Print
Author Topic: Download Gallery - template alteration  (Read 1305 times)
peterrodger

Offline Offline

Posts: 39


« on: November 28, 2007, 11:25:11 AM »

Hi
I'm using WB 2..6.7 and have installed the Download Gallery module (download_gallery_v1 .82).  I would like to make a couple of changes to the layout of the results page but cannot find the right file to alter.  It's fairly simple - I want to change the words "Upload File" to "Upload a file" and change the position of this link from below the listed, uploaded documents to make it appear above them.  (So that it's at the top of the listed documents rather than below them, which can be a bit confusing for some of our users).
I'm sure it will be possible, but I can't seem to find where I can make these alterations.  I've looked in the Settings page, but there doesn't seem to be any reference to this link.
Cheers
Peter
Logged
doc
Guest
« Reply #1 on: November 28, 2007, 01:21:29 PM »

Hello,

check the view.php and the language files /languages/EN.php. There you should find what you are searching for.

Regards Christian
Logged
peterrodger

Offline Offline

Posts: 39


« Reply #2 on: November 28, 2007, 08:40:43 PM »

Thank you very much Christian. 

For the record I was able to edit the text in the EN.php file in the languages folder of the module and to adjust the position of the text (to the top of the content) by editing the view.php file on line 296 or thereabouts.  For what it's worth I actually repeated the "File Upload" phrase at the top and the bottom of the page, just to improve the usability of it.  This link now appears twice on the page, so that as the list of documents gets longer, there will be links within easy reach.

Download Gallery is a very good addition to WB, so far I've only thought of one improvement if anyone is listening.  Is it possible to include a "Close this window" button (or link) on the new page that opens when you select a document from the gallery?  It can be a bit confusing for users to open a new page which fills their monitor and there is no apparent way of returning to the earlier page.  I know they can use the "X" box to close the window but it's not always
Peter
Logged
DGEC

Offline Offline

Posts: 386


WWW
« Reply #3 on: November 28, 2007, 08:56:43 PM »

Peter, the new page should have 2 links on it.
"restart download" and "close this window" or something like that.
Logged
peterrodger

Offline Offline

Posts: 39


« Reply #4 on: November 28, 2007, 09:09:38 PM »

Yep, you are right, BUT... Let's say I'm opening an image previously uploaded to the site, I click on the image link which opens the download page, where exactly as you say, the 2 options appear and as soon as the image is loaded onto the page those 2 links disappear!  If you then click on the browser "Back" button they briefly re-appear, only to disappear again as the image re-appears!

Sorry if that sounds complicated, but it seems to be what happens.  The only escape is to close the window. 

I wondered if there was a way to include a "Close this window" link (or option) on the downloaded (image in the above example) page.  I guess that there probably isn't a way to do it, since the plug-in page for whatever type of file is being downloaded appears to take control of the browser page.

Just a thought!

Peter
Logged
DGEC

Offline Offline

Posts: 386


WWW
« Reply #5 on: December 07, 2007, 07:02:25 PM »

I think the reason there's no button because it's not a PAGE, it's the PICTURE itself being downloaded, as per usual browser behaviour.  Hitting "back" reloads the initial page, which then... re-sends the (picture) file again. 

It's the same thing with MP3 files - people click on the files in the download gallery and it automatically loads their default helper application for audio files and starts to play it.  Unfortunately for you (in this case), the browser's default helper application for picture files is the browser itself.

You'd be better off using an image gallery module if you're mostly displaying pictures. The download gallery is to DOWNLOAD files, not view them.  A couple of them can point to the media folder pictures you've already uploaded, to save you some time/bandwidth.

If you really want to DOWNLOAD the picture, I would think there's some way to download the picture rather than viewing it, but I'm not sure if it's possible without some trickery. As soon as the browser sees a .jpg file, it knows what to do... display it!

The easiest way would be to zip the picture first, which also lets you put in a readme with explanation, sales pitch, license, etc.

Oh, the other thing you could do, is change the download link to a popup via JS or target="_blank", so a new window opens with the picture instead of the original window displaying the picture.
« Last Edit: December 07, 2007, 07:11:19 PM by DGEC » Logged
peterrodger

Offline Offline

Posts: 39


« Reply #6 on: December 09, 2007, 12:52:20 PM »

Thanks DGEC
The idea of making target="_blank" appeals to me.  I had a quick poke around but could find where to add this.  Does anyone know which file to edit?
Peter
Logged
DGEC

Offline Offline

Posts: 386


WWW
« Reply #7 on: December 11, 2007, 04:41:43 PM »

Try going to the Download Gallery page, in the Settings tab and adding it to the File Loop field:

<tr>
  <td class="line"><img src="[FTIMAGE]" alt="" /><a href="[liNK]" target="_blank"><b>[TITLE]</b></a></td>
  <td class="line_rightalign">downloads: [DL] | type: [EXT]&nbsp;|&nbsp;size: [SIZE]</td>
</tr>
<tr>
  <td class="line_text" colspan="2">[DESCRIPTION]</td>
</tr>


Out of curiousity, why is it you are using the download gallery instead of an image gallery, anyway? They both are going to display the picture, regardless of what you do. The image gallery will give a thumbnail though, and likely save you bandwidth.
« Last Edit: December 11, 2007, 04:43:20 PM by DGEC » Logged
peterrodger

Offline Offline

Posts: 39


« Reply #8 on: December 11, 2007, 04:53:53 PM »

Thanks, I'll try adding it later this evening.  The reason I need to "download" rather than "view" is that the web site is partly a sort of campaign centre for a community who are fighting a major local industry.  The gallery will allow residents to upload and download a variety of documents, sound files, videos and images.  It's a document exchange really.
Cheers
Logged
Pages: [1]   Go Up
Print
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!