Reply
php html form please help
Old 09-22-2006, 06:22 PM Re: php html form please help
millwalll's Avatar
Webmaster Talker

Posts: 554
Name: James
Location: KENT
hi i will try that do i copy all that and save that as scub.php

also what you mean define $body

Last edited by millwalll : 09-22-2006 at 06:42 PM.
millwalll is offline
Reply With Quote
View Public Profile Visit millwalll's homepage!
 
Old 09-23-2006, 12:58 AM Re: php html form please help
jito's Avatar
MY LIFE IS 'i' LIFE

Posts: 551
Name: surajit ray
Location: inside the heart of my friends
find out where is the problem:
PHP Code:
mysql_connect (DB_HOST DB_USERDB_PASSWORD) or die("Connection Err:".mysql_error());
mysql_select_db (DB_NAME)  or die("DB Selection Err:".mysql_error()); 
__________________
Think+, work +, but not HIV + :)
jito is offline
Reply With Quote
View Public Profile
 
Old 09-24-2006, 10:06 AM Re: php html form please help
millwalll's Avatar
Webmaster Talker

Posts: 554
Name: James
Location: KENT
done that this hat i get

DB Selection Err:Access denied for user 'ekcab'@'localhost' to database 'usertable'
millwalll is offline
Reply With Quote
View Public Profile Visit millwalll's homepage!
 
Old 09-25-2006, 01:05 AM Re: php html form please help
jito's Avatar
MY LIFE IS 'i' LIFE

Posts: 551
Name: surajit ray
Location: inside the heart of my friends
that means you don't have access to that database. replace current username password with the correct one.
__________________
Think+, work +, but not HIV + :)
jito is offline
Reply With Quote
View Public Profile
 
Old 09-25-2006, 04:41 AM Re: php html form please help
millwalll's Avatar
Webmaster Talker

Posts: 554
Name: James
Location: KENT
posted by mistake opss
Attached Images
File Type: jpg one.jpg (54.6 KB, 9 views)

Last edited by millwalll : 09-25-2006 at 06:35 AM.
millwalll is offline
Reply With Quote
View Public Profile Visit millwalll's homepage!
 
Old 09-25-2006, 06:34 AM Re: php html form please help
millwalll's Avatar
Webmaster Talker

Posts: 554
Name: James
Location: KENT
ok i gone onto cpanel creat and new user called ekcab and a new password this is the code i have
<?
define ('DB_USER', 'ekcab');
define ('DB_PASSWORD', '*****');
define ('DB_HOST', 'localhost');
define ('DB_NAME', 'ekcab_usertable');

$adb = mysql_connect (DB_HOST , DB_USER, DB_PASSWORD) or die("Connection Err:".mysql_error());
mysql_select_db (DB_NAME) or die("DB Selection Err:".mysql_error());

$fullname = $_POST["textfield"];
$email = $_POST["textfield2"];
$sql = "INSERT INTO ekcab_usertable (fullname, email) VALUES ('$fullname', '$email')";
mysql_query($sql);
?>
and i get this

Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'ekcab'@'localhost' (using password: YES) in /home/ekcab/public_html/scub.php on line 16
Connection Err:Access denied for user 'ekcab'@'localhost' (using password: YES)
millwalll is offline
Reply With Quote
View Public Profile Visit millwalll's homepage!
 
Old 09-25-2006, 09:07 AM Re: php html form please help
Ultra Talker

Posts: 253
Location: Auckland, New Zealand
Why use constants it can cause more problems than what it's worth, you must always check they are not defined, since you can't redefine a constant.

Anyways, from your screenshot your username was ekcab_info not ekcab.

Cheers,

MC
__________________
#------------------------------signature---------------------------------------------------------------------------------#
Quote:
I am well recognised for what I don't do than what I do. Chores are just one of those things.
mastercomputers is offline
Reply With Quote
View Public Profile Visit mastercomputers's homepage!
 
Old 09-25-2006, 09:16 AM Re: php html form please help
millwalll's Avatar
Webmaster Talker

Posts: 554
Name: James
Location: KENT
yeah i know i changed it it jsu anoying me as i cant finish rest site off with out knowing this wont work
millwalll is offline
Reply With Quote
View Public Profile Visit millwalll's homepage!
 
Old 09-25-2006, 01:33 PM Re: php html form please help
mad_willsy's Avatar
Super Spam Talker

Posts: 774
Name: Will Craig
Location: Cheltenham, Gloucestershire, UK
You havent added user to the database. As long as that screen hasn't changed all you need to do is add user to database!
__________________
Wont :P
SoldierExteme.com - Free MMORPG - sign-up today!
Backthebulls.com - Free online games
mad_willsy is offline
Reply With Quote
View Public Profile Visit mad_willsy's homepage!
 
Old 09-25-2006, 02:03 PM Re: php html form please help
millwalll's Avatar
Webmaster Talker

Posts: 554
Name: James
Location: KENT
hi mad what you mean im not very good with php have small knolage of it
millwalll is offline
Reply With Quote
View Public Profile Visit millwalll's homepage!
 
Old 09-30-2006, 01:42 PM Re: php html form please help
mad_willsy's Avatar
Super Spam Talker

Posts: 774
Name: Will Craig
Location: Cheltenham, Gloucestershire, UK
Click the button circled in screenshot.
Attached Images
File Type: gif screenshot.gif (23.7 KB, 8 views)
__________________
Wont :P
SoldierExteme.com - Free MMORPG - sign-up today!
Backthebulls.com - Free online games
mad_willsy is offline
Reply With Quote
View Public Profile Visit mad_willsy's homepage!
 
Old 09-30-2006, 02:44 PM Re: php html form please help
millwalll's Avatar
Webmaster Talker

Posts: 554
Name: James
Location: KENT
yeha ive now done that mate it still dont want to work
millwalll is offline
Reply With Quote
View Public Profile Visit millwalll's homepage!
 
Old 10-01-2006, 08:41 AM Re: php html form please help
mad_willsy's Avatar
Super Spam Talker

Posts: 774
Name: Will Craig
Location: Cheltenham, Gloucestershire, UK
Follow this tutorial.

If you aquire some knowledge of php, you may be able to exp[lain your problem better.
__________________
Wont :P
SoldierExteme.com - Free MMORPG - sign-up today!
Backthebulls.com - Free online games
mad_willsy is offline
Reply With Quote
View Public Profile Visit mad_willsy's homepage!
 
Old 10-01-2006, 06:03 PM Re: php html form please help
millwalll's Avatar
Webmaster Talker

Posts: 554
Name: James
Location: KENT
i do have basic knolage of php the problem is it dont seem to want connect to the database and put the informaiton in
millwalll is offline
Reply With Quote
View Public Profile Visit millwalll's homepage!
 
Old 10-02-2006, 01:12 PM Re: php html form please help
mad_willsy's Avatar
Super Spam Talker

Posts: 774
Name: Will Craig
Location: Cheltenham, Gloucestershire, UK
Try this and tell me what you get.
PHP Code:
<?php
$link 
mysql_connect('localhost''mysql_user''mysql_password');
if (!
$link) {
   die(
'Could not connect: ' mysql_error());
}
echo 
'Connected successfully';
mysql_close($link);
?>
EDIT:
I think I've cracked your problem:

If above gets Could not connect: Access denied for user 'ekcab'@'66.118.142.108' (using password: YES) in /home/ekcab/public_html/scub.php on line 19

Use the username ecab_info not ekcab.
__________________
Wont :P
SoldierExteme.com - Free MMORPG - sign-up today!
Backthebulls.com - Free online games

Last edited by mad_willsy : 10-02-2006 at 01:21 PM.
mad_willsy is offline
Reply With Quote
View Public Profile Visit mad_willsy's homepage!
 
Old 10-03-2006, 09:05 AM Re: php html form please help
millwalll's Avatar
Webmaster Talker

Posts: 554
Name: James
Location: KENT
BEFORE I TRY THAT THIS IS THE LATEST CODE I HAVE AND THE LATEST ERROR I HAVE AS WHERE IVE BEEN MESSING ABOUT IVE CHANGED USERNAME AND PASSWORD SO ON


<?PHP

$dbh=mysql_connect ("localhost", "eKcab_admin", "<PASSWORD IS HERE>") or die ('I cannot connect to the database because: ' . mysql_error());
mysql_select_db ("ekcab_usertable");

$fullname = $_POST["textfield"];
$email = $_POST["textfield2"];
$sql = "INSERT INTO ekcab_usertable (fullname, email) VALUES ('$fullname', '$email')";
mysql_query($sql);
?>

Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'ekcab_admin'@'localhost' (using password: YES) in /home/ekcab/public_html/scub.php on line 12
I cannot connect to the database because: Access denied for user 'ekcab_admin'@'localhost' (using password: YES)
millwalll is offline
Reply With Quote
View Public Profile Visit millwalll's homepage!
 
Old 10-04-2006, 02:17 PM Re: php html form please help
mad_willsy's Avatar
Super Spam Talker

Posts: 774
Name: Will Craig
Location: Cheltenham, Gloucestershire, UK
Honestly mate, unless you have the passowrd wrong, the user IS NOT in the database or else you would not have that error. Adding a user does not make it have access to database - although if you had added it to mysql but not to databse you would be able to connect but not select db.

Secondly try using a free database like http://freesql.org/freesql/mysql just to prove my point that THE USER HAS NOT BEEN ADDED/OR THE PASSWORD IS WRONG!

Hope this helps!
__________________
Wont :P
SoldierExteme.com - Free MMORPG - sign-up today!
Backthebulls.com - Free online games
mad_willsy is offline
Reply With Quote
View Public Profile Visit mad_willsy's homepage!
 
Old 10-05-2006, 04:30 AM Re: php html form please help
millwalll's Avatar
Webmaster Talker

Posts: 554
Name: James
Location: KENT
if i gave u my log in details would u have a look at for me please as it kinder holding everythink up as this script on every page dont want do rest page and find i got change sumthink if so have u got msn so i can add u and that many thanks
millwalll is offline
Reply With Quote
View Public Profile Visit millwalll's homepage!
 
Old 10-05-2006, 01:24 PM Re: php html form please help
mad_willsy's Avatar
Super Spam Talker

Posts: 774
Name: Will Craig
Location: Cheltenham, Gloucestershire, UK
You can add me on msn if you like and i will help you from there. - mad_willsy@backthebulls.com

I will be on saturday and sunday from about 3AM GMT till 9PM GMT

EDIT:
Exactly what I said was wrong!

Talkupation please! :P
__________________
Wont :P
SoldierExteme.com - Free MMORPG - sign-up today!
Backthebulls.com - Free online games

Last edited by mad_willsy : 10-06-2006 at 01:43 PM.
mad_willsy is offline
Reply With Quote
View Public Profile Visit mad_willsy's homepage!
 
Reply     « Reply to php html form please help

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML