Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,149,975 members, 7,806,834 topics. Date: Wednesday, 24 April 2024 at 03:06 AM

How Can I Make My Form Interactive? - Webmasters - Nairaland

Nairaland Forum / Science/Technology / Webmasters / How Can I Make My Form Interactive? (4529 Views)

How Do I Create An Interactive Website / How Can I Make My Blog Appear On Top Google Search / Help! How Do I Make My Website Have Two Different Languages? (2) (3) (4)

(1) (2) (Reply) (Go Down)

How Can I Make My Form Interactive? by candiva2013(m): 11:44am On Dec 20, 2013
Dear Friends, I need your assistance. I am still a green horn in web design, but I have managed to design a site with a form. My problem is how to make the form more interactive. I want a situation were by if the visitor does not fill a particular field, the form won't sumit. The person will be notified that he has not filled the form completely. I use dreamweaver8. I need ur help on how to do this with dreamweaver 8.
Re: How Can I Make My Form Interactive? by Nobody: 12:04pm On Dec 20, 2013
what platform and language r u using?
Re: How Can I Make My Form Interactive? by Afam4eva(m): 12:09pm On Dec 20, 2013
Dreamweaver is just a platform. What scripting language do you use? PHP, JSP, ASP.net, pearl etc?
Re: How Can I Make My Form Interactive? by onyengbu: 12:31pm On Dec 20, 2013
if you add the attribute required="required" in your text, password, and textarea fields, most modern browsers will validate on the clientside asking the user to fill out the fields if they are empty.

However, this is just clientside and can be spooked. Again, it doesnt ensure that the kind of input you want is only the one submitted from that field. To acheive all of the above, you must need a server side validation.
Re: How Can I Make My Form Interactive? by candiva2013(m): 12:33pm On Dec 20, 2013
Afam4eva: Dreamweaver is just a platform. What scripting language do you use? PHP, JSP, ASP.net, pearl etc?
thanks. Am using php
Re: How Can I Make My Form Interactive? by candiva2013(m): 12:35pm On Dec 20, 2013
rutchiekens: what platform and language r u using?
am using dreamweaver as th platform and PHP is the lang. Am using.
Re: How Can I Make My Form Interactive? by Nobody: 1:06pm On Dec 20, 2013
candiva2013: am using dreamweaver as th platform and PHP is the lang. Am using.

Then you have not completed your php lessons

I'm also a learner But you need to know PHP/MySql to be able to pull this off. U need a server to store the user's data and create a file(example.php), which would collect the user's info.

I can give u d code but what's d point when like me, u barely understand Php.

Pls note: it mainly needs PHP and Mysql to achieve but it might also need Php and MySql and Ajax
Re: How Can I Make My Form Interactive? by candiva2013(m): 2:16pm On Dec 20, 2013
rutchiekens:

Then you have not completed your php lessons

I'm also a learner But you need to know PHP/MySql to be able to pull this off. U need a server to store the user's data and create a file(example.php), which would collect the user's info.

I can give u d code but what's d point when like me, u barely understand Php.

Pls note: it mainly needs PHP and Mysql to achieve but it might also need Php and MySql and Ajax
I want you to note that the form has been connected to the database. It is fully functional ie. It recieves data and stores same in the datdbase, my only problem is that i want the form to inform the user when it is not properly filled.
Re: How Can I Make My Form Interactive? by onyengbu: 2:43pm On Dec 20, 2013
candiva2013: I want you to note that the form has been connected to the database. It is fully functional ie. It recieves data and stores same in the datdbase, my only problem is that i want the form to inform the user when it is not properly filled.

Properly filled?
As in how?
What are the values to be filled in the form and what exactly do you want your users to submit...
Re: How Can I Make My Form Interactive? by Afam4eva(m): 2:53pm On Dec 20, 2013
Let's assume you have a form with one input called first_name.

<form method="post" action="process.php">
<input type="text" name="first_name" /> /* This is where members will input their first name */
<input type="submit" name="submit value="submit /> /* This is where members will input their first name */
</form>


This is what you'll have to do to validate it in the server side. I think it's easier to create a seperate page for processing the form. We're assuming this page is "process.php"

<?php
if(isset($_POST['submit']))
{
$first_name=$_POST['first_name'];

if(empty($first_name))
{
echo "Pls enter your first name" /* This displays when nothing is entered into the first name input */

/* This displays the form again */
echo '
<form method="post" action="process.php">
<input type="text" name="first_name" />
<input type="submit" name="submit value="submit />
</form>';
}
}
?>
Re: How Can I Make My Form Interactive? by candiva2013(m): 4:28pm On Dec 20, 2013
Afam4eva: Let's assume you have a form with one input called first_name.

<form method="post" action="process.php">
<input type="text" name="first_name" /> /* This is where members will input their first name */
<input type="submit" name="submit value="submit /> /* This is where members will input their first name */
</form>


This is what you'll have to do to validate it in the server side. I think it's easier to create a seperate page for processing the form. We're assuming this page is "process.php"

<?php
if(isset($_POST['submit']))
{
$first_name=$_POST['first_name'];

if(empty($first_name))
{
echo "Pls enter your first name" /* This displays when nothing is entered into the first name input */

/* This displays the form again */
echo '
<form method="post" action="process.php">
<input type="text" name="first_name" />
<input type="submit" name="submit value="submit />
</form>';
}
}
?>


thank you brother. You have been of great help. Please, do u know any good web hosting site where i can host mine. Can I ur email address?
Re: How Can I Make My Form Interactive? by candiva2013(m): 6:39pm On Dec 20, 2013
Thanks bro. But I'd love it if there's a simpler way to do this cos am a learner n am not gud at using the code view.
Re: How Can I Make My Form Interactive? by Nobody: 7:34pm On Dec 20, 2013
candiva2013: Thanks bro. But I'd love it if there's a simpler way to do this cos am a learner n am not gud at using the code view.

Err!!! what simpler way No simpler way in coding!!! by the way, what tutorial are you learning Php from?
Re: How Can I Make My Form Interactive? by Afam4eva(m): 8:10pm On Dec 20, 2013
candiva2013: thank you brother. You have been of great help. Please, do u know any good web hosting site where i can host mine. Can I ur email address?
Send me an email via info@internetvisa.net
Re: How Can I Make My Form Interactive? by yofak: 8:14pm On Dec 20, 2013
You can host your website with us, affordable plans
www.ayishost.com
Re: How Can I Make My Form Interactive? by Nobody: 9:19pm On Dec 20, 2013
if u wanna host you can go here(they are Nigerian host providers):

www.whogohost.com

www.web4africa.net


Nigerian hosting company are not encouraging, because most of the design on the hosting provider websites are ugly, not well designed and crafted which make it look shady, poor user interface, they didn't take the time to design their sites. but most of them are cheap
Re: How Can I Make My Form Interactive? by onyengbu: 7:12am On Dec 21, 2013
rutchiekens: if u wanna host you can go here(they are Nigerian host providers):

www.whogohost.com

www.web4africa.net


Nigerian hosting company are not encouraging, because most of the design on the hosting provider websites are ugly, not well designed and crafted which make it look shady, poor user interface, they didn't take the time to design their sites. but most of them are cheap
i thought he should be worried about their hosting efficiency rather than their site design...
Re: How Can I Make My Form Interactive? by Nobody: 9:55am On Dec 21, 2013
onye_ngbu*:
i thought he should be worried about their hosting efficiency rather than their site design...

Err!!! Hosting efficiency with naija's epileptic power supply, I use a foreign host provider, I can't use naija providers because of the power situation in d country
Re: How Can I Make My Form Interactive? by Gabrielsylar(m): 1:41pm On Dec 21, 2013
Download jquery validation and use nahhhh
Re: How Can I Make My Form Interactive? by Guykhena(m): 1:45pm On Dec 21, 2013
.....
Re: How Can I Make My Form Interactive? by Nobody: 1:49pm On Dec 21, 2013
simple HTML5 will do the job
Re: How Can I Make My Form Interactive? by baskettmouth: 1:56pm On Dec 21, 2013
undecidedOMG! See as all this code(s) they make my head spin, gussh, i nid to go back to computer skull.:-(
Re: How Can I Make My Form Interactive? by Nobody: 1:56pm On Dec 21, 2013
Please, where did you guys learn all this php, oracle, mysql from? Although I learnt a little about font page and Html during my secondary school days
Re: How Can I Make My Form Interactive? by AbuMikey(m): 1:58pm On Dec 21, 2013
Re: How Can I Make My Form Interactive? by ezeuba(m): 2:00pm On Dec 21, 2013
Just use JavaScript validation and save yourself headache.
Re: How Can I Make My Form Interactive? by Nobody: 2:08pm On Dec 21, 2013
candiva2013: Thanks bro. But I'd love it if there's a simpler way to do this cos am a learner n am not gud at using the code view.
you can do it in design view. I don't know the name of that panel that is at the bottom of the screen in dreamweaver that is collapsible. You can do it from there, if a user is filling the form and omits a text field, the form will refuse to send and indicate those field with red. If you know that panel just experiment and you will see it.
Re: How Can I Make My Form Interactive? by ibietela2(m): 2:10pm On Dec 21, 2013
Re: How Can I Make My Form Interactive? by dorange(m): 2:20pm On Dec 21, 2013
@op...it's pretty simple.....first click on the form u want to validate then click on tags(not sure if it's tags but d last menu on d right hand side of d the dreamweaver screen then click on + sign then u will see a list of stuffs...validate form will be dere click on it nd from dere on am sure u will get d rest by urself.....if u dnt understand wat i mean..just click on help then click on getting started with dreamweaver then type *validate form* in the search field.....u will get more explanation there..would av explained better but my pc under serious malware attacks....trying to fix it back.....if you need more help....whatsapp me @0818543877
Re: How Can I Make My Form Interactive? by Nobody: 2:37pm On Dec 21, 2013
Javascript would make your life easier with form validation.
Re: How Can I Make My Form Interactive? by Nobody: 2:47pm On Dec 21, 2013
ezeuba: Just use JavaScript validation and save yourself headache.

Op listen to this man.
Re: How Can I Make My Form Interactive? by onyengbu: 3:58pm On Dec 21, 2013
rutchiekens:

Err!!! Hosting efficiency with naija's epileptic power supply, I use a foreign host provider, I can't use naija providers because of the power situation in d country
... why then are you talking about the site design?
Power supply?... i give up!

(1) (2) (Reply)

Latest 9mobile Unlimited Free Browsing Cheat For August/september 2017 Is Back A / How To Create Pages And Menu Tabs On Blogger. / Website Design Proposal

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 38
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.