/    Sign up×
Community /Pin to ProfileBookmark

Text recognition

I want to create some script that recognises some text entered, adn them directs them to a certain page.

Eg. 1

I enter “1234” into a text field, the code then looks at the text and thinks “34”, this means send the user to 34.html

Eg. 2

I enter “I like pie” into a text field and then code thinks “pie” – and sends the user to eat.html

Any idea’s?

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@96turnerriFeb 01.2004 — well you would need an array of each page that it can redirect you to

eg

Array('eat.htm', '34.htm', 69.htm', 'die.htm');

and an array of words that would redirect to each

Array('pie', '34', '69', 'guns');
×

Success!

Help @ianripping spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.19,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...