Upload PHP page help!

Hi All , PHP Noob here! I have a lil page im trin to get working ! Its an upload page … I can upload 7.5mb no problem! over that and it never post! I have the max file size @ 10mb … can yall look at it and tell me where i messed up??

<?php if ($HTTP_POST_VARS['action']) { ?> 
<!-- Code to process Uploaded File and Display --> 
<!-- The HTML to display the results --> 
?> 
<BR><A HREF="<?php echo $PHP_SELF ?>">Back</A> 
</FONT></P> 
</BODY> 
</HTML> 
<?php } else { ?> 
<HTML> 
<HEAD> 
<TITLE>File Upload</TITLE> 
<style type="text/css">
<!--
.style5 {color: #FF0000}
.style6 {color: #FF8040}
.style7 {color: #FFFFFF; }
-->
</style>
</HEAD> 
<BODY BGCOLOR="black" TEXT="white">

Back to <a href="http://www.MGXclan.com" target="_parent" class="style7"> www.<span class="style5">MGX</span>clan.com</a>
<hr />
<h2>In-Game Demo Commands for COD2:</h2>
<p><strong>Record [demoname]</strong> - <span class="style6">Starts recording an in-game demo with the filename you specify.</span></p>
<p class="style5"> (  The file is saved under 
  your \Program Files\Activision\Call of Duty 2\mgx\demos directory as a .dm_1 file.)</p>
<p><strong>StopRecord</strong> - <span class="style6">Stops recording the current demo.</span></p>
<p><strong>Demo [demoname]</strong> - <span class="style6">Plays back the pre-recorded demo specified. Note, to play back a demo you must be in the game menus - 
demos can't be played back while you're in-game.</span></p>
<hr />
<h1>Kegwads Upload Center</h1>
<p>Upload your In-Game Demos(.DM_1) ...... 10MB Max file size! </p> 
 <FORM METHOD="POST" ENCTYPE="multipart/form-data" 
      ACTION="<?php echo $PHP_SELF;?>"> 

<INPUT TYPE="HIDDEN" NAME="MAX_FILE_SIZE" VALUE="12345567890"> 
<INPUT TYPE="HIDDEN" NAME="action" VALUE="1"> 
<INPUT TYPE="FILE" NAME="file1" SIZE="30">
<INPUT TYPE="SUBMIT" VALUE="Upload"> 
</FORM> 
<hr />
</BODY> 
</HTML> 
<?php } ?> 
<strong><?php if ($HTTP_POST_VARS['action']) { ?> 

<HTML> 
<HEAD> 
<TITLE>File Upload Results</TITLE> 
</HEAD> 
<BODY BGCOLOR="WHITE" TEXT="BLACK"> 
File Upload Results<BR><BR> 
<?php     
    $uploadpath = 'uploads/'; 
    $source = $HTTP_POST_FILES['file1']['tmp_name']; 
    $dest = ''; 

    if ( ($source != 'none') && ($source != '' )) { 

        $imagesize = getimagesize($source); 

        switch ( $imagesize[2] ) { 

            case 0: 

                echo '<BR> Image is unknown <BR>'; 
				$dest = $uploadpath.uniqid('img').'.dm_1'; 
                break; 

            case 1: 
                echo '<BR> Image is a MP3 <BR>'; 
                $dest = $uploadpath.uniqid('img').'.mp3'; 
                break; 
             
            case 2: 
                echo '<BR> Image is a JPG <BR>'; 
                $dest = $uploadpath.uniqid('img').'.jpg'; 
                break; 
             
            case 3: 
                echo '<BR> Image is a RAR <BR>'; 
                $dest = $uploadpath.uniqid('img').'.rar'; 
                break; 

 
        } 

        if ( $dest != '' ) { 

            if ( move_uploaded_file( $source, $dest ) ) { 

                echo 'File successfully stored.<BR>'; 

            } else { 

                echo 'File could not be stored.<BR>'; 

            } 

        }  

    } else { 

        echo 'File not supplied, or file too big.<BR>'; 

    } 

?> 
<BR><A HREF="<?php echo $PHP_SELF ?>">Back</A> 
</BODY> 
</HTML> 
<?php } else { ?> 
<!-- File Upload Form HTML Code Here --> 
<?php } ?>

It is highly likely that your hosting has set the parameter on the server for php uploads. Check with them, the max-upload for php script is normally 8Mb.

Welcome to TPR :wave:

DT.

ok I think i comprehend what you said, My friend in Mi. has given me subspace!
Thanks ! Wow … so i coded it right?:confused: