Recent Widgets


Register for DashboardWidgets

Recent Forums Posts

Partners


iCompositions

MacDesktops.net

RSS Showcase
RSS Comments
RSS Forums

This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies. Posted in: Widget Development

XLMHttpRequest and spaces in URI

Author Message
MacPrawn



Joined: 04 Aug 2005
Posts: 6
Location: Bromont, Qc, Canada

Posted: Thu Feb 22, 2007 - 7:49 am    Post subject: XLMHttpRequest and spaces in URI Reply with quote

Hi everyone!

I'm trying to read a plist file in the "Application Support" folder, using XMLHttpRequest... The problem is, the space in "Application Support" is breaking code that normally would work flawlessly... I've tried replacing it with "+" and "%20", but to no avail...

I know I could use cURL, or some other command line for this but for one thing, they won't return me a XML document object (text would be usable I guess, but a pain) and there's apparently a 4K limit to the outputString form a system call... In the short term that limit is fine, but I can't know for sure in the long run, and because of that first reason, I'd like to find another way??

Any ideas?

Thanks!
_________________
Jean Le Clerc << Making your IT life easier >>

Logiciels Malus Softwares
http://www.malus.ca
View user's profile Send private message Send e-mail Visit poster's website AIM Address Widgets
MacPrawn



Joined: 04 Aug 2005
Posts: 6
Location: Bromont, Qc, Canada

Posted: Thu Feb 22, 2007 - 8:10 am    Post subject: Reply with quote

Ok - found a work around... It's not pretty, but it will do... So here it is, for posterity:

basically, I make a copy of the file I want to read from the "Application Support" folder to the "Home" folder using a system call, read *that* version in the home folder using XMLHttpRequest and then delete that temporary copy... Like I said, not pretty, but it does the job...

Thanks!
_________________
Jean Le Clerc << Making your IT life easier >>

Logiciels Malus Softwares
http://www.malus.ca
View user's profile Send private message Send e-mail Visit poster's website AIM Address Widgets
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.

 
Powered by phpBB © 2001, 2002 phpBB Group