limited webspace

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
chexm8
Forum Newbie
Posts: 5
Joined: Sun Aug 03, 2003 11:04 am

limited webspace

Post by chexm8 »

I have creates a script where members to the site can have webspace on my server.

But I need to give them limited webspace, say about 5mb. Is it possible for me to do this? And if yes, how do I go about it?

Any help with scripting or head me to some php function that allows me do to this is much appreciated.

Thanks :)
User avatar
evilmonkey
Forum Regular
Posts: 823
Joined: Sun Oct 06, 2002 1:24 pm
Location: Toronto, Canada

Post by evilmonkey »

Forgive if I'm wrong, but i don't think you can do this with PHP. You need to do this with your server. You can send commands to your server using PHP, but don't expect PHP to control webspace.

Cheers!
User avatar
chexm8
Forum Newbie
Posts: 5
Joined: Sun Aug 03, 2003 11:04 am

Post by chexm8 »

Thanks for the quick reply. :cry:
User avatar
chexm8
Forum Newbie
Posts: 5
Joined: Sun Aug 03, 2003 11:04 am

Post by chexm8 »

Would it be possible to allow members to post certain number of words or letters to the database?
m3rajk
DevNet Resident
Posts: 1191
Joined: Mon Jun 02, 2003 3:37 pm

Post by m3rajk »

yes

you need a feild (preferably in a file outsdie the webtree) then in there (i'd mask the actual value so ppl don't know what it is) you should have it set. when they have that number of entries instead of inserting you return an error
User avatar
chexm8
Forum Newbie
Posts: 5
Joined: Sun Aug 03, 2003 11:04 am

Post by chexm8 »

Any idea how to start scripting this?

Just need to know how to start. I can do the rest.

thanks
m3rajk
DevNet Resident
Posts: 1191
Joined: Mon Jun 02, 2003 3:37 pm

Post by m3rajk »

<?php
include('/path/to/include/file.php/');






and the include file....
<?php
$max_entries=







then when checking
if($max_entries===mysql_num_rows($query)){
#error
}else{
#add
}
User avatar
chexm8
Forum Newbie
Posts: 5
Joined: Sun Aug 03, 2003 11:04 am

Post by chexm8 »

Thanks.

Looks simple enough. I hope I can ask you for more help if I need it.

Regards
Post Reply