Song-sharing-platform

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Song-sharing-platform

Stephane Thomas-3
Hi,

I started to think about how to write a file sharing platform in
PHP/MySQL, i put i description here to know if we're talking of the same
thing...

General :

 - Using Apache (a .htpassw file) for permissions but adding a "users"
MySQL table to permit a file to be linked with an user and to stock
users options (is_admin, realname, etc...)

 - Have a trash to permit to the owner of a file or an admin to restore
a deleted file. Trash can be empty in the administration interface.

 - No nested categories, harder to code...

File tree would be something like this :

Songs
  |_Techno
  |   |_foo1.xml
  |   |_foo2.xml
  |_Rock
      |_foo3.xml

Samples
  |_Kick
  |   |_foo.xml
  |_Harps
      |_foo.xml

Categories are set by admin users.

Now i'll describe the differents pages of the application :

1) Browse database (same page for songs, samples and presets)

A tree view of the differents files.
For each file it's possible to :
 - download
 - see
 - delete (if admin or owner)

2) Add (song|samples|presets) to database (three different pages as the
categories are not the same for songs, samples or presets)

It's a multiple upload form with a radio input to choose the category.

3) New|Modify account

 - login
 - pass
 - realname
 - is_admin ? (if admin)

4) Administration interface

 4a) Accounts list with delete and modify links
 4b) Trashed files list with delete, restore links and an empty trash
link.


For the MySQL database we need (today i don't have the time to make a
real conceptual model with relations etc...)

a table "users" with at least
(login,realname,date_of_inscription,date_of_lastlogin)
a table "categories" with at least (name,type)

a table "files" with at least
(filename,users.login,categories.name,date_of_entry,is_trashed)

I think it's all we need.


--
Stephane Thomas <[hidden email]>



-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
LMMS-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/lmms-devel
Reply | Threaded
Open this post in threaded view
|

Re: Song-sharing-platform

Tobias Doerffel-2
Am Donnerstag, 15. September 2005 13:26 schrieb Stephane Thomas:
> Hi,
>
> I started to think about how to write a file sharing platform in
> PHP/MySQL, i put i description here to know if we're talking of the same
> thing...
cool ;-)

> General :
>
>  - Using Apache (a .htpassw file) for permissions but adding a "users"
> MySQL table to permit a file to be linked with an user and to stock
> users options (is_admin, realname, etc...)
ok, I don't know that much about developing web-pages with users, logins
etc... but we should focus on security if we host it on sf.net since the
security is not the best there (as mentioned in
http://meta.wikimedia.org/wiki/Running_MediaWiki_on_Sourceforge.net)

>  - Have a trash to permit to the owner of a file or an admin to restore
> a deleted file. Trash can be empty in the administration interface.
why this? if a user really wants to delete one of it's content, then it
shouldn't be saved anywhere anymore... but we can discuss this point later.

>  - No nested categories, harder to code...
thats ok for the first time. maybe one could add this feature later...

> File tree would be something like this :
>
> Songs
>
>   |_Techno
>   |
>   |   |_foo1.xml
>   |   |_foo2.xml
>   |
>   |_Rock
>   |
>       |_foo3.xml
>
> Samples
>
>   |_Kick
>   |
>   |   |_foo.xml
>   |
>   |_Harps
>   |
>       |_foo.xml
samples are unlikely to be xml-files but that's ok ;-) I know what you mean.
the idea of also sharing free samples and presets is really good!

> Now i'll describe the differents pages of the application :
>
> 1) Browse database (same page for songs, samples and presets)
>
> A tree view of the differents files.
> For each file it's possible to :
>  - download
>  - see
>  - delete (if admin or owner)
maybe later also rating or even better adding/reading comments, what do you
think?

> 2) Add (song|samples|presets) to database (three different pages as the
> categories are not the same for songs, samples or presets)
>
> It's a multiple upload form with a radio input to choose the category.
hmm? why different pages when selecting category with a radio input? did I
misunderstood something?

> 3) New|Modify account
>
>  - login
>  - pass
>  - realname
>  - is_admin ? (if admin)
that should be ok for the first time, it's everyhting what's really needed ;-)

> For the MySQL database we need (today i don't have the time to make a
> real conceptual model with relations etc...)
thats ok ;-) you still did very much so far!

> a table "categories" with at least (name,type) a table "files" with at least
> (filename,users.login,categories.name,date_of_entry,is_trashed)
how do you want to save files? in the mysql-db or as files on the server? add
ability of compressing files? this makes much sense especially when working
with big XML-files...


thank you for you ideas!

toby

--
Wer einen Aal beim Schwanz
Und Weiber faßt bei Worten,
Wie feste der gleich hält,
Hält nichts an beiden Orten.
                -- Friedrich von Logau (Sinngedichte)

attachment0 (316 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Song-sharing-platform

Stephane Thomas-3
Le jeudi 15 septembre 2005 à 13:41 +0200, Tobias Doerffel a écrit :

> maybe later also rating or even better adding/reading comments, what do you
> think?

Adding a comment isn't difficult, it's a good idea.

> > It's a multiple upload form with a radio input to choose the category.
> hmm? why different pages when selecting category with a radio input? did I
> misunderstood something?

The category won't be the same for a song or for a sample.

> how do you want to save files? in the mysql-db or as files on the server? add
> ability of compressing files? this makes much sense especially when working
> with big XML-files...

I don't know how to retrieve a binary from a mysql database. I don't
know well how to deal with BLOB mysql type, i can learn...

I think saving the files in the file system. I don't know what's the
best solution, inside or outside the database ?


--
Stephane Thomas <[hidden email]>



-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
LMMS-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/lmms-devel
Reply | Threaded
Open this post in threaded view
|

Re: Song-sharing-platform

Tobias Doerffel-2
Am Donnerstag, 15. September 2005 16:27 schrieb Stephane Thomas:
> > > It's a multiple upload form with a radio input to choose the category.
> > hmm? why different pages when selecting category with a radio input? did
> > I misunderstood something?
>
> The category won't be the same for a song or for a sample.
what about a select-box (<option ...>)?

> I think saving the files in the file system. I don't know what's the
> best solution, inside or outside the database ?
this depends on size of files. generally files on server are easier to handle
at all, so if we have the possibility to store files on a server (which is
NOT the case on sf.net-webspace or at least it sucks doing so...).

toby

--
Wenn Adam auf die Erde zurückkäme, würde er nichts wiedererkennen -
ausgenommen die Witze.
                -- Ugo Tognazzi

attachment0 (316 bytes) Download Attachment