473,785 Members | 2,419 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Limiting the language in a text box to english only

Hi
I've posted this message couple of days ago, but I can't find it now,
so sorry if you see it twice...

Anyways - I have a text box, and I want my users to be able to write
only in english inside it. I want to prevent the Alt+Shift option of
switching to other languages.

Thanks alot - Oren
Jul 23 '05 #1
18 5464
or*********@hot mail.com (OrenFlekser) wrote:
Hi
I've posted this message couple of days ago, but I can't find it now,
so sorry if you see it twice...

Anyways - I have a text box, and I want my users to be able to write
only in english inside it. I want to prevent the Alt+Shift option of
switching to other languages.


Here's the entire set of messages telling you that you can't do this:

http://groups.google.com/groups?selm...ing.google.com

Oh--besides everything already written, what makes you think everyone
who sees your page has his machine configured to use English in the
first place?

--
Harlan Messinger
Remove the first dot from my e-mail address.
Veuillez ôter le premier point de mon adresse de courriel.
Jul 23 '05 #2
On 7 Nov 2004 07:00:25 -0800, or*********@hot mail.com (OrenFlekser)
wrote:
Anyways - I have a text box, and I want my users to be able to write
only in english inside it.


How are you suggesting to stop my fingertips from typing any random
sequence of letters in a text box?

Some of those character sequences might just possibly end up being words
in e.g. Swedish while some other sequences might look suspiciously much
like words in English?

Either you need to rephrase your question to make it understandable, or
you need to stop and think for a minute.

--
Rex (who posts in English from a PC configured to Swedish)
Jul 23 '05 #3
DU
Jan Roland Eriksson wrote:
On 7 Nov 2004 07:00:25 -0800, or*********@hot mail.com (OrenFlekser)
wrote:

Anyways - I have a text box, and I want my users to be able to write
only in english inside it.

How are you suggesting to stop my fingertips from typing any random
sequence of letters in a text box?


Maybe with an onkeyup event handler checking if the character typed is
listed in the english character set. If not, then cancelling the event.

Also,

http://www.w3.org/TR/html4/interact/...accept-charset
Some of those character sequences might just possibly end up being words
in e.g. Swedish while some other sequences might look suspiciously much
like words in English?

Either you need to rephrase your question to make it understandable, or
you need to stop and think for a minute.

I think his question was understandable. Like many many posts in
newsgroups, his post lacked webpage context, webpage analysis,
explanations, descriptions as to why he wants to do this and why/how he
ended up with such solution.

DU
--
The site said to use Internet Explorer 5 or better... so I switched to
Mozilla 1.7.3 :)
Jul 23 '05 #4
or*********@hot mail.com (OrenFlekser) wrote in
news:c1******** *************** ***@posting.goo gle.com:
Hi
I've posted this message couple of days ago, but I can't find it now,
so sorry if you see it twice...

Anyways - I have a text box, and I want my users to be able to write
only in english inside it. I want to prevent the Alt+Shift option of
switching to other languages.

Thanks alot - Oren


Sorry for your getting bombarded with phony answers from the other people
on the newsgroup. There is a way to achieve this, with a simple (but
rather difficult) step-by-step process.

You need to spectrally manipulate your text box so that it rejects all
typing that is possessed by an aura of malice. This is the easy part.
The hard part is defining non-English text as that which contains an aura
of malice.

The defining is the difficult part. In order to do so, you must first
put your page on the Web, at whatever location it will be in the future.
(The address and contents of the file must _not_ change.) Then, you need
to type into the text box a representative sample of twenty-six English
words, each beginning with a different letter. Then you must copy the
text you have just typed and repaste it into the text box twenty-six
times, but between each pasting, you must type a letter of the QWERTY
keyboard, starting at Q and finishing at M, from left to right. Each
time you paste the text, you must say the letters of the alphabet
backwards, quickly! (This is the hard part.) If you are too slow, in
reciting backwards, the whole procedure might not work. When the Twenty-
Six Pastings are complete, submit the form by double-clicking.

In the submission process, the words of the form will transform into the
works of Shakespeare. You will not see this, because they get
transformed in their transmission to the server (a target script is not
necessary). The server will not see this either, unless it has a perfect
number of transistors that is prime.

Now that you have successfully defined the English langauge as non-
malicious (as shown by the miraculous transformation into the works of
Shakespeare), the form will automatically consider non-English text as
malicious. Now, all you need to do is tell the form to reject malicious
text. Do this by adding the minimized, WC3-approved attribute,
"raboof," as shown below.

<input type="text" name="whatever" raboof>

or do the same with a textarea.

This must be done after the pasting procedure, and note that this only
works with HTML. The WC3 does not recommend use of the raboof attribute
with XHTML, as the use of raboof="raboof" has not been thoroughly tested.
There are some reports of success with raboof="", though. Some people
suggest using raboof=" ", and some even advocate using two spaces.

Once you've set this up, people who type in non-English will receive a
small shock to their fingers and a popup alert message. The shock only
works with Thinkpads and Microsoft keyboards, though.

Note that in defining the English language's aura, you also define the
aura of the keyboard layout. In order to allow Dvorak layout users to
type, you need to repeat the process of pasting with the Dvorak layout,
going from P to Z.

Good luck with this. Be careful about getting the right order in your
recitation of the alphabet; otherwise your computer might crash (but it
will restart fine. The crash is just annoying). Also, be careful about
your representative sample of words. A friend of mine from Providence
told me that his form would only accept French, after he had used words
like Garage for G and Quiche for Q.
Jul 23 '05 #5
Sam Hughes wrote:
In the submission process, the words of the form will transform into the
works of Shakespeare. You will not see this, because they get
transformed in their transmission to the server (a target script is not
necessary). The server will not see this either, unless it has a perfect
number of transistors that is prime.


Apart from 2, all primes are odd numbers. From this page:

http://www-gap.dcs.st-and.ac.uk/~his...t_numbers.html

we read that:

"we know that an odd perfect number would have to have at least eight
distinct prime factors, and at least 29 prime factors which are not
necessarily distinct. It is also known that such a number would have
more than 300 digits and a prime divisor greater than 106. The problem
of whether an odd perfect number exists, however, remains unsolved."

....so there's no such thing as a perfect prime. This fact has to call
into question the validity of the rest of the information in your post.

--
Mark.
http://tranchant.plus.com/
Jul 23 '05 #6
Mark Tranchant <ma**@tranchant .plus.com> wrote in
news:41******** *************** @ptn-nntp-reader02.plus.n et:
Sam Hughes wrote:
In the submission process, the words of the form will transform into
the works of Shakespeare. You will not see this, because they get
transformed in their transmission to the server (a target script is
not necessary). The server will not see this either, unless it has a
perfect number of transistors that is prime.


Apart from 2, all primes are odd numbers. From this page:

http://www-gap.dcs.st-and.ac.uk/~his...ct_numbers.htm
l

we read that:

"we know that an odd perfect number would have to have at least eight
distinct prime factors, and at least 29 prime factors which are not
necessarily distinct. It is also known that such a number would have
more than 300 digits and a prime divisor greater than 106. The problem
of whether an odd perfect number exists, however, remains unsolved."

...so there's no such thing as a perfect prime. This fact has to call
into question the validity of the rest of the information in your
post.


I think the question of there being a perfect prime has a more obvious
explanation than that. A perfect number is one for which the sum of its
proper factors equals itself. Every prime has only one proper factor, the
number one, and because all primes are not equal to one, none are perfect
-- they are as far from perfect as a whole number can be.

The fact that no servers can see the transformed text does not mean the
rest of the information is false. How you decided upon that, I have no
idea. When the procedure is correctly carried out, this method works. I
guarantee this. If you do not believe me, try it yourself.
Jul 23 '05 #7
or*********@hot mail.com (OrenFlekser) wrote in message news:<c1******* *************** ****@posting.go ogle.com>...
Anyways - I have a text box, and I want my users to be able to write
only in english inside it. I want to prevent the Alt+Shift option of
switching to other languages.


I'm unaware of an "Alt+Shift" option to "switch languages" -- what
browser and platform has this?

Do you wish your site to require *correct* English (for instance,
rejecting "english" if typed without a capital "E")? Should the site
consider "rendezvous " to be English or French?

--
Dan
Jul 23 '05 #8
da*@tobias.name (Daniel R. Tobias) wrote in
news:aa******** *************** **@posting.goog le.com:
or*********@hot mail.com (OrenFlekser) wrote in message
news:<c1******* *************** ****@posting.go ogle.com>...
Anyways - I have a text box, and I want my users to be able to write
only in english inside it. I want to prevent the Alt+Shift option of
switching to other languages.


I'm unaware of an "Alt+Shift" option to "switch languages" -- what
browser and platform has this?


XP Windows. I use it to switch keyboard layouts, or I try to, except that
it randomly fails to work (with randomly meaning ALWAYS). It says it
should work, at least.
Jul 23 '05 #9
On 9 Nov 2004 15:32:14 GMT, Sam Hughes <hu****@rpi.edu > wrote:

....
You need to spectrally manipulate your text box so that it rejects all
typing that is possessed by an aura of malice. This is the easy part.
The hard part is defining non-English text as that which contains an aura
of malice.

....

Message / Keep :-)

--
Stephen Poley

http://www.xs4all.nl/~sbpoley/webmatters/
Jul 23 '05 #10

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

Similar topics

5
3294
by: Gustaf Liljegren | last post by:
In IE (at least from version 5), you can change your prefered language, so that for example the Windows Update page appears in another language than the system default. Here's the process: Tools -> Internet Options -> Languages -> Add (choose language from list) -> Move Up (move language to top of list)
3
6619
by: Lian Liming | last post by:
Hi, The language in my web site may be Simplified Chinese or English. I want to define different styles for each language. For each language, the http header is different. <meta name="language" content="en" /> means the language is english <meta name="language" content="zh" /> means the language is Simplified Chinese. Then I use a css selector to define different style for each language. My css code is
2
359
by: OM | last post by:
Hi, I have a simple Access application, for recording fuel use, and generating a few reports. It is necessary that the forms (such as the menu, and data entry forms) be in Thai as well as English. There are 4 ways that I have imagined how to do this, but I'm not sure which are practical, or easiest etc. 1. I was considering just adding the Tai to the existing labels and
6
3119
by: Michelle Stone | last post by:
Hi I am doing a bilingual .NET application for English/Arabic. On a web form, I have some edit boxes for data entry in Arabic and some for entry in English. Right now the user has to change his keyboard language by pressing ALT+SHIFT (or by changing the language manually elsewhere) each time he wants to shift from one language to another.
0
1275
by: marcus | last post by:
I am developing a web site at work that needs to be both in French and English. I have been reading up on using resource files (.resx files) in combination with setting the CultureInfo to either "en-CA" (Canadian English) or "fr" (French), then retrieving the appropriate variables from the resx file with a ResourceManager depending on the current Culture. That seems straightforwrad enough. Whenever I want a label or any other control that...
2
1790
by: saravanan.arul | last post by:
Hi this sarav... I having some languages in dropdownlist(like english,tamil,japan.......) based on this dropdown selection full application need to change corresponding language.. Anyone give solution for this
2
1816
by: erag | last post by:
Hi im newbie to java, and i want to set the language change according to main page..how to create it? here is my coding: main page: import org.eclipse.swt.SWT; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.Label;
0
1883
by: sivamedia | last post by:
hai to all I want to Translate the given English Text into some other language for Example English - French, English - Hindi etc. i found that 1)we have to enter the database of each and every words and sentenses in required language in XML file and then we compare english text with the other coressponding language and get it
3
1831
by: Alex | last post by:
Hi, We're working on what will become a multi-language application, and I wanted to see if this idea is feasable. What we're thinking of doing is creating a table to contain all text of the application and in multiple languages, for example: Col1 - ID Col2 - English Col3 - French
0
9480
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
10091
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9950
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7499
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6740
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5381
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5511
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3646
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2879
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.