confused and dazed Posted November 13, 2011 Share Posted November 13, 2011 I am new to web programming and I think I am missing a simple concept that is keeping me from going forward. I have a hosting account with Go Daddy and I want to send a bunch of data to my server or to an e-mail address. I have a bunch of buttons with values populated from an "onclick" command and I want all that button data to be sent somewhere. This is where I cannot figure out how to proceed. Please help. Link to comment Share on other sites More sharing options...
dsonesuk Posted November 13, 2011 Share Posted November 13, 2011 http://w3schools.com/html/tryit.asp?filename=tryhtml_form_submit Link to comment Share on other sites More sharing options...
birbal Posted November 13, 2011 Share Posted November 13, 2011 you need to handlle the data using php or any server side language. check here http://w3schools.com/html/html_forms.asp in form's action attribute you will sepecify where the data will be sent and method will tell how via get or post. html or js cant send email you will need server side language for it. Link to comment Share on other sites More sharing options...
confused and dazed Posted November 13, 2011 Author Share Posted November 13, 2011 So you cannot send data to a file? Only to a page within the server? Link to comment Share on other sites More sharing options...
confused and dazed Posted November 13, 2011 Author Share Posted November 13, 2011 Thanks for the response. One questions - I know my ignorence will show here but .asp file - how do I create this file? Is it as simple as using a notepad file and save it as a .asp Link to comment Share on other sites More sharing options...
dsonesuk Posted November 13, 2011 Share Posted November 13, 2011 http://w3schools.com/html/tryit.asp?filename=tryhtml_form_mail Link to comment Share on other sites More sharing options...
birbal Posted November 13, 2011 Share Posted November 13, 2011 yes you can create it in notepad. but it needs a server installed in your compuer to run the file. did you check the w3schools.com/asp tutorials for start over?btw the examples in above link uses .asp that does not mean its obvious to use .asp. as w3schoos tutorial part is written in .asp so it is sending to a .asp file. it could be any other file which knows what to do with that data to process it. If you are not specialy leaned toward asp and just planing to learn any server side language. I will say to start with php. Link to comment Share on other sites More sharing options...
confused and dazed Posted November 13, 2011 Author Share Posted November 13, 2011 Thank you for the response and yes I am extremely new... as if you could not tell :)Is there a tutorial you recommend for php? Link to comment Share on other sites More sharing options...
birbal Posted November 13, 2011 Share Posted November 13, 2011 you can start over from hereat first form here http://w3schools.com/php (tutorial ,easy to catch up)in depth info and the manual is here http://php.net/language Link to comment Share on other sites More sharing options...
Ingolme Posted November 13, 2011 Share Posted November 13, 2011 You only need to make one thread for your problems. I've merged the two threads here. Link to comment Share on other sites More sharing options...
confused and dazed Posted November 13, 2011 Author Share Posted November 13, 2011 This tutotial is going to be great! Thanks. I started going through it and I think there is one last bit of information I am missing. How do I test the code I am writing? I tried to load the .php file off my local drives to my server side and it will not load. It appears I can only load .html files on my server side. Am I missing something? Link to comment Share on other sites More sharing options...
Ingolme Posted November 13, 2011 Share Posted November 13, 2011 It's possible that your server does not support PHP. What web host do you have? Link to comment Share on other sites More sharing options...
confused and dazed Posted November 13, 2011 Author Share Posted November 13, 2011 I have go daddy and they said they support .php strange. Link to comment Share on other sites More sharing options...
confused and dazed Posted November 13, 2011 Author Share Posted November 13, 2011 I have go daddy and I am using Windows not Linux Link to comment Share on other sites More sharing options...
Ingolme Posted November 13, 2011 Share Posted November 13, 2011 What happens when you try to load a PHP file? Link to comment Share on other sites More sharing options...
confused and dazed Posted November 13, 2011 Author Share Posted November 13, 2011 O.k maybe I am missing something basic again... the .php file I created in notepad and I am simply trying to put it in the server directory. Is there a specific place or file or page I need to place the .php file? Link to comment Share on other sites More sharing options...
confused and dazed Posted November 13, 2011 Author Share Posted November 13, 2011 I guess I didnt answer your question - it tells me "unable to upload one or more file(s)" Link to comment Share on other sites More sharing options...
confused and dazed Posted November 13, 2011 Author Share Posted November 13, 2011 It worked now. I'm not sure why it did not load - maybe becauser I was working on the file and it was open at the time. I am going to mess around for a while now... thanks to all for responding and getting this baby rolling over. I hope to be crawling soon. Later!!! Link to comment Share on other sites More sharing options...
confused and dazed Posted November 13, 2011 Author Share Posted November 13, 2011 I'm pickin it up fairly easily - here is a new question. How do I get php to post process the value of a regular button. I would like to see all the information contained in all the buttons I have. I am using an onclick command to populate the value of the buttons. Link to comment Share on other sites More sharing options...
justsomeguy Posted November 14, 2011 Share Posted November 14, 2011 Information sent to PHP is available through $_GET and $_POST. You can use print_r to print out the entire array: print_r($_POST); Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.