reading xml faster than DB call?


Posted on 16th Feb 2014 07:03 pm by admin

I am trying to optimize a high traffic website, and I enabled a feature where there are three photos selected from the most recently submitted ones, and displayed at the top of the page. I figured that if each person is asking for 3 photos every time the page loads, this will put strain on server load. My solution involves having a script generate an xml file of the 30 most recent photos every half hour, and then cycle through the xml on the actual page. Is this a better solution than making a db call, in terms of speed gained/efficiency? I dont have much experience with XML so I wouldn't know how fast parsing it in PHP would be compared to a database call.

No comments posted yet

Your Answer:

Login to answer
305 Like 15 Dislike
Previous forums Next forums
Other forums

Getting Resource id #11 while trying to connect..
So i tried using "DEFINE" for the first time and im using the variables i defined to conne

Php - mysql store data and use it later?
Hi, i' making a login page at the moment, however my username + password is stored many different pl

change text color with a jQuery code
Hihow can I change the text in a asp:TextBox to a different color when I start typing using jQuery?I

How to form a xml form table with a single sql statement..?
Hi everyone,
I don't know if this is going to be a duplicate thread but i couldn't

Login page problems
I developed a website a few months ago and I am now having an issue with logging into it. The place

On page view, minus credit
Hello all, please, I need a little help with this script. I am charging one credit (credits can be p

C problem struct and string
Hi guys,

This is my first post and I'm hoping the experts here can help me solve my problem.<

help finding hacking loopholes
i was attacked by a redirect php injection

my pc is clean of viruses

so i figure that

form problem
below in the form action, i've put "test.php?w=$sw&h=$sh" but when i input the for

PHP/Database issue
My friend is helping me make a database where you go to a certain webpage of my site and the page wi

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash