Free Web Hosting Forum
(#1 (permalink))
Old
Member
willettmatter is on a distinguished road
 
Posts: 61
Join Date: Jan 2012
Location: Idaho
Default xml - 01-24-2012, 02:33 AM

I made the simplest XML file I can contrive.

<? xml version 1.0 ?>
<page>
<menu>note</menu>
</page>

yes it is at the very top of the file.

Now I'm trying to pull it into my PHP.

$feat = new SimpleXMLElement(file_get_contents("main.xml"));

I've checked letter by letter, I don't see anything wrong in my code. permitions are correct in file and folder. what else would cause errors reading this in?

ASUS M4A88-M LE / AMD 6 core. Ubuntu
Reply With Quote
Sponsored Links
(#2 (permalink))
Old
ShocK's Avatar
Senior Member
ShocK is on a distinguished road
 
Posts: 1,622
Join Date: Jul 2011
Location: UK
Default 01-24-2012, 02:02 PM

Does this post help? Error, publish iWeb Website.
Reply With Quote
(#3 (permalink))
Old
Member
willettmatter is on a distinguished road
 
Posts: 61
Join Date: Jan 2012
Location: Idaho
Default 01-24-2012, 05:38 PM

Hey Shock, you are right on the money. I knew it was something like that. along those lines. (sorry, just one more) What doctype do you need if you are going to pull files into javascript?

anyway thank you thank you.
Reply With Quote
Reply

Tags
php, xml

Thread Tools
Display Modes

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

Forum Jump



Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.5.2
vBulletin Skin developed by: vBStyles.com