• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 16:07
CEST 22:07
KST 05:07
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
TL.net Map Contest #21: Voting10[ASL20] Ro4 Preview: Descent11Team TLMC #5: Winners Announced!3[ASL20] Ro8 Preview Pt2: Holding On9Maestros of the Game: Live Finals Preview (RO4)5
Community News
BSL Team A vs Koreans - Sat-Sun 16:00 CET6Weekly Cups (Oct 6-12): Four star herO85.0.15 Patch Balance Hotfix (2025-10-8)80Weekly Cups (Sept 29-Oct 5): MaxPax triples up3PartinG joins SteamerZone, returns to SC2 competition32
StarCraft 2
General
Revisiting the game after10 years and wow it's bad The New Patch Killed Mech! TL.net Map Contest #21: Voting Stellar Fest: StarCraft II returns to Canada herO Talks: Poor Performance at EWC and more...
Tourneys
SC2's Safe House 2 - October 18 & 19 Sparkling Tuna Cup - Weekly Open Tournament $1,200 WardiTV October (Oct 21st-31st) WardiTV Mondays RSL Offline Finals Dates + Ticket Sales!
Strategy
Custom Maps
Map Editor closed ?
External Content
Mutation # 496 Endless Infection Mutation # 495 Rest In Peace Mutation # 494 Unstable Environment Mutation # 493 Quick Killers
Brood War
General
BW General Discussion BSL Season 21 BGH Auto Balance -> http://bghmmr.eu/ BW caster Sayle BSL Team A vs Koreans - Sat-Sun 16:00 CET
Tourneys
[ASL20] Semifinal B [Megathread] Daily Proleagues SC4ALL $1,500 Open Bracket LAN [ASL20] Semifinal A
Strategy
Current Meta BW - ajfirecracker Strategy & Training Relatively freeroll strategies Siegecraft - a new perspective
Other Games
General Games
Stormgate/Frost Giant Megathread Dawn of War IV Path of Exile Nintendo Switch Thread ZeroSpace Megathread
Dota 2
Official 'what is Dota anymore' discussion LiquidDota to reintegrate into TL.net
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Deck construction bug Heroes of StarCraft mini-set
TL Mafia
TL Mafia Community Thread SPIRED by.ASL Mafia {211640}
Community
General
US Politics Mega-thread Russo-Ukrainian War Thread Things Aren’t Peaceful in Palestine Men's Fashion Thread Sex and weight loss
Fan Clubs
The herO Fan Club! The Happy Fan Club!
Media & Entertainment
Series you have seen recently... Anime Discussion Thread [Manga] One Piece Movie Discussion!
Sports
2024 - 2026 Football Thread Formula 1 Discussion MLB/Baseball 2023 NBA General Discussion TeamLiquid Health and Fitness Initiative For 2023
World Cup 2022
Tech Support
SC2 Client Relocalization [Change SC2 Language] Linksys AE2500 USB WIFI keeps disconnecting Computer Build, Upgrade & Buying Resource Thread
TL Community
The Automated Ban List Recent Gifted Posts
Blogs
The Heroism of Pepe the Fro…
Peanutsc
Rocket League: Traits, Abili…
TrAiDoS
Customize Sidebar...

Website Feedback

Closed Threads



Active: 1593 users

HTML/PHP help?

Blogs > M155_G33k
Post a Reply
M155_G33k
Profile Blog Joined March 2010
United States470 Posts
October 03 2011 23:09 GMT
#1
So for my html class we have to make a web page. I came up with this really cheesy idea for pranks and stuff. Well, I wanted to have a page for submissions and to have those emailed to me so I can post them later on. However, the pages aren't friggen working and I've gone through the code so much, that I am just about to DEGAF T_T When you hit the submit button, you get the "This page cannot be displayed yadda yadda -- http error 405"

I dont know if its an internal server error or my codes are wrong, but any explanation would be great.


Here is the web page: http://it-web.nhti.edu/student41/submit.html


Here is the code for the submission page:

+ Show Spoiler +

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head>
<meta content="en-us" http-equiv="Content-Language" />
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
<title>Submit Your Stories</title>
<style type="text/css">
.auto-style1 {
text-align: center;
}
</style>
</head>

<body background="background.jpg" link="white" vlink="white">

<table bgcolor="black" border="5" width="80%" align="center">
<tr><td>

<font color="white">

<h1 class="auto-style1" align="center" id="top">Submit Your Stories</h1>
<center>
<font size="3" color="#ffffff">
<a href="default.aspx">Home Base</a> | <a href="past.html">Past Missions</a> | Submit Your Stories
</font>
</center>
<hr width="80%" size="5" color="red" noshade />
</font>

<font color="white">

<form action="send-mail.php" method="post">
Name:<br />
<input type="text" name="name" value="" maxlength="100" /><br />

Story:<br />
<textarea rows="10" cols="50" name="comments"></textarea> <br />

<input type="submit" value="Submit" />
</form>

</font>

<hr width="80%" size="5" color="red" noshade />

<center>
<font size="3" color="#ffffff">
<a href="default.aspx">Home Base</a> | <a href="past.html">Past Missions</a> | Submit Your Stories

</font>
</center>

<br />
</td></tr>
</table>

</body>

</html>


And here is the PHP code:
+ Show Spoiler +

<?php
/*
This first bit sets the email address that you want the form to be submitted to.
You will need to change this value to a valid email address that you can access.
*/
$webmaster_email = "m155g33k@gmail.com";

/*
This bit sets the URLs of the supporting pages.
If you change the names of any of the pages, you will need to change the values here.
*/
$submit = "submit.html";
$error_page = "error_message.html";
$thankyou_page = "thank_you.html";

/*
This next bit loads the form field data into variables.
If you add a form field, you will need to add it here.
*/
$name = $_REQUEST['name'] ;
$comments = $_REQUEST['comments'] ;


// If the user tries to access this script directly, redirect them to the feedback form,
if (!isset($_REQUEST['name'])) {
header( "Location: $submit" );
}

// If the form fields are empty, redirect to the error page.
elseif (empty($name) || empty($comments)) {
header( "Location: $error_page" );
}

// If email injection is detected, redirect to the error page.
elseif ( isInjected($name) ) {
header( "Location: $error_page" );
}

// If we passed all previous tests, send the email then redirect to the thank you page.
else {
mail( "$webmaster_email", "Feedback Form Results",
$comments, "From: $name" );
header( "Location: $thankyou_page" );
}
?>


Any help would be so appreciated. I just hope it's not something stupid lol

(and so help me if it is something stupid like a wrong case letter T_T)


Thanks everyone

"It can't be a NE Lan without any problems!" ~ "Starcraft is like sex. After a rough round, sometimes you just need that cigarette."
R1CH
Profile Blog Joined May 2007
Netherlands10341 Posts
October 03 2011 23:24 GMT
#2
You're trying to use PHP but your web server is Microsoft IIS, are you sure PHP is supported and allowed on the server? The "method not allowed" means the server is denying your POST request, probably because it isn't configured to run scripts.
AdministratorTwitter: @R1CH_TL
Phtes
Profile Blog Joined October 2010
United States370 Posts
Last Edited: 2011-10-03 23:25:21
October 03 2011 23:24 GMT
#3
edit: r1ch beat me to it lol
I'm Your Phtes o.0 **SKT1 For Life!**
M155_G33k
Profile Blog Joined March 2010
United States470 Posts
October 03 2011 23:41 GMT
#4
*sigh* Yah I just found out. It seems that the teacher thought it was. Did a whole class on PHP. He told us today to post it to our account on the server. He called the network admin to find out why it wasn't working, guess what! It doesn't allow PHP T_T


BLAH
"It can't be a NE Lan without any problems!" ~ "Starcraft is like sex. After a rough round, sometimes you just need that cigarette."
Phtes
Profile Blog Joined October 2010
United States370 Posts
October 03 2011 23:52 GMT
#5
Is your project required to link to a PHP database? if not, just create some redirect pages and be done with it xD.

Never really heard of a HTML class requiring PHP to begin with o.0
I'm Your Phtes o.0 **SKT1 For Life!**
M155_G33k
Profile Blog Joined March 2010
United States470 Posts
October 04 2011 00:08 GMT
#6
On October 04 2011 08:52 Phtes wrote:
Is your project required to link to a PHP database? if not, just create some redirect pages and be done with it xD.

Never really heard of a HTML class requiring PHP to begin with o.0


Its a web design class officially, but we mainly deal with html. He teaches using a gui based app where ass I like doing the actual code. Thats why I was afraid that my code was wrong >_<
"It can't be a NE Lan without any problems!" ~ "Starcraft is like sex. After a rough round, sometimes you just need that cigarette."
Deleted User 183001
Profile Joined May 2011
2939 Posts
Last Edited: 2011-10-04 00:32:51
October 04 2011 00:32 GMT
#7
AFAIK, 405 comes up when a request is made (like to a form), and the method (like POST, GET, etc.) isn't allowed. This is really weird, because POST and GET are very important global variables in PHP that are filled upon submission of a form, for example.

My web dev experience has only been with Apache servers, so there has to be some issue with your server that isn't allowing PHP OR PHP isn't installed. Verify that PHP is installed on your server. If it is, then contact your IT guy.

Edit: My bad. I see that the IT guy's on the issue. Well, once it's fixed, good luck
Phtes
Profile Blog Joined October 2010
United States370 Posts
October 04 2011 01:04 GMT
#8
On October 04 2011 09:08 M155_G33k wrote:
Show nested quote +
On October 04 2011 08:52 Phtes wrote:
Is your project required to link to a PHP database? if not, just create some redirect pages and be done with it xD.

Never really heard of a HTML class requiring PHP to begin with o.0


Its a web design class officially, but we mainly deal with html. He teaches using a gui based app where ass I like doing the actual code. Thats why I was afraid that my code was wrong >_<


Yeah I'm in a web design major and my college has it seperated, like HTMl/CSS are considered Intro / etc Web Design with server coding seperate, like Intro / inter / advanced programming logic, then you have the extra stuff like intro / advanced java etc.


GUI, you using a dreamweaver? ewwww. Notepad++ is where its at ^^
I'm Your Phtes o.0 **SKT1 For Life!**
Please log in or register to reply.
Live Events Refresh
IPSL
19:00
Ro24 Group D
Sziky vs Havi
Artosis vs Klauso
Airneanach54
Liquipedia
Safe House 2
17:00
Playoffs
TriGGeR vs Cham
Astrea vs TBD
ZombieGrub681
TKL 328
3DClanTV 80
EnkiAlexander 75
CosmosSc2 75
LiquipediaDiscussion
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
ZombieGrub681
TKL 328
JuggernautJason91
ProTech81
CosmosSc2 75
Railgan 28
StarCraft: Brood War
Larva 696
Barracks 305
Dewaltoss 147
Hyun 143
Mong 58
NaDa 27
scan(afreeca) 14
Counter-Strike
fl0m2653
Stewie2K513
Heroes of the Storm
Liquid`Hasu572
Khaldor470
Other Games
Grubby2364
ScreaM1531
ToD313
Pyrionflax219
gobbtv178
ArmadaUGS120
Hui .115
Organizations
Other Games
gamesdonequick2984
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 15 non-featured ]
StarCraft 2
• Adnapsc2 18
• Migwel
• AfreecaTV YouTube
• intothetv
• sooper7s
• Kozan
• IndyKCrew
• LaughNgamezSOOP
StarCraft: Brood War
• blackmanpl 16
• STPLYoutube
• ZZZeroYoutube
• BSLYoutube
Dota 2
• Ler54
League of Legends
• imaqtpie2909
Other Games
• Shiphtur154
Upcoming Events
Replay Cast
13h 53m
Monday Night Weeklies
19h 53m
WardiTV Invitational
1d 14h
WardiTV Invitational
1d 18h
Tenacious Turtle Tussle
3 days
The PondCast
3 days
WardiTV Invitational
4 days
Online Event
4 days
RSL Revival
5 days
RSL Revival
5 days
[ Show More ]
WardiTV Invitational
5 days
Afreeca Starleague
6 days
Snow vs Soma
Sparkling Tuna Cup
6 days
WardiTV Invitational
6 days
RSL Revival
6 days
Liquipedia Results

Completed

Acropolis #4 - TS2
WardiTV TLMC #15
HCC Europe

Ongoing

BSL 21 Points
ASL Season 20
CSL 2025 AUTUMN (S18)
C-Race Season 1
IPSL Winter 2025-26
EC S1
Thunderpick World Champ.
CS Asia Championships 2025
ESL Pro League S22
StarSeries Fall 2025
FISSURE Playground #2
BLAST Open Fall 2025
BLAST Open Fall Qual
Esports World Cup 2025
BLAST Bounty Fall 2025
BLAST Bounty Fall Qual

Upcoming

SC4ALL: Brood War
BSL Season 21
BSL 21 Team A
BSL 21 Non-Korean Championship
RSL Offline Finals
RSL Revival: Season 3
Stellar Fest
SC4ALL: StarCraft II
CranK Gathers Season 2: SC II Pro Teams
eXTREMESLAND 2025
ESL Impact League Season 8
SL Budapest Major 2025
BLAST Rivals Fall 2025
IEM Chengdu 2025
PGL Masters Bucharest 2025
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2025 TLnet. All Rights Reserved.