Welcome, Guest. Please login or register.
August 20, 2008, 05:03:38 PM

Login with username, password and session length
Search:     Advanced search
Please check out the Documentation available and use the advanced forum search, before posting in the forum - thanks.
Bitte lies zuerst die Dokumentation und benutze die Advanced Forensuche, bevor Du einen neuen Beitrag erstellst - danke.
Bekijk alstublieft eerst de Documentatie en gebruik de Advanced Forum Zoekfunctie, voor dat u een post maakt in het forum - Hartelijk dank.
60555 Posts in 9791 Topics by 5824 Members
Latest Member: blubb
* Home Help Search Login Register
+  Website Baker Community Forum
|-+  English
| |-+  Modules
| | |-+  DirList Module
Pages: [1] 2 3 Go Down Print
Author Topic: DirList Module  (Read 6070 times)
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« on: October 07, 2007, 06:16:37 PM »

I have wrote a small module. Purpose of DirList is to show automatic all files in the assigned MEDIA folder as downloadable links and additional information about filesize and time last modified.

For Download v0.13 please look at this Post

Thank You!
Ralf
« Last Edit: October 14, 2007, 12:50:24 PM by Ralf (Berlin) » Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
mhaefliger
First-Time Baker
*
Offline Offline

Posts: 1


Email
« Reply #1 on: October 09, 2007, 10:21:02 PM »

Hi Ralf
I tried it out. Great work. Works nice. One suggest / extension:
on website fronted,  click on row headers (Filename, Modified), so it would change the sort (sortierung). For example "Modified" --> Date, "Filename" --> alphabetical.
best regards
martin


Logged
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« Reply #2 on: October 10, 2007, 05:20:30 AM »

Hi Martin,

thank you for the feedback.

Quote
on website fronted,  click on row headers (Filename, Modified), so it would change the sort (sortierung). For example "Modified" --> Date, "Filename" --> alphabetical.

that's a very good idea, I will implement it as soon as possible.

best regards
Ralf
Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« Reply #3 on: October 13, 2007, 07:33:03 AM »

Hello,

I have added some additional functions to DirList v0.11:

  • in backend you may preselect the sorting of DirList by filename, filesize or date ascending or descending
  • first click on table header in frontend will sort the selected row ascending, next click will sort descending
  • DirList uses mimetypes and display a icon for each file

Automated upgrade from v0.10 to v0.11 should work proper, so it is not neccessary to uninstall v0.10.

For Download v0.13 please look at this post

Please try it out and report any problems and suggestions to me, thank you!

Ralf
« Last Edit: October 14, 2007, 12:51:52 PM by Ralf (Berlin) » Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
doc
Leaders Team
A Baker's Baker
*****
Offline Offline

Posts: 2277

Never mind!!!


« Reply #4 on: October 13, 2007, 08:58:22 AM »

Hello Ralf,

just tested the new version. Works fine if the module is not invoked two times from one single page (sections). I had the same problem with my Zitate module  smiley.
Currently the following error message appears if I add two versions of dirlist to one page via sections:
Code:
Fatal error: Cannot redeclare cmp() (previously declared in E:\09-Webserver\xampp\htdocs\webserver\wb267_blank\modules\dirlist\class.dirlist.php:476) in E:\09-Webserver\xampp\htdocs\webserver\wb267_blank\modules\dirlist\class.dirlist.php on line 476

Personally I do not like the buttons to switch the sort list in the frontend. I would prefer the column name as link maybe with a up/down icon to indicate that users can click on the column entry.

Very nice that you check the page language setting to display the date/time in a different way e.g. for German / English.

Think if this error is fixed, we could add the module to the Add-ons page.
Again thanks for your contribution.

Regards Christian
« Last Edit: October 13, 2007, 09:02:08 AM by doc » Logged
mlohnen
Pending Apprentice Baker
**
Offline Offline

Posts: 29


WWW Email
« Reply #5 on: October 13, 2007, 09:40:36 AM »

Hi, very nice module.. thank you!
Logged
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« Reply #6 on: October 13, 2007, 09:58:16 AM »

Hello Christian,

Oooops, this was a minor problem  grin

I've fixed the problem and added a tag to prevent multiple DirList within a single page to sort synchronous when clicking at the column header - looks nice but isn't useful  cheesy

For Download v0.13 please look at this post

Quote
Personally I do not like the buttons to switch the sort list in the frontend. I would prefer the column name as link maybe with a up/down icon to indicate that users can click on the column entry.

Perhaps it should be an option for a coming version to choose between buttons or links in the table header. Up/Down buttons seems to be a good idea...

Regards
Ralf
« Last Edit: October 14, 2007, 12:53:02 PM by Ralf (Berlin) » Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
mlohnen
Pending Apprentice Baker
**
Offline Offline

Posts: 29


WWW Email
« Reply #7 on: October 13, 2007, 10:05:31 AM »

And here is a Dutch language file for DirList v0.11 (should also work for v0.12)
Rename txt to php and put in DirList language subdirectory.
Logged
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« Reply #8 on: October 13, 2007, 10:17:37 AM »

Hello Marco,

Quote
And here is a Dutch language file for DirList v0.11 (should also work for v0.12)

Great! Thank you!

Best regards
Ralf
« Last Edit: October 13, 2007, 10:19:29 AM by Ralf (Berlin) » Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
doc
Leaders Team
A Baker's Baker
*****
Offline Offline

Posts: 2277

Never mind!!!


« Reply #9 on: October 13, 2007, 06:46:34 PM »

Hi Ralf,

adding two dir list modules on one page via section works fine now with v0.12. However, if I click on the file size button of one of the lists, the other module output is sorted as well  smiley

Another thing. You are using the $module_directory variable defined in info.php. On some server configuration, those modules will not work. It is recommended to use the hardcoded string of the module directory instead of $module_directory (not nice but this way the module will run independend on the server configuration). See hello world module for details.

Regards Christian
« Last Edit: October 13, 2007, 06:52:50 PM by doc » Logged
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« Reply #10 on: October 13, 2007, 11:15:12 PM »

Hello Christian,

Quote
adding two dir list modules on one page via section works fine now with v0.12. However, if I click on the file size button of one of the lists, the other module output is sorted as well

Hmmm, I can't reproduce this error, tried installations at different servers. I had added the tag {section} to v0.12  to prevent DirList exactly from this behaviour. Have you upgraded from v0.11 to v0.12? Please check template file frontend.htt in /dirlist/htt :

Code:
      <th class="th_file">
          <form name="btn_file_{section}" action="{form_action}" method="post">
          <input type="hidden" name="sort{section}" value="{file_sort}">
            <input type="submit" value="{file_btn_text}">
          </form>
        </th>

are there also the {section} placeholders in your file?

Quote
It is recommended to use the hardcoded string of the module directory instead of $module_directory (not nice but this way the module will run independend on the server configuration). See hello world module for details.

 huh ... not nice, but okay, I will change it.

Regards
Ralf
Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« Reply #11 on: October 13, 2007, 11:41:22 PM »

Hello Christian,

I think I have detected the problem. Sometimes it's the first click at row header which will start a sorting of all DirLists at the page.

Have to sleep about it, at the moment there is no solution...

Regards
Ralf
Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« Reply #12 on: October 14, 2007, 06:43:58 AM »

Hello Christian,

there is no error rsp. bug in DirList, while sorting the lists in frontend.

Please check the following example to understand the behaviour of DirList:

  • Load a page with two or more DirLists inside (please flush browser cache before)
  • In the Second DirList try to change sorting in any way you want. You will see that the First DirList will not change sorting in any way.
  • At last change the sorting of the Second DirList in a manner which is not the default sorting for this DirList.
  • I you now click at any Column Header of the First DirList the Second DirList will change too.
  • any further change in the First DirList will not cause any change in the Second DirList

What happens? At the moment you change the focus from the Second DirList to the First DirList the Second DirList will fall back to the default sorting order. This behaviour is absolutly correct because all changes in the frontend are temporary and not saved in any way.

Regards
Ralf
Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
doc
Leaders Team
A Baker's Baker
*****
Offline Offline

Posts: 2277

Never mind!!!


« Reply #13 on: October 14, 2007, 08:53:50 AM »

Hello Ralf,

thanks for the information. Just looks funny if you change the sort order (date/time) of the first list and afterwards for the second list (date/time) the first list will change too  smiley

Best regards
Christian
Logged
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« Reply #14 on: October 14, 2007, 09:10:49 AM »

Hello Christian,

yes, it looks funny  smiley

Changing this behaviour will be very elaborate and therefore I think at the time it's ok for this small modul.

I have attached dirlist_0.13.zip with changed $module_directory to hardcoded module path and NL.php inside for Add-on page.

Regards
Ralf

Please download the latest version from the Addons Repository
« Last Edit: October 20, 2007, 04:59:03 PM by Ralf (Berlin) » Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
doc
Leaders Team
A Baker's Baker
*****
Offline Offline

Posts: 2277

Never mind!!!


« Reply #15 on: October 14, 2007, 09:16:53 AM »

Hi Ralf,

just tested it, works as expected. Think we should wait for another few days so forum members can provide some feedback before publishing it on the Add-ons repository. Can you please remove the old Zipfiles in this thread to prevent a mix-up of different versions?

Thanks for this nice module.
Regards Christian
Logged
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« Reply #16 on: October 18, 2007, 06:47:53 PM »

DirList v0.14 - 18.10.2007

  • fixed: HTML/XML - some markup language errors prevented DirList from passing W3C Markup Language Validation
  • note: Bug in WB 2.6.7 impede modules from passing W3C Validation, please check Ticket #521 for further informations and fix-up


Please download the latest version from the Addons Repository

Thank you!
Ralf
« Last Edit: October 20, 2007, 04:59:55 PM by Ralf (Berlin) » Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
doc
Leaders Team
A Baker's Baker
*****
Offline Offline

Posts: 2277

Never mind!!!


« Reply #17 on: October 20, 2007, 04:15:33 PM »

Hello Ralf,

added your latest DirList version to the section Page Type modules on the Add-ons repository. Please delete the version attached here in the forum to avoid a mixup of files.

Thanks for the nice contribution.
Regards Christian
Logged
Ralf (Berlin)
Addons Team
Master Baker
******
Offline Offline

Posts: 275


Don't panic...


WWW
« Reply #18 on: October 20, 2007, 05:01:56 PM »

Hello Christian,

thank you for your service.

Regards
Ralf
Logged

panke.info - Das Informationsportal rund um die Panke von Bernau bis Berlin...
pkoskela
Pending Apprentice Baker
**
Offline Offline

Posts: 6


« Reply #19 on: October 21, 2007, 10:51:01 AM »

Dirlist shows .htaccess file in list. How can I hide it?

Danke schön, Module für Website Baker CMS ist gut!

Logged
Pages: [1] 2 3 Go Up Print 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.5 | SMF © 2006-2008, Simple Machines LLC Valid XHTML 1.0! Valid CSS!