Welcome to the EliteCubers forums!
Sign-Up To Get The Full Site Smile



 
ServersHomeHome PageRegisterLog in
Check the video "EC Intro" in the portal page
New Server by Elek11tr0 | log in to |EC| Main and |EC| Main 2 servers by typing /connect ecmain.mine.nu and /connect ecmain2.mine.nu
Log in
Username:
Password:
Log in automatically: 
:: I forgot my password
Rules
Read These Rules Before You Post:Rules
Top posters
CubriC (1491)
 
Ua51 (1099)
 
Kidkrazy (596)
 
Shorty (446)
 
BenWasHere (401)
 
Foo (331)
 
Mael$trom (310)
 
Elek11tr0 (288)
 
5econds (239)
 
~HeR's~ (229)
 
Latest topics
» Ua51 is here
Thu Dec 16, 2010 6:38 pm by Elek11tr0

» Hey hey
Thu Dec 16, 2010 6:36 pm by Elek11tr0

» Heya kiddies!
Wed Aug 04, 2010 12:31 pm by AWE5OME GUY

» Hi, i'm rulla
Wed Jul 07, 2010 10:35 pm by CubriC

» k1llerd3vold's application
Sat Jul 03, 2010 9:07 am by Kidkrazy


Share | 
 

 Simple AC application form in PHP made by me

Go down 
AuthorMessage
shadow_killer25
Active Member
Active Member


Posts : 123
Reputation : 0
Join date : 2009-01-20

PostSubject: Simple AC application form in PHP made by me   Tue Mar 03, 2009 12:18 pm

PHP Code
Code:

    <?php
$self = $_SERVER['PHP_SELF'];
if (isset($_POST['submit'])) {
$filename = "form.txt";
$open = fopen($filename, "a");
$name = $_POST['name'];
$months = $_POST['month'];
$skill = $_POST['skill'];
$test = $_POST['test'];
$anythingadd = $_POST['add'];
$often = $_POST['often'];
fwrite($open, "Name:\n$name\n");
fwrite($open, "How long have you been playing?\n$months\n");
fwrite($open, "Skill from 1-10\n$skill\n");
fwrite($open, "When can be tested\n$test\n");
fwrite($open, "Anything to add\n$anythingadd\n");
fwrite($open, "How often do you play\n$often\n\r");
fclose($open);
echo "Thank you for submitting your form these are your answers<br>";
echo "$name<br>"; echo "$months<br>"; echo "$skill<br>"; echo "$test<br>"; echo "$anythingadd<br>"; echo "$often";
}
?>
Remember do not edit anything

Here are the HTML code you can edit but not the names
Code:

<html>
<head>
<title>EC Application form</title>
</head>
<body>
<form action="<?php $self ?>" method="POST">
Name:<br>
<input type="text" name="name"><br>
Time you have been playing:<br>
<input type="text" name="month"><br>
Your skill from 1-10:<br>
<input type="text" name="skill"><br>
When can you be tested?<br>
<input type="text" name="test"><br>
Anything to add?<br>
<textarea name="add" cols="20"></textarea><br>
How often do you play?<br>
<input type="text" name="often"><br>
<input type="reset" value="Reset"><input type="submit" name="submit" value="Submit">
</form>
</body>
</html>
preview
http://sixzeal.co.cc/ac/
form will be saved at
http://sixzeal.co.cc/ac/form.txt

sorry but there is no mail function Razz
Back to top Go down
http://sixzeal.co.cc
BenWasHere
Ex EC
Ex EC
avatar

Posts : 401
Reputation : 15
Join date : 2009-01-18
Age : 24
Location : Christchurch, New Zealand

PostSubject: Re: Simple AC application form in PHP made by me   Wed Mar 04, 2009 8:58 pm

can it be saved in the website, like http://www.elitecubers.co.nr/applog.txt

_________________

DES|BenWasHere
Back to top Go down
http://elitecubers.darkbb.com
shadow_killer25
Active Member
Active Member


Posts : 123
Reputation : 0
Join date : 2009-01-20

PostSubject: Re: Simple AC application form in PHP made by me   Thu Mar 05, 2009 1:05 am

yup this will be the PHP code
Code:


    <?php
$self = $_SERVER['PHP_SELF'];
if (isset($_POST['submit'])) {
$filename = "applog.txt";
$open = fopen($filename, "a");
$name = $_POST['name'];
$months = $_POST['month'];
$skill = $_POST['skill'];
$test = $_POST['test'];
$anythingadd = $_POST['add'];
$often = $_POST['often'];
fwrite($open, "Name:\n$name\n");
fwrite($open, "How long have you been playing?\n$months\n");
fwrite($open, "Skill from 1-10\n$skill\n");
fwrite($open, "When can be tested\n$test\n");
fwrite($open, "Anything to add\n$anythingadd\n");
fwrite($open, "How often do you play\n$often\n\r");
fclose($open);
echo "Thank you for submitting your form these are your answers<br>";
echo
"$name<br>"; echo "$months<br>"; echo "$skill<br>";
echo "$test<br>"; echo "$anythingadd<br>"; echo "$often";
}
?>

changed the form.txt to applog.txt still learning mail function and trying to get it work Razz Razz
Back to top Go down
http://sixzeal.co.cc
BenWasHere
Ex EC
Ex EC
avatar

Posts : 401
Reputation : 15
Join date : 2009-01-18
Age : 24
Location : Christchurch, New Zealand

PostSubject: Re: Simple AC application form in PHP made by me   Thu Mar 05, 2009 5:06 am

tyvm shadow Smile

_________________

DES|BenWasHere
Back to top Go down
http://elitecubers.darkbb.com
BenWasHere
Ex EC
Ex EC
avatar

Posts : 401
Reputation : 15
Join date : 2009-01-18
Age : 24
Location : Christchurch, New Zealand

PostSubject: Re: Simple AC application form in PHP made by me   Thu Mar 05, 2009 5:42 am

There is now a link on the main page of the website called "application logs"(its hiding just under the shoutBox)
anyone can view it (for now)
all credit goes to shadow!
Cheers Ben

_________________

DES|BenWasHere
Back to top Go down
http://elitecubers.darkbb.com
shadow_killer25
Active Member
Active Member


Posts : 123
Reputation : 0
Join date : 2009-01-20

PostSubject: Re: Simple AC application form in PHP made by me   Thu Mar 05, 2009 11:25 am

Well you can change the CSS for that Smile

and i'll try to get the PHP mail working
Back to top Go down
http://sixzeal.co.cc
Sponsored content




PostSubject: Re: Simple AC application form in PHP made by me   

Back to top Go down
 
Simple AC application form in PHP made by me
Back to top 
Page 1 of 1
 Similar topics
-
» Viewing application/x-chess-pgn MIME on Android
» Simple-c-chess-engine
» THIS IS THE BEST DRAWING I HAVE PROBABLY EVER MADE.
» JOB APPLICATION!! Group: Reporter
» JOB APPLICATION!! Group: CB Mod

Permissions in this forum:You cannot reply to topics in this forum
 :: General :: Website :: Website Requests-
Jump to: