Closed decadence closed 5 years ago
Hi, Thank you for the suggestion. Would it be OK if this is a generator instead of returning an array of IPs? I think for a large subnet using an array may result in a PHP fatal error for allowed memory size.
I think that's will be ok. Anyway anyone can convert iterator to array if needed.
Thanks decadence, you have told my requirement. I am searching a program that will list all the IPs in the subnet. And thanks to markrogoyski. Please include the feature if possible.
I too would appreciate if this function is available. listing the IP range.
I would like to have that option, but I agree with @markrogoyski about the problem when we set 10 using the cidr notation, for example, will generate 2²² ips, so it will result in a fatal error.
Thanks for all the feedback. I will try to include this in the next release.
This has been added in version v3.0.0.
Thanks to @fillmorejd for implementing this!
Hello. Thanks for the library. Can we have method for listing all IP in subnet? Something like:
If you like I can make PR for this or you can add it by yourself.