TinyPortal

Development => Block Codes => Topic started by: alan s on September 10, 2006, 05:49:48 PM

Title: File Host Service/Block
Post by: alan s on September 10, 2006, 05:49:48 PM
Might be a bit pointless if your using the tinyportal download module but you could use it as a alternitive.

Install Instrucions : Unzip and upload the package attached to your server ( edit the config.php file with your details )


Customisation Instrucions : Edit the file in the "pages" folder to suit your site.


Then create a script block and insert this code.

<form enctype="multipart/form-data" action="http://yoursite.com/upload/upload.php" id="form" method="post" target="_blank" onsubmit="a=document.getElementById('form').style;a.display='none';b=document.getElementById('part2').style;b.display='inline';" style="display: inline;">
<input name="upfile" size="15" type="file"><br>
25mb File Size Limit!. <input value="Upload!" onclick="window.open"('http://yoursite.com/upload/upload.php') id="upload" type="submit">
</form>


Change the yoursite.com/upload to your site url and the directory where your script is in.

Demo : http://theteenzone.net/smf1.1rc3/

Title: Re: File Host Service/Block
Post by: Greenbug on September 10, 2006, 06:01:31 PM
I dont see anything attached here

Title: Re: File Host Service/Block
Post by: alan s on September 10, 2006, 06:04:10 PM
Ooops ! forgot to attach it ! thanks for letting me know , i edited my post with the attachment.
Title: Re: File Host Service/Block
Post by: Greenbug on September 10, 2006, 06:27:24 PM
Thanks Alan

I left an question on your forum for ya....

This works well for off site file hosting
Title: Re: File Host Service/Block
Post by: alan s on September 10, 2006, 07:18:02 PM
I'll answer your questions you posted on my site here.

I just edited the mod package for the youtube bbc code , i think i posted it on the smf forums but heres the download link for the rc3 version of the youtube bbc code anyway

http://theteenzone.net/upload/download.php?file=d971e937d39a40efbe516060a718b62d

as for the music video you want to embed from that site just use the embed code they give but add a

[html]

before it and a 

[html]

after it.

However i could come up with a bbc tag mod for it if you want.

Title: Re: File Host Service/Block
Post by: Greenbug on September 10, 2006, 07:20:25 PM
Quote from: Alan S on September 10, 2006, 07:18:02 PM
I'll answer your questions you posted on my site here.

I just edited the mod package for the youtube bbc code , i think i posted it on the smf forums but heres the download link for the rc3 version of the youtube bbc code anyway

http://theteenzone.net/upload/download.php?file=d971e937d39a40efbe516060a718b62d

as for the music video you want to embed from that site just use the embed code they give but add a

[html]

before it and a 

[html]

after it.

However i could come up with a bbc tag mod for it if you want.

That would be awesome Alan if you could. something that the board could use. If am I correct this would also allow any file hosting that uses the microsoft player as well?
Title: Re: File Host Service/Block
Post by: alan s on September 10, 2006, 07:23:44 PM
I asseum your talking about the html tags letting any file hosting use the media player , yes you can embed anything using the html tags , videos , music , flash etc...but the admins the only one allowed to use them html tags though i think theres a mod out that lets you select the membergroups allowed to use it.

I might have that mod done tonight , depends on how busy i am , if not i 'll get it done tomorrow
Title: Re: File Host Service/Block
Post by: Greenbug on September 10, 2006, 07:25:43 PM
Awesome Alan SÃ,  - you're the man!

I'm an idiot, I wasnt aware of the html bbc tags you cold use. This seems to work for everything. DUH!

learning is a slow process for me sometimes.....
Title: Re: File Host Service/Block
Post by: alan s on September 10, 2006, 09:11:40 PM
Mod created , attached to post , works with 1.1rc3 only , i'll submit it to the mod site later.


Demo : http://theteenzone.net/smf1.1rc3/
Title: Re: File Host Service/Block
Post by: akulion on September 11, 2006, 04:58:52 PM
also remember to allow only members to be able to see this block

cos if guests could upload it could be a disaster

for added security only allow members with a minimum of 50 posts to use this function

or anyone could sign up and upload a potential hack to your server and use it against you
Title: Re: File Host Service/Block
Post by: alan s on September 11, 2006, 05:02:24 PM
I dont think the hack is possible akulion , it doesnt excute the uploaded file and you dont get the direct link to the file. You get a link to a download page ( like rapidshare.de if you have used that ).
Title: Re: File Host Service/Block
Post by: akulion on September 11, 2006, 05:28:47 PM
everything is possible lol

but with that little added security feature which u mentioned it would be good
Title: Re: File Host Service/Block
Post by: Mintschi on August 13, 2007, 02:06:04 PM
Any chance to get a working Downloadlink for this interessting Block?
Title: Re: File Host Service/Block
Post by: Mintschi on November 02, 2007, 02:56:27 PM
What a pity!
Title: Re: File Host Service/Block
Post by: serpento on November 21, 2007, 03:49:41 AM
Aw, I really wanted this block, to bad theres no more download link :(