|
|
Re: by get this format my explode file name like this through php [message #175902 is a reply to message #175894] |
Fri, 04 November 2011 12:04 |
|
On Thu, 03 Nov 2011 23:41:06 -0700, srikanth wrote:
> N1N2N3N4N5N6N7N8N9N10N11N12N13N14YYYYMMDDHHMMSS.zip where,
>
> N1N2N3N4 – Branch Code
> N5N6N7N8N9 – ID.
> N10N11N12N13N14- Sequence Number
> YYYYMMDDHHMMSS – Date-time
What is your code?
What is your input data?
What is the result?
Why is the result not what you expect?
Rgds
Denis McMahon
|
|
|
|
|
|
|
Re: by get this format my explode file name like this through php [message #175911 is a reply to message #175908] |
Sat, 05 November 2011 20:20 |
|
On Sat, 05 Nov 2011 18:20:30 +0100, Michael Fesser wrote:
> .oO(Denis McMahon)
>
>> On Sat, 05 Nov 2011 06:34:31 -0700, Balazs Nadasdi wrote:
>>
>>> 2. Why do you use
>>> YYYYMMDDHHMMSS? Unix Timestamp?
>>
>> Conjecture - as he's creating a filename, [...]
>
> I understood it that way that he has a filename and wants to split it
> into its parts as described ("explode"). In this case preg_match() or
> sscanf() might help.
Oh. I thought he was trying to create the filename from the data.
If he wants to get the data from the filename, all he needs is a few
http://uk.php.net/manual/en/function.substr.php surely.
$branch = substr(string,start,length);
etc etc etc
Rgds
Denis McMahon
|
|
|