Tiny little hack... 0.31.1

How are you using your Bubba? Got ideas for a cool modification? Share!
bubbalibre
Posts: 117
Joined: 01 Feb 2007, 09:33
Location: Paris, France

Tiny little hack... 0.31.1

Post by bubbalibre » 21 Mar 2007, 22:42

Hi folks,

I've got something for you...

You may find this new interface a little rough, but since I don't have much time I just tried to build something that works. The frame is still the same, not the design.


What's new:
  • * the percentage displayed on the homepage (fully css compliant)
    * the favicon (different from the one used for the forum)
    * the navigation menu shows the current page
    * 'add from folder' hack
    * an ajax loader image while waiting the downloader
    * a cleaner code
    * the design is easier to modify and extend
Add from folder?
This hack lets you add downloads by putting your .torrent files into... a folder. It's using an apache's ability. You'll need to:
  • * modify the file /etc/apache2/mods-available/userdir.conf as follow:

    Code: Select all

    <IfModule mod_userdir.c>
    	UserDir www
    	UserDir disabled root
    
    <Directory /home/*/www/>
    		AllowOverride FileInfo AuthConfig Limit
    		Options -Indexes SymLinksIfOwnerMatch IncludesNoExec
    		Order deny,allow
    		Deny from all
    		Allow from 192.168.0.0/255.255.255.0
    	</Directory>
    </IfModule>
    * restart apache:

    Code: Select all

    apache2ctl restart
    * create a 'www' folder into your home directory, then a 'torrents' sub-folder.
What if I don't modify the apache configuration file
As long as you don't create a 'www/torrents' folder into your home directory, the button 'add from folder' won't be displayed. And even if, it just won't be able to download the torrent file, without any fuss.


Download the archive: Remember : always make a backup before you try anything.

Forgive my English, but it has been a long day...
Tell me what you think.
Last edited by bubbalibre on 25 Mar 2007, 19:09, edited 5 times in total.

bubbalibre
Posts: 117
Joined: 01 Feb 2007, 09:33
Location: Paris, France

Post by bubbalibre » 22 Mar 2007, 19:15

Hi everyone,

I made some improvements. But first, the picture:

Image

The way the infos are displayed below each torrent have been rewritten:
  • * the percentage is displayed with a brand new image
    * the percentage is displayed only for torrents in progress
    * for the finished torrents you'll only see the size, not the download speed, for it's always 0
    * the ratio is more accurate
    * resumed torrents are displayed as finished if they indeed are, and their size is accurate
    * the speedOmeter is back
    * the layout has been slightly modified
If you want to try it, the link above has been updated. If you already have installed the previous release, here is an archive containing only the modifications: Hope you'll enjoy it,

TheEagleCD
Posts: 46
Joined: 27 Feb 2007, 16:44
Location: Austria
Contact:

Post by TheEagleCD » 23 Mar 2007, 18:42

I just installed it and I have to say you did a great job!

So far I have only encountered two issues: First of all the download page doesn't seem to display the download-speed. It just says "DL: KB/s" and the speed-summary also stays at "DL: 0 KB/s". Oddly enough that error only happens when I download via ftp or http, with torrents it seems to work just fine.

The second point are those OMG *pink* buttons... :shock: I think that the orange you're using throughout the interface would look much better as a button colour.

Thanks for that hack,
Christoph
Bubba, I'm lovin' it

lelle
Posts: 69
Joined: 02 Jan 2007, 20:25
Location: Stockholm, Sweden

Post by lelle » 23 Mar 2007, 19:58

u da man, bubbalibre :D

bubbalibre
Posts: 117
Joined: 01 Feb 2007, 09:33
Location: Paris, France

Post by bubbalibre » 23 Mar 2007, 20:19

Hi guys,
TheEagleCD wrote:the download page doesn't seem to display the download-speed. It just says "DL: KB/s" and the speed-summary also stays at "DL: 0 KB/s". Oddly enough that error only happens when I download via ftp or http, with torrents it seems to work just fine.
You're damn right, I wasn't handling these downloads.
TheEagleCD wrote:The second point are those OMG *pink* buttons... :shock: I think that the orange you're using throughout the interface would look much better as a button colour.
Right again! I didn't work much on the design (only on the layout). The buttons are now the same orange than the navigation menu.

The way the infos are displayed below each torrent have been rewritten:
  • * buttons are orange
    * http and ftp downloads are properly displayed
    * ratio wasn't correct, it should now be
The link above has been updated. And here is the archive containing only the modifications: Thanks to TheEagleCD and lelle for their support and feedback.

bubbalibre
Posts: 117
Joined: 01 Feb 2007, 09:33
Location: Paris, France

Post by bubbalibre » 24 Mar 2007, 13:00

Hi everyone,

Yet another update of my tiny little hack. The main purpose of this update is a better handling of torrent > 2 GB.

Major changes
* Torrents with 'in progress status' but fully downloaded have now '*** ' before their names
* If the size is 2 GB, the size will be displayed in bold and the download speed will be shown, even if the downloaded size is the same than the total size
Image

Minor changes
* Lighter colors
* Darker text
* Round number for ftp and http download speed
* Background image for the title using favicon.ico
* Spelling "Send and recieve" in smb.php (thanks to TheEagleCD)
* Call for another file in index.php optimized

The link above has been updated. And here is the archive containing only the modifications: Enjoy and tell me what you think.

Note for myself: this is rev#14

TheEagleCD
Posts: 46
Joined: 27 Feb 2007, 16:44
Location: Austria
Contact:

Post by TheEagleCD » 24 Mar 2007, 13:43

Thanks so much, I love that you keep improve your hack... :)

Unfortunately I'll first have to re-vive my Bubba and then I'll take a look at the latest version of your hack!

Cheers,
Christoph
Bubba, I'm lovin' it

bubbalibre
Posts: 117
Joined: 01 Feb 2007, 09:33
Location: Paris, France

Post by bubbalibre » 24 Mar 2007, 14:19

Thanks to you, Christoph.
Hope you'll soon enjoy your bubba again. Looks like your in good hands.
Cheers !

Clive
Posts: 148
Joined: 07 Mar 2007, 07:15

Post by Clive » 25 Mar 2007, 09:46

I've got this little hack loaded up and it looks great !

I especially like being able to upload Torrents from a folder which saves me having to copy them onto the web-server and make URL's out of them.

Thanks for this !

bubbalibre
Posts: 117
Joined: 01 Feb 2007, 09:33
Location: Paris, France

Post by bubbalibre » 25 Mar 2007, 10:17

Hi Clive,
Clive wrote:I've got this little hack loaded up and it looks great !

I especially like being able to upload Torrents from a folder which saves me having to copy them onto the web-server and make URL's out of them.

Thanks for this !
You're welcome. Any feedback appreciated.

Regards,

Clive
Posts: 148
Joined: 07 Mar 2007, 07:15

Post by Clive » 25 Mar 2007, 12:56

Thanks Bubbalibre, one minor issue that I found with the changes to apache and which others may have to do -

Code: Select all

Code:
<IfModule mod_userdir.c>
   UserDir www
   UserDir disabled root

<Directory /home/*/www/>
      AllowOverride FileInfo AuthConfig Limit
      Options -Indexes SymLinksIfOwnerMatch IncludesNoExec
      Order deny,allow
      Deny from all
      Allow from 192.168.0.0/255.255.255.0
   </Directory>
</IfModule>
I had to change the "Allow from" IP address to match my own IP address to allow the 'From folder' upload option to work. Might be worth mentioning !

bubbalibre
Posts: 117
Joined: 01 Feb 2007, 09:33
Location: Paris, France

Post by bubbalibre » 25 Mar 2007, 13:12

Hi Clive,
Clive wrote:I had to change the "Allow from" IP address to match my own IP address to allow the 'From folder' upload option to work. Might be worth mentioning !
You're right, this directive should be modified according to your network configuration.

Code: Select all

Allow from 192.168.0.0/255.255.255.0
This line means that every computer whose IP adress has the form 192.168.0.xyz (where xyz stands for every number between 1 and 254) can reach the website. I guess that it's not your case. Am I clear ?

You could also write:

Code: Select all

Allow from all
Then every computer, including outside your home network, could reach the site. It isn't really secure but, as the list of files will not been displayed (-indexes), it shall do.

Thanks for the feedback.
Regards,

Yenii
Posts: 2
Joined: 22 Feb 2007, 07:03

Post by Yenii » 25 Mar 2007, 18:28

Hi bubbalibre,
I'm running your hack, 3.5. The graphics is really nice and soft.

But when I have many downloads, and want even more :D a little fight starts between me and "Add new download". Since the page autorefreshes often and I'm too slow - and its annoying - its hard to put in new ones...

Just something to do if you have some time over...

Thanks!

/Yenii

bubbalibre
Posts: 117
Joined: 01 Feb 2007, 09:33
Location: Paris, France

Post by bubbalibre » 25 Mar 2007, 19:20

Hi Yenii,

Thanks for the congratulation :oops:

Actually, the #3.5 should give you the same result that hack #4. It's only aimed to update only #3 versions. The link to the latest version is always in my first post.
Yenii wrote:But when I have many downloads, and want even more :D a little fight starts between me and "Add new download". Since the page autorefreshes often and I'm too slow - and its annoying - its hard to put in new ones...
I had the same problem. Here is a partial solution.
Image

Major changes
* the download list is now wrapped into a block

Minor changes
* the frame of the download list is always shown
* new shiny icons and buttons from Nuvola
* the number of downloads (and uploads) is now displayed above the 'speedOmeter'

Structural changes
* the ajax updater is now using the prototype framework
* the ajax tab menu is now using control.tabs (based on prototype)
* all css styles are now in bubba.css

The link above has been updated. And here is the archive containing only the modifications since rev#4: As usual, any feedback appreciated.

Enjoy!

Note for myself: this is rev#17
Last edited by bubbalibre on 27 Mar 2007, 18:54, edited 2 times in total.

bubbalibre
Posts: 117
Joined: 01 Feb 2007, 09:33
Location: Paris, France

Post by bubbalibre » 25 Mar 2007, 19:35

I almost forgot: the update of the download list occurs now every 10 seconds instead of 5, because with a long list I need that time to read it all.

Locked