Tech Note: Code Frenzy Continued

Charles Johnsonfollow me on twitter
Technology • Mon Nov 9, 2009 at 6:21 pm PST • Views: 204

As I mentioned yesterday, I recently discovered that the LGF server was running PHP 5, not PHP 4 as I thought, and I’ve been like a geek in a gadget store ever since.

For years, the RSS news and blog feeds in our left sidebar were driven by a PHP 4 class called Magpie RSS, but now I’ve rewritten the LGF code to use PHP 5’s native SimpleXML functions.

The RSS format was pretty straightforward, but ATOM feeds required a little more geekage, because to do it right you have to properly handle an XML feature called “namespacing” while parsing the feed. The PHP SimpleXML documentation is rather … ahem … sparse on exactly how to do this, but this article at IBM’s developerWorks was very helpful: SimpleXML processing with PHP. And this comment at the PHP website showed me how to auto-detect whether an XML file is RSS or ATOM.

And now, we return to our regularly scheduled open thread.

Advertisement

458 comments

^ back to top ^

Name:

Pass:

Register Forgot Your Password? Re-send Confirmation (To log in, cookies must be enabled in your browser!)

Turn off ads by subscribing!
For about 33 cents a day, our subscription option turns off all advertisements at LGF!
Read more...


► LGF Headlines

  • Loading...

► Tweeted Articles

  • Loading...

► Tweeted Pages

  • Loading...

► Top 10 Comments

  • Loading...

► Bottom Comments

  • Loading...

► Recent Comments

  • Loading...

► Tools/Info

► Tag Cloud

► Contact

You must have Javascript enabled to use the contact form.
Your email:

Subject:

Message:


Messages may be published in our weblog, unless you request otherwise.
Tech Note:
Using the Contact Form

More Partners

Compare Electricity Prices in your area. Texas Electricity is deregulated; you have the right to choose Texas Electric Rates from among many Texas Electric Companies.

Chunks of funk.

TwitterFacebook
LGF Pages
Recent Pages

Daniel Ballard
Iran Hit With 'Flame,' the Most Sophisticated Spy Virus Ever - May. 30, 2012
1 hour, 57 minutes ago
Views: 45 • Comments: 0
Tweets: 0 • Rating: 1

researchok
Romney and Trump
3 hours, 28 minutes ago
Views: 60 • Comments: 0
Tweets: 0 • Rating: 0

ggt
Leona's Sister Gerri
4 hours, 32 minutes ago
Views: 59 • Comments: 0
Tweets: 0 • Rating: 1

I AM BREITBART!
Seattle Manhunt Launched After Deadly Cafe Shootings, Carjacking
6 hours, 42 minutes ago
Views: 103 • Comments: 1
Tweets: 0 • Rating: 2

Shiplord Kirel
Dragon to Depart Station Thursday
7 hours, 53 minutes ago
Views: 53 • Comments: 0
Tweets: 0 • Rating: 1

Randall Gross
Citadel Malware Delivers Reveton Ransomware in attempts to extort money
8 hours, 46 minutes ago
Views: 142 • Comments: 0
Tweets: 0 • Rating: 3

Channeling Confucius
From the previous Diamond Jubilee: Kipling's 'Recessional'
9 hours, 17 minutes ago
Views: 89 • Comments: 0
Tweets: 0 • Rating: 0

Bob Dillon
REVEALED: Hundreds of Words to Avoid Using Online if You Don't Want the Government Spying on You
10 hours, 21 minutes ago
Views: 219 • Comments: 3
Tweets: 0 • Rating: 2

Learned Mother of Zion
Native Americans Have Jewish DNA!
10 hours, 41 minutes ago
Views: 336 • Comments: 10
Tweets: 1 • Rating: 8

Eclectic Infidel
Mitt Romney for a better Amercia!
10 hours, 46 minutes ago
Views: 151 • Comments: 1
Tweets: 0 • Rating: 0

 Frank says:

I can't think of anything I like more than audience participation -- From the Mothers of Prevention