473,387 Members | 1,536 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

question about M. Lemos form script

Hello,

I'm creating registration service with this great form script for
creating forms within Smarty.

Question is how can I validate 'username' against allready registered
users in MySQL?

TNX!
Jul 17 '05 #1
1 1432
On Tue, 16 Mar 2004 16:58:16 +0100, dr zoidberg wrote:
Hello,

I'm creating registration service with this great form script for
creating forms within Smarty.

Question is how can I validate 'username' against allready registered
users in MySQL?

TNX!

why dont you compare username with the entries in the database?
something like this...

$res = mysql_query("SELECT * FROM table WHERE u_name LIKE $username");
if($mysql_num_rows()) $username_exists = 1;

if one row is returned, username already is registered.
hope i didnt misunderstood your problem.
(and sorry for the bad english, not my mother-language)

Robert
Jul 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Bosconian | last post by:
I'm looking for a free open source web site search engine. htdig looks like a good one that's well supported and used in the community. I've read over the feature list and documentation, but I'm...
1
by: diroddi | last post by:
How do you validate a SELECT field with m. lemos forms validation class. I want to make sure the user has selected a product and not left the field as the default of 'Select One'. ...
4
by: diroddi | last post by:
In reference to the Manual Lemos Form class, does anybody know if the class does anything to prevent SQL injection attacks or provide any kind of security by cleaning _POST variables? Also, does...
5
by: Westcoast Sheri | last post by:
Normally, if I want to know if someone viewed a particular page, I use the php's "mail()" function (because I check my email lots more than I check my weblogs :-) Now I want to know how get php...
7
by: Calan | last post by:
Mike, Your code on the dynamic input checking was excellent and very well explained. (The only thing I had to do was change the test for text input to be "1 > len of text", instead or "0 >...
10
by: Mark Winter | last post by:
Hello, I am wondering if someone could point me in the right direction to figure out how to create a dynamic form. I have been developing programs in perl and oracle and have recently switched...
2
by: Ronald Raygun | last post by:
I have a form, which contains a textfield for a user to enter their username. I want to provide a button that allows the user to check to see whether that username has already been taken up by...
3
by: SAM | last post by:
ll a écrit : <script type="text/javascript"> function checkform( f ) // f is the form to check { var txt1 = 'Please make a selection for the Learning Outcome :', txt2 = '\nYour...
22
by: Neil Gould | last post by:
Or... when is a script not a script? I have several modules for managing different aspects of our club's website, most of which are multi-page. Does setting such things as server.ScriptTimeout...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.