Hi,
I have a question about determine how many charactars contain a var.
Does anyone know, there will probably be a simple command, but I can't find it.
Assuming $_ = /hello/this/will/have/to/be/IMPORTANT/ONLY/AND/CAN/BE/LONG/features.txt
$dir = substr("$_", 0, -13); ## Remove features.txt
$link = substr("$dir", 27); ## Remove the not used and already defined $base
@href = split(/\//, $link); ## put this in an array
$lineteller = ( scalar(@href) -1 ); ## To determine the last word
$href = "$href[${lineteller}]"; ## and make $href this last one
$nhref = ???($href); ?? Determine number of characters
$header = substr("$link", 0, -${nhref}); ## Use it to def $header without
$href
So what I need out of $_ :
$dir = "/hello/this/will/have/to/be/IMPORTANT/ONLY/AND/CAN/BE/LONG";
$link = "/IMPORTANT/ONLY/AND/CAN/BE/LONG";
$href = "LONG";
$header = "/IMPORTANT/ONLY/AND/CAN/BE/";
I know there is a faster way to get the last value of an aray, but I don't know
exactly how anymore (help is welcome). The most important now is, how do I get
the number of charactars out of $href ??
Thanks for your help in adance !!
Regs David
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]