If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

If you don't actually need that string $i for anything else, I'd suggest using range() to create your array instead:

PHP Code:

<?php

$numbers = range( 1,15 );
# same result

If neither of these are what you're asking about, please clarify.

Hi There

Thanks for your message and valuable advices.

Your Question --

...your code seems incomplete. Are you intending to create the variable $i in this loop?
Using $i both to control the loop and create your result will have unexpected consequences.

In addition, it seems to conflict with what you said in your original post:
--------------------------------------------------------------------------------------Answer
If iam going to write the full coding , in common sense iam missing the valuable time of me and people like you readers. that why i shortened it into a small code, as the coded form is already understand for you.

Your Question --
Explode() is exploding in this issue
what?
--------------------------------------------------------------------------Answer
Exploding (means) - To show to be false or unreliable. http://www.thefreedictionary.com/exploding
I refer it with my program output , which is incorrect while using explode() function.

Your Question -
If neither of these are what you're asking about, please clarify.
-------------------------------------------------------------------------Answer
The issue is solved when the range function is used.. Thanks for your kind and valuable suggestions

If iam going to write the full coding , in common sense iam missing the valuable time of me and people like you readers. that why i shortened it into a small code, as the coded form is already understand for you.

While I understand your goal, it is always much more helpful to give a working example.

Yes, it is a good idea to remove irrelevant code from your samples.
However, in order to be useful, the code that you do show us needs to demonstrate not only the part that is the problem, but also the part that works.
In this case, removing portions of your code only added to the confusion by implying other (false) problems.

Originally Posted by letom

Exploding (means) - To show to be false or unreliable.
I refer it with my program output , which is incorrect while using explode() function.

Alright. How is it being unreliable or incorrect? What was the result it gave you, vs. what you expected?
The statement "it doesn't work" will not lead to a solution on its own.

Originally Posted by letom

The issue is solved when the range function is used.. Thanks for your kind and valuable suggestions

The reason we expect clear questions is because it makes it easier to help you. This is all for you, not for us. And although it may feel excessive, the details really are important. We can't guess what you are thinking, so your posts need to be clear enough for us to understand all of the important details. If we don't understand them, we can't help.