I'm wondering if the XML is faster that INI or vise versa.
I'm developing a site that includes many files this question is connected to my problem about including many files and I decided to take another step on this I want to test ini and xml if the load or process will decrease I mean the site will be faster loader. As far as I know INI is very good on PHP including but I can't do a comparison on XML vs. INI.
Can any expert or not an expert explain me about this two things I'm new with XML?
You need to metric that with your concrete application with the data in question. It's hard to say generally.
But as long as you don't even run into a problem, I would use the one you're familiar with. In case this starts to get slow (which you don't even know if it will ever happen), you can still learn about XML anyway.
So don't make up your mind about problems you don't have. I'm sure you've got more to do.
As INI files are simpler, I imagine parsing them would take slightly less time. That said, XML can easily represent much more complex data structures.
This being true, I imagine anything where the difference in parsing speed is critical would have other problems - they are both probably going to parsed fast enough for all but the most crazy of edge cases.
With small XML files, instantiating the XML parser can take longer than actually parsing the source file. So the answer may depend on whether your application is already using XML for other purposes.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With