close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

restrict new users by username & IP address

Thread began 2/16/2010 9:40 am by ijk76319396 | Last modified 2/16/2010 3:09 pm by Jason Byrnes | 448 views | 1 replies |

ijk76319396

restrict new users by username & IP address

I have it so a user cannot register with a new user name, but I would also like to restrict it so that a user cannot register on the same computer with the same IP address. Is there a way to restrict both of these independently of each other?

Sign in to reply to this post

Jason ByrnesWebAssist

create two separate recordsets. one to filter the username column with the username that was entered, the other to filter the IP address column with the $_SERVER["REMOTE_ADDR"] variabel:
<?php echo((isset($_SERVER["REMOTE_ADDR"]))?$_SERVER["REMOTE_ADDR"]:"") ?>



for each recordset, a variable will be created containing the number of rows:
$totalRows_<Recordset Name>


use the Server Validation - number validation

you will need to create one for each the user name recordset, and the ip recordset, use the total rows variable for the server variable and set the minimum to -1 and maximum to 0.

this will cause validation to pass only if both recordsets are empty.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...