earthdance Posted April 1, 2006 Posted April 1, 2006 Hello, I have this regular expressions (thanks to jo0ls for providing it) ([A-Za-z0-9']+)|([^A-Za-z0-9']+) But I would like to add the functionality to also detect in the first class words that have a number attached to them, for example 9word word9word word6 ... The first cass DOES this but it will also detect numbers that are all by themselves without a word attached... and this is what I am trying to avoid.. any ideas? e.g: word -> matches first class word9 -> matches first class 9word9 -> matches first class wo9rd -> matches first class 8 -> matches second class 10 -> matches second class any other char -> matches second class Quote
mark007 Posted April 2, 2006 Posted April 2, 2006 This will do the first bit I think: [a-zA-Z0-9']*[a-zA-Z]+[a-zA-Z0-9']* :) Quote Please check the Knowledge Base before you post. "Computers are useless. They can only give you answers." - Pablo Picasso The Code Net
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.