Forum: PHP Aug 7th, 2009 |
| Replies: 7 Views: 353 also just to optimize the php code you have, I would switch to a switch statement instead of going through a ton of if statements.
Also, the code you entered didn't parse correctly, did it? I... |
Forum: PHP Aug 7th, 2009 |
| Replies: 7 Views: 353 try adding readfile at the end
.....
header('Content-Disposition: attachment; filename="'.$name.'.'.$ext.'"');
readfile($file);
?> |
Forum: PHP Jul 11th, 2009 |
| Replies: 32 Views: 1,547 Oops, the
$grade = 5;
is supposed to
$grade = $grade + 5; |
Forum: PHP Jul 11th, 2009 |
| Replies: 32 Views: 1,547 It looks like you're calculating them to have full credit if they haven't taken the exam, if that's the case...
if ($_POST['Quiz1'] >= 0 && $_POST['Quiz1'] <= 100)
$grade = $grade +... |
Forum: PHP Jul 11th, 2009 |
| Replies: 32 Views: 1,547 Something simple and straightfowrd...
$grade = 0;
if ($_POST['QUIZ1'] >= 0 && $_POST['QUIZ1'] <= 100)
$grade = $grade + $_POST['QUIZ1'] * 0.05;
if ($_POST['Mid-Term'] >= 0 &&... |
Forum: PHP Mar 12th, 2005 |
| Replies: 6 Views: 2,462 yes I think that PHP does support some ftp functions (i have no idea how to use those) so that you could log into another off site server and access these files, although this would probably be too... |
Forum: PHP Mar 11th, 2005 |
| Replies: 6 Views: 2,462 the other thing you could do with the private section is restrict downloads. Suppose you only want to let your members download certain videos from your website (or any other content) then you can... |