HTML Forum

Post

Posted
Rating:
#3062 (In Topic #596)
hi guys im trying too add this code for my game website

<form action="/action_page.php">
  <fieldset>
    <legend>Arma 3 Malden Bases:</legend>
    Territory Owners Name:<br>
    <input type="text" name="Name" value=""><br>
    Base Name:<br>
    <input type="text" name="Base" value=""><br>
    Base Location:<br>
    <input type="text" name="Co-Ords" value=""><br><br>
    <input type="submit" value="Submit">
  </fieldset>
</form> <br />
<br />
the problem is, its showing but when you submit it, its not showing anything or gives you a 404 error<br />
i believe it has to do with "/action_page.php"> but dont know how to change it or get it changed if need to make a special page.

so could someone pleas tell me how to fix this or what im doing wrong.

Post

Posted
Rating:
#3063
First step would be confirming how the URL with the 404 does or does not match the expected location of "/action_page.php".

Also you're missing method="post" on the form tag.

Post

Posted
Rating:
#3064
To clarify what I mean, we really need to know the FTP path to action_page.php, the URL the HTML is put on, and the URL that shows as a 404. That should allow us to see why it's misdirecting (assuming that's the issue).

Post

Posted
Rating:
#3065
if i make another page though the comcode page
like this  site:Arma_3_Bases so the complete codes are like so


Arma 3 Bases



 
    Arma 3 Malden Bases:     Owners Name:
   
    Base Name:
   
    Base Location Co-ords:
   

     


it will make the page with the first picture

Preview.png
or maybe im doing all this wrong on how to set it up.
also this is confusing me   /action_page.php    as its pretty much saying where this should be but i dont have it

so what am i really doing wrong

Post

Posted
Rating:
#3066
If you post Comcode within a forum post here, it will treat it like Comcode as it would on your own site. You need to put it within Comcode code tags.

However, on reading what you wrote it sounds like you don't actually have the action_page.php file the form is posting to. There is a lot between you and this working I'm afraid – even if you get a copy of this file (from whereever it is), the file is probably is making assumptions about database tables and many other things, all of which would need duplicating on your server.

Post

Posted
Rating:
#3067

Chris Graham said

If you post Comcode within a forum post here, it will treat it like Comcode as it would on your own site. You need to put it within Comcode code tags.

However, on reading what you wrote it sounds like you don't actually have the action_page.php file the form is posting to. There is a lot between you and this working I'm afraid – even if you get a copy of this file (from whereever it is), the file is probably is making assumptions about database tables and many other things, all of which would need duplicating on your server.

i got it from

HTML Forms

W3Schools offers free online tutorials, references and exercises in all the major languages of the web. Covering popular subjects like HTML, CSS, JavaScript, Python, SQL, Java, and many, many more.

View


so its sounds like a really bad headache to do

Post

Posted
Rating:
#3070
Ah, I see. That's just trying to explain how the form tag works, but you need to hook it up to something server-side.

If you change it to use action="/data/form_to_email.php" (and add method="post") it should e-mail you the contents. form_to_email.php is a default script we provide.

Post

Posted
Rating:
#3072
ill try this out,

if i was to start from the beginning with the code, how would i get things started like new page or forum and so on.

its so i got an insight on what to do and  where it will go

Last edit: by rgscriven

5 guests and 0 members have recently viewed this.