Error Message
Posted by: dlannetts (---.lnse3.ken.bigpond.net.au)
Date: January 31, 2010 07:33AM

Hello,

today l was building a register form and when l enter my details it opens my register.php and comes up with this error message:

Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''127.0.0.1','first name','last name','email','username','passowrd')' at line 3

Does anyone know why? Or what is even causing it to happen...

EDIT:~:Oh, l put Apache and MySQL on there latest versions and it now says: Error: No database selected on the register.php page, also, my wamp icon is white, shouldn't it be red or yellow?



Edited 1 time(s). Last edit at 01/31/2010 07:42AM by dlannetts.

Options: ReplyQuote
Re: Error Message
Posted by: stevenmartin99 (---.b-ras2.blp.dublin.eircom.net)
Date: January 31, 2010 09:30AM

it shud be white

your mysql connection code is wrong..

you need to fill in database name, host, user, password and table name in the mysql query

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: Error Message
Posted by: dlannetts (---.lnse3.ken.bigpond.net.au)
Date: January 31, 2010 09:44AM

mmm, no, l am pretty sure that is correct, but, do you remember how you fixed it steven when it got the white screens and all that on my pc? well ... it's doing that shit again... l am pretty sure we downloaded all the newest versions of php, mysql and apache, same thing again? Also, when l put new versions on can l delete or uninstall the older version, l can right???

Options: ReplyQuote
Re: Error Message
Posted by: c2dan (---.15-1.cable.virginmedia.com)
Date: January 31, 2010 01:13PM

The problem is to do with your code. WAMP is running fine.

Options: ReplyQuote
Re: Error Message
Posted by: yfastud (Moderator)
Date: January 31, 2010 05:10PM


Options: ReplyQuote
Re: Error Message
Posted by: dlannetts (---.lnse3.ken.bigpond.net.au)
Date: February 01, 2010 08:33AM

just reading my last post, if it sounded rude l didn't mean it to be this way, just l re-read it and l thought it sounded like l was being a smart ass. Thanks for the blog, l will read up on it, also, what is the code that goes at the bottom of the "config.inc.php" file that has the ip in it, something like 127.0.0.1, but there is something a bit before it l though, l just can't remember it, can anyone help me? It could help my white screen issue that seems to happen all the time, and at the worst times...

Options: ReplyQuote
Re: Error Message
Posted by: dlannetts (---.lnse3.ken.bigpond.net.au)
Date: February 01, 2010 10:38AM

Actually, should l have 127.0.0.1 somewhere in this file:

# Copyright (c) 1993-1999 Microsoft Corp.
#
# This is a sample LMHOSTS file used by the Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to computernames
# (NetBIOS) names. Each entry should be kept on an individual line.
# The IP address should be placed in the first column followed by the
# corresponding computername. The address and the computername
# should be separated by at least one space or tab. The "#" character
# is generally used to denote the start of a comment (see the exceptions
# below).
#
# This file is compatible with Microsoft LAN Manager 2.x TCP/IP lmhosts
# files and offers the following extensions:
#
# #PRE
# #DOM:<domain>
# #INCLUDE <filename>
# #BEGIN_ALTERNATE
# #END_ALTERNATE
# \0xnn (non-printing character support)
#
# Following any entry in the file with the characters "#PRE" will cause
# the entry to be preloaded into the name cache. By default, entries are
# not preloaded, but are parsed only after dynamic name resolution fails.
#
# Following an entry with the "#DOM:<domain>" tag will associate the
# entry with the domain specified by <domain>. This affects how the
# browser and logon services behave in TCP/IP environments. To preload
# the host name associated with #DOM entry, it is necessary to also add a
# #PRE to the line. The <domain> is always preloaded although it will not
# be shown when the name cache is viewed.
#
# Specifying "#INCLUDE <filename>" will force the RFC NetBIOS (NBT)
# software to seek the specified <filename> and parse it as if it were
# local. <filename> is generally a UNC-based name, allowing a
# centralized lmhosts file to be maintained on a server.
# It is ALWAYS necessary to provide a mapping for the IP address of the
# server prior to the #INCLUDE. This mapping must use the #PRE directive.
# In addtion the share "public" in the example below must be in the
# LanManServer list of "NullSessionShares" in order for client machines to
# be able to read the lmhosts file successfully. This key is under
# \machine\system\currentcontrolset\services\lanmanserver\parameters\nullsessionshares
# in the registry. Simply add "public" to the list found there.
#
# The #BEGIN_ and #END_ALTERNATE keywords allow multiple #INCLUDE
# statements to be grouped together. Any single successful include
# will cause the group to succeed.
#
# Finally, non-printing characters can be embedded in mappings by
# first surrounding the NetBIOS name in quotations, then using the
# \0xnn notation to specify a hex value for a non-printing character.
#
# The following example illustrates all of these extensions:
#
# 102.54.94.97 rhino #PRE #DOM:networking #net group's DC
# 102.54.94.102 "appname \0x14" #special app server
# 102.54.94.123 popular #PRE #source server
# 102.54.94.117 localsrv #PRE #needed for the include
#
# #BEGIN_ALTERNATE
# #INCLUDE \\localsrv\public\lmhosts
# #INCLUDE \\rhino\public\lmhosts
# #END_ALTERNATE
#
# In the above example, the "appname" server contains a special
# character in its name, the "popular" and "localsrv" server names are
# preloaded, and the "rhino" server name is specified so it can be used
# to later #INCLUDE a centrally maintained lmhosts file if the "localsrv"
# system is unavailable.
#
# Note that the whole file is parsed including comments on each lookup,
# so keeping the number of comments to a minimum will improve performance.
# Therefore it is not advisable to simply add lmhosts file entries onto the
# end of this file.

Options: ReplyQuote
Re: Error Message
Posted by: dlannetts (---.lnse3.ken.bigpond.net.au)
Date: February 01, 2010 11:49AM

Now my icon is red, shit this thing is worse than my girlfriend, very temperamental... Any ideas on fixing this thing now? l am new to this sort of program that tries to make life hard...

Options: ReplyQuote
Re: Error Message
Posted by: stevenmartin99 (---.b-ras2.blp.dublin.eircom.net)
Date: February 01, 2010 04:59PM

if ur on msn contact me

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: Error Message
Posted by: yfastud (Moderator)
Date: February 01, 2010 11:38PM

open file hosts in folder C:\WINDOWS\System32\drivers\etc and make sure you have only this line and nothing else

127.0.0.1 localhost

Have fun,

FREE One A Day
FREE Photo
FREE Games
FREE Websites
FREE Portable GPS
FREE WAMP Guides

Options: ReplyQuote
Re: Error Message
Posted by: dlannetts (---.lnse3.ken.bigpond.net.au)
Date: February 02, 2010 12:34PM

yep, l have done that yfastud. Thanks Steven, don't see you on much anymore but next time l do, l will be sure to give you a bell...

Options: ReplyQuote


Sorry, only registered users may post in this forum.