close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

How to prevent spaces within text?

Thread began 2/11/2010 3:17 pm by Nathon Jones Web Design | Last modified 4/13/2010 12:40 pm by Eric Mittman | 1516 views | 3 replies |

Nathon Jones Web Design

How to prevent spaces within text?

I am trying to validate a form field that requests a username. I don't want the user to enter any spaces but I can't find anything in Validation Toolkit that checks for spaces within text, like in a name for example "Joe Bloggs".

Am I missing something? I've tried adding a space to the Restrict Content validation but this doesn't prevent entry of a name with a space in it.

Here's a link to a page where this is occuring:
movie-register.asp

I'd appreciate any advice. Thanks.

Regards
Nathon.

Sign in to reply to this post

Eric Mittman

I did some testing with this but it was in php. What I found was that the space character was not matching the list of not allowed in the function call.

In php I could get it to work by making the not allowed value  , I then had to add a string replace function around the value to replace any space with  . When I did this it would pick up the space properly and show the error message when it was present.

There should be an equivalent thing you can do in the asp code. Please post back with a copy of the page that has the validation applied to it along with your WA_ValidationToolkit folder in a zip archive. I will take a look to see if I can get it working this way for you.

Sign in to reply to this post

Nathon Jones Web Design

zip attached

Hi Eric,

Sorry, here is the zip file with the relevant files. I'd appreciate any advice you could offer, thank you.

Regards
Nath.

Attached Files
DontAllowSpacesProblem.zip
Sign in to reply to this post

Eric Mittman

I have opened a ticket for you on this issue. To check the status of your ticket or update it login and visit your support history.

supporthistory.php

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...