RE: strip .0 off off IPaddress

This WebDNA talk-list message is from

1999


It keeps the original formatting.
numero = 22167
interpreted = N
texte = >Can you post the code you're using? Your example IP number works fine for >me with the code that I posted earlier...Here it is: [math][GetCharsstart1end3][IPAddress][GetChars][math].[math][GetCharsstart=5&end =7][IPAddress][/GetChars][math].[math][GetCharsstart=9&end=11][IPAddress][/GetCh ars][math].[math][GetCharsstart=13&end=15][IPAddress][/GetChars][/math] Moosenaround >>I used this string as if it were the context [ipaddress] >>and it only returned the first number. >> >>The ip was 123.045.678.981 and >>after it only returned >>123. >> >>What am I missing? >> >>Happy New Year Ya'll!! >> >>Mooseman >> >> >>I'm not sure exactly what you are asking, but this technique should work >>>for all addresses. Basicly what it does is grab each 3-digit chunk with >>>[GetChars], and then [math] converts that string into a number, which has >>>the effect of removing any extraneous leading zeros. It won't remove any >>>zeros that are significant (i.e. non-leading) > > >o--------------- Dave MacLeay --+ >o----------- Digital Frontier --+ >o--------------- 802.253.8612 --+ >o--- dave@digitalfrontier.com --+ Associated Messages, from the most recent to the oldest:

    
  1. RE: strip .0 off off IPaddress (Olin Lagon 1998)
  2. RE: strip .0 off off IPaddress (The Mooseman 1999)
  3. RE: strip .0 off off IPaddress (Dave MacLeay 1999)
  4. RE: strip .0 off off IPaddress (The Mooseman 1998)
  5. RE: strip .0 off off IPaddress (Dave MacLeay 1999)
  6. Re: strip .0 off off IPaddress (Kenneth Grome 1998)
  7. RE: strip .0 off off IPaddress (Olin Lagon 1998)
  8. Re: strip .0 off off IPaddress (Dave MacLeay 1998)
>Can you post the code you're using? Your example IP number works fine for >me with the code that I posted earlier...Here it is: [math][GetCharsstart1end3][ipaddress][getchars][math].[math][GetCharsstart=5&end =7][ipaddress][/GetChars][math].[math][GetCharsstart=9&end=11][ipaddress][/GetCh ars][math].[math][GetCharsstart=13&end=15][ipaddress][/GetChars][/math] Moosenaround >>I used this string as if it were the context [ipaddress] >>and it only returned the first number. >> >>The ip was 123.045.678.981 and >>after it only returned >>123. >> >>What am I missing? >> >>Happy New Year Ya'll!! >> >>Mooseman >> >> >>I'm not sure exactly what you are asking, but this technique should work >>>for all addresses. Basicly what it does is grab each 3-digit chunk with >>>[getchars], and then [math] converts that string into a number, which has >>>the effect of removing any extraneous leading zeros. It won't remove any >>>zeros that are significant (i.e. non-leading) > > >o--------------- Dave MacLeay --+ >o----------- Digital Frontier --+ >o--------------- 802.253.8612 --+ >o--- dave@digitalfrontier.com --+ The Mooseman

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

Understanding texta (1997) syntax question, not in online refernce (1997) WebCat2b13MacPlugIn - [include] (1997) Occasional crashes with $remove (1997) problems with 2 tags (1997) Not possible to unsubscribe (2007) Transfering [text] variables (2000) rnsearch on date (2003) RE: Questions To Answer (1997) authenticate and password (1998) WebMerchant & CC Response (2002) Emailer port change (1997) Creating PDF (2004) I'm tired of all this! (2000) WebCat2.0b15-to many nested [xx] tags (1997) Multi Colonns (1998) PSC recommends what date format yr 2000??? (1997) Unexpected error (1997) Emailer program? (2000) webcat NT (1998)