Hi there
I am trying to make a very simple form validation function. I currently have the following
function formValidate($field, $msg) {
if (empty($_POST['$field'])) {
$errors[] = $msg;
} else {
$field = mysqli_real_escape_string($dbc, trim($_POST['$field']));
}
}// end of function
formValidate('form', 'You forgot to enter the form');
When I run the script and enter nothing into the $_POST['form'] field it still executes an empty record into the database.
What am I doing wrong?
Mail functionality from localhost to server
Hi I am facing problem of mail functionality.When i tested mail functionality in my localhost it works fine but when i tried it on server it didn't work and also no error it displays.So please give me
if statements problems
Hi. I'm trying to make a web form, but I kind of hit a dead end trying to figure out why it doesn't work. Basically, I'm trying to read from a file and then populate the form according to the file.The
Code error with Index.php
Error: Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/runevid/public_html/index.php on line 25<html><head><title>CrazyQuest -
Why is the logic of this simple code not working?
Hey, I'm trying to determine if a table already exists in mysql, but doing a query first with mysql_query, then checking $sql as if it a were TRUE of FALSE. Which I though it would be. My Code
insert PHP code into function
Hi,I'm having problems when trying following:I have:Code: [Select]createBar("Download: <b>$kwd</b><Br />", "100%")and I'm trying to
Buggy registration system
Hey, I just started scripting in PHP, and I ran into a few problems.Code: <?phpinclude('config.php');if
Filtering an Array Based on Value
I have a very simple script set up that pulls data from a database and is output using this code:Code: Print "<table border cellpadding=3>";Print
Greek characters in php
Hi,I'm making a script and I m using for first time greek characters.I started to write a simple drop down menu that loads some city names from the database. The names are in Greek in the database and
Auto-populating dropdowns and multiple forms.
Here's what I have so far:First drop down = select a state (works)This populates the second drop down (works)Second drop down = select a city (works)This populates the third drop down with local
php mailer
How can i send a mail to large no, say 50,000 reciepients using [color=#0000FF]php mailer[/color]