Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC:

VALIDATE ALPHANUMERIC UPPERCASE+LIMIT LENGTH 16 Oct 2012 23:07 #4603

  • JoomGuy
  • JoomGuy's Avatar Topic Author
  • Offline
  • Moderator
  • Moderator
  • Joomla Enthusiast, Lover of Cooking
  • Posts: 1115
  • Thank you received: 195
OK, say you want need an alphanumeric field for something like a product code, grab yourself a string datatype and add a regular expression similar to;
^[A-Z0-9]{2,10}$
In this particular example,
  1. [A-Z0-9] allows only UPPERCASE letters from A-Z OR numeric values between 0 and 9
  2. {2,10} length is restricted to a minimum of 2 and maximum of 10
Valid
  1. 12345ABCDE
  2. M12
  3. SHOES115
  4. F1DEF

Invalid
  1. 12345ABCDEF
  2. M
  3. 9
  4. f1def
Need help with your Cook/Joomla Project? . PM me to find out what I can help with. NO time wasters please!!!

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Time to create page: 0.097 seconds

This is what you call a component builder. I was able to master using this in a very short time and the resulting component works like a charm. Not just a basic component builder but a fully working component builder with forms fields tables all ready to go. You can make the list and item views to display in the front and back end. Also there is a great forum just starting to evolve and I'm sure this will grow very rapidly when you all realise how good this tool is.
Kevin (JED)

         

Get Started