Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
xml what? expat, simplexml, dom, xmlrpc?
Old 03-17-2008, 02:30 AM xml what? expat, simplexml, dom, xmlrpc?
Novice Talker

Posts: 6
Name: anggoro
Trades: 0
I am learning xml for curiousity. I think this db format is ready to go wider than as rss-thing. So, I'm trying to make simple cms with xml (not mysql or plain txt db).

I tried simplexml. It's cool and so easy. But, this feature is only available (by default) in php5.

I tried dom, and it's full of codes. I think it run heavier than simplexml.

I look around web and found that there are many cms' use xmlrpc and expat as xml parser.

any one knows?

thanks!!
sumpel is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 03-17-2008, 02:38 AM Re: xml what? expat, simplexml, dom, xmlrpc?
NullPointer's Avatar
Will Code for Food

Posts: 2,815
Name: Matt
Location: Irvine, CA
Trades: 0
I'm not sure exactly what you are asking but if you are looking for an xml parser, php has one built in: http://us2.php.net/xml its available in php4 and 5. As far as xml as a database goes, it is still just a flat file, I wouldn't trust it for a large scale project, or if you intend to have a large number of entries.

That being said it may be a good solution to maximize application compatibility where you don't intend to maintain a large database. Maybe someone can correct me if I'm wrong regarding XML based databases vs. mysql, mssql, oracle etc.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE

Last edited by NullPointer; 03-17-2008 at 02:42 AM..
NullPointer is online now
Reply With Quote
View Public Profile Visit NullPointer's homepage!
 
Old 03-17-2008, 02:46 AM Re: xml what? expat, simplexml, dom, xmlrpc?
Novice Talker

Posts: 6
Name: anggoro
Trades: 0
thanks for your reply. My problem is there are many ways to parse xml file in php. your link point to xml expat (which is one of extension). I want to know what the best extension which available (by default) in php4 and php5.
sumpel is offline
Reply With Quote
View Public Profile
 
Old 03-17-2008, 04:14 AM Re: xml what? expat, simplexml, dom, xmlrpc?
mtishetsky's Avatar
King Spam Talker

Posts: 1,226
Name: Mike
Location: Mataro, Spain
Trades: 0
Using XML as data storage engine is very, very bad idea. When your data grows over 5 (10, 20, 50) Mb and you get any sufficient amount of requests per second your script performance will reduce in exponential manner. You can use XML to store small amounts of data which you are changing frequently and manually (because main idea of XML is to keep data human readable) but using it instead of usual (relational) database engine will not give you any profit.
__________________

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE

And don't forget to give me talkupation!
mtishetsky is offline
Reply With Quote
View Public Profile Visit mtishetsky's homepage!
 
Old 03-17-2008, 04:15 AM Re: xml what? expat, simplexml, dom, xmlrpc?
mtishetsky's Avatar
King Spam Talker

Posts: 1,226
Name: Mike
Location: Mataro, Spain
Trades: 0
As for me I use PEAR XML::Serializer package to convert XML into data objects and back.
__________________

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE

And don't forget to give me talkupation!
mtishetsky is offline
Reply With Quote
View Public Profile Visit mtishetsky's homepage!
 
Old 03-17-2008, 04:48 AM Re: xml what? expat, simplexml, dom, xmlrpc?
Novice Talker

Posts: 6
Name: anggoro
Trades: 0
Quote:
Originally Posted by mtishetsky View Post
Using XML as data storage engine is very, very bad idea. When your data grows over 5 (10, 20, 50) Mb and you get any sufficient amount of requests per second your script performance will reduce in exponential manner. You can use XML to store small amounts of data which you are changing frequently and manually (because main idea of XML is to keep data human readable) but using it instead of usual (relational) database engine will not give you any profit.
thanks you for your suggestion. I choose xml to this apps because i think it wouldn't be that big. I want to make this for company profile or portfolio website.

btw, what is the benefit of using PEAR than other xml parsers?
sumpel is offline
Reply With Quote
View Public Profile
 
Old 03-17-2008, 07:10 AM Re: xml what? expat, simplexml, dom, xmlrpc?
mtishetsky's Avatar
King Spam Talker

Posts: 1,226
Name: Mike
Location: Mataro, Spain
Trades: 0
I'm not sure about built in php parsers but in pear unserializer it is just needed to call two functions to convert xml text data into an complex object which I can iterate with foreach() or call something like $object->children['child_name']->items. AFAIR when I tried to play with domxml or something like that I got a lot of problems due to its unobvioucity and bad flexibility.
__________________

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE

And don't forget to give me talkupation!
mtishetsky is offline
Reply With Quote
View Public Profile Visit mtishetsky's homepage!
 
Old 03-17-2008, 11:33 PM Re: xml what? expat, simplexml, dom, xmlrpc?
Novice Talker

Posts: 6
Name: anggoro
Trades: 0
thanks. It is like simplexml, you can call xml file by "$root->book->chapter". Unfortunately, simplexml is for php5 (php4 with enable instalation-not by default). But, it lacks in structure recognizing. Ok, I'll try pear, then. thanks again, mtishetsky.
sumpel is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to xml what? expat, simplexml, dom, xmlrpc?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.26618 seconds with 12 queries