getting pages walked per base url

User avatar
mark
Site Admin
Posts: 5519
Joined: Tue Apr 25, 2000 6:56 pm

getting pages walked per base url

Post by mark »

Doesn't sort? As in leaves the items in the order they were in before? We'd have to see your code and the result to know why.
KMandalia
Posts: 301
Joined: Fri Jul 09, 2004 3:50 pm

getting pages walked per base url

Post by KMandalia »

As suspected, it was my mistake. I was sorting them after I break the variable in pieces. I have it fixed now.


however there is one minor problem, which I don't think there will be a solution. I am removing http://www part of the url but when the url doesn't have http://www. but has http://somedomain it wouldn't sort it correctly.

But that's alright for the time being.
User avatar
mark
Site Admin
Posts: 5519
Joined: Tue Apr 25, 2000 6:56 pm

getting pages walked per base url

Post by mark »

Try removing
http://=www\.?
KMandalia
Posts: 301
Joined: Fri Jul 09, 2004 3:50 pm

getting pages walked per base url

Post by KMandalia »

I am already doing it,

For example I have two sites,

www.somesite.com
somedomain.somesite.com

I want to only consider everything after the first '.'

<sandr "http://=www\.?[^/]+.*" "\3" $urllisting>

this one only removes if the url starts with 'www', what would I change to return everything after the first '.' ?
User avatar
mark
Site Admin
Posts: 5519
Joined: Tue Apr 25, 2000 6:56 pm

getting pages walked per base url

Post by mark »

<sandr "http://=[^.]+\.=.*" "\4" $urllisting>

But for "http://somesite.com" you'll get just "com". Not sure if that's what you really want.
KMandalia
Posts: 301
Joined: Fri Jul 09, 2004 3:50 pm

getting pages walked per base url

Post by KMandalia »

yeah, you are right.

I don't think I want to do anything about it for the time being.

Thanks.
Post Reply