Solved

Break down the URL from request.ServerVariables("URL")

Posted on 2013-02-06
3
437 Views
Last Modified: 2013-02-06
Hello All;
As the title suggest, I need to break down the URL.

Lets say this is the URL

domain.com/something/else/50/page.asp

Now, I need to break down the URL, and get the /50/ from the string.
Any idea's on this one?

Thanks All
Carrzkiss
0
Comment
Question by:Wayne Barron
  • 2
3 Comments
 
LVL 52

Accepted Solution

by:
Scott Fell,  EE MVE earned 500 total points
ID: 38862795
<%
page = Request.ServerVariables("url")
arrPage=split(page,"/")
response.write arrPage(0)&"<br>"
response.write arrPage(1)&"<br>"
response.write arrPage(2)&"<br>"
response.write arrPage(3)&"<br>"
response.write arrPage(4)&"<br>"

%>
0
 
LVL 30

Author Comment

by:Wayne Barron
ID: 38862833
Thanks Padas.
It was weird, I had it set for the (3) and it picked up on the first one, so I had to set it for (5) in order to grab the number.

However, it works like a charm.
And I see that I am not the only one that is up late tonight..

have a good one Padas.
Carrzkiss
0
 
LVL 30

Author Closing Comment

by:Wayne Barron
ID: 38862835
As always, great work, from a great coder and person.
Take care Padas.

Carrzkiss
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Time/Date Query 11 43
Diminish Pop-up  in 3 seconds 7 49
Html Table Looping (part 2) 5 27
Time comparison asp 1 13
I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

837 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question