Request for a new library routine RemoveURLPart()
Posted: Sun Apr 08, 2012 5:50 pm
I have found a need for a function RemoveURLPart() which is simialr to GetURLPart() and can be described thus:
RemoveURLPart()
Syntax
Result$ = URLPart(URL$, Parameter$)
Description
Remove a specific field of the given URL$. This can be a named parameter or another field within the URL.
Examples
URL$ = "purebasic.com:80/index.php3?test=1&ok=2"
Debug RemoveURLPart(URL$, "Test")
gives "purebasic.com:80/index.php3?ok=2"
Debug RemoveURLPart(URL$, #PB_URL_Parameters)
gives "purebasic.com:80/index.php3
Debug RemoveURLPart(URL$, #PB_URL_Port)
gives "purebasic.com/index.php3?test=1&ok=2"
Debug RemoveURLPart(URL$, #PB_URL_Path)
gives "purebasic.com:80"
as the parameters are useless without the path
Could this please be implemented?
RemoveURLPart()
Syntax
Result$ = URLPart(URL$, Parameter$)
Description
Remove a specific field of the given URL$. This can be a named parameter or another field within the URL.
Examples
URL$ = "purebasic.com:80/index.php3?test=1&ok=2"
Debug RemoveURLPart(URL$, "Test")
gives "purebasic.com:80/index.php3?ok=2"
Debug RemoveURLPart(URL$, #PB_URL_Parameters)
gives "purebasic.com:80/index.php3
Debug RemoveURLPart(URL$, #PB_URL_Port)
gives "purebasic.com/index.php3?test=1&ok=2"
Debug RemoveURLPart(URL$, #PB_URL_Path)
gives "purebasic.com:80"
as the parameters are useless without the path
Could this please be implemented?