Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  • Users: slowfish
  • Order by date
  1. slowfish

    email validation

    could I send the code to you so you can take a look? many thanks for all your help
  2. slowfish

    email validation

    still doesn't work
  3. slowfish

    email validation

    Still can't get this to work... function checkemail(what) { return ! ( what == "" || /[!\"£$%\^&*()-+=<>,\'#?\\|¬`\/\[\]]/.test(what) || what.indexOf('.') == -1 || what.indexOf('@') == -1 || what.slice(what.lastIndexOf('.')+1,what.length).length < 2 ||...
  4. slowfish

    email validation

    Thanks feherke. What about if I have other fields in the form that I need to check for? Can I put these in the validate(form) function too?
  5. slowfish

    email validation

    Can you help as to how I would do this? tsuji - not sure I understand what you mean by "And you tolerate yourself to produce such thing?" Apologies all, quite new to javascript and the code I used was just copied after a google search. Thanks
  6. slowfish

    email validation

    Apologies, this is the actual code I'm using. Field names are different, both fields are in form "ff". if (document.ff.ref1email.value != "") { var str = new String(document.ff.ref1email.value); var isOK = true; rExp = /[!\"£$%\^&*()-+=<>,\'#?\\|¬`\/\[\]]/ if(...
  7. slowfish

    email validation

    Yes, there are two email fields in the same form (ff)
  8. slowfish

    email validation

    Here's the code. The first email field is ref1email and the second field is ref2email. If ref1email is not a valid email address the alert pops up. If ref1email address amended so correct, form submitted and passes through without any alert that ref2email is invalid. if...
  9. slowfish

    email validation

    Hi I have an email field in my form where javascript email validation works fine on submit. I've recently added another email field but some reason the email validation now doesn't work. Any ideas?
  10. slowfish

    CASE and JOINS

    Hi Is it possible to use CASE to work out which table to JOIN? Cheers
  11. slowfish

    this month followed by subsequent months

    $mon=$mon+1; $count=$mon+11; for ( $x=$mon; $x<=$count; $x++ ) { if ($x > 12) { $nextmonth = $x-12; } else { $nextmonth = $x; } Got there in the end. Thanks for all your help!
  12. slowfish

    this month followed by subsequent months

    Hi It's the "trick" that I'm after.... I have an array with full month names and am using a for loop.
  13. slowfish

    this month followed by subsequent months

    What's the easiest way of printing this month followed by all the subsequent months, so showing 12 months in total, i.e. - May 2010 June 2010 etc etc March 2011 April 2011
  14. slowfish

    COUNT WITH MULTIPLE JOINS

    Great thanks for that, it worked. Just had to replace the AND with WHERE. SELECT COUNT(*) AS howmany FROM taskvolsnew WHERE vol NOT IN ( SELECT volref FROM volunteers_types WHERE voltype = '4' )
  15. slowfish

    COUNT WITH MULTIPLE JOINS

    it's irrelevant how many types the vol is - whenever they are on task it should just be a count of one. need to exclude voltype 4 vols from the count for all tasks they have ever been on
  16. slowfish

    COUNT WITH MULTIPLE JOINS

    really appreciate the help rudy... "tasks" table has date of the task along with various other info (site, leader, tasktype, etc, etc) "taskvolsnew" table contains id's of all the vols that were on a particular task (multiple vols on a task) "volunteers_types" table contains the voltype id's...
  17. slowfish

    COUNT WITH MULTIPLE JOINS

    that just returns a count of zero
  18. slowfish

    COUNT WITH MULTIPLE JOINS

    It still doesn't return the correct count even if the join to the tasks table is taken out. A volunteer can be multiple "types", so for a volunteer that is not type '4' but is type 3, 6 and 9 for example it is counting them 3 times, rather than once.
  19. slowfish

    COUNT WITH MULTIPLE JOINS

    Thanks for that Rudy. It still doesn't return the correct count though, I think maybe something to do with the fact I'm also joining the tasks table.
  20. slowfish

    COUNT WITH MULTIPLE JOINS

    Hi I'm trying to count the total number of workdays for all volunteers that are not "Type 4" volunteers. A volunteer can be multiple types, hence I think why I'm getting a much larger count than expected. SELECT COUNT(taskvolsnew.vol) AS howmany FROM taskvolsnew LEFT JOIN tasks ON...

Part and Inventory Search

Back
Top