Re: [PHP] Novice question

2011-10-31 Thread John Allsopp
cURL is the best one in my experience, but you have to manage security yourself. Meaning: Remember to escape/encode data. http://php.net/manual/en/book.curl.php Thanks everyone, appreciated, I'll investigate .. Cheers J -- 01723 376477 Cost-free marketing:

[PHP] Novice question

2011-10-30 Thread John Allsopp
Hi I'm afraid I've fallen a little out of touch with PHP dev, so a stupid question for you. I want to write a script that requests a URL and then reads that website .. I'm interested to map web structures. My web host is saying I'll need URL file access enabled but that it's a) a security risk

Re: [PHP] How to secure this

2010-02-13 Thread John Allsopp
Robert Cummings wrote: Ashley Sheridan wrote: On Fri, 2010-02-12 at 16:12 -0500, Robert Cummings wrote: John Allsopp wrote: Hi everyone There may be blinding bits of total ignorance in this so don't ignore the obvious. This is a security question, but a sentence of background: I'm

[PHP] How to secure this

2010-02-12 Thread John Allsopp
Hi everyone There may be blinding bits of total ignorance in this so don't ignore the obvious. This is a security question, but a sentence of background: I'm writing software for a mapping/location website and I want to be able to provide something others can plug into their website that

Re: [PHP] Re: Call to object function, want to PHP interpret returned string

2009-07-07 Thread John Allsopp
Stuart wrote: 2009/7/6 John Allsopp j...@johnallsopp.co.uk: David Robley wrote: John Allsopp wrote: Hi At the top of a webpage I have: ?php include_once(furniture.php); $myFurniture = new furniture(); echo $myFurniture-getTop(my company title); ? to deliver the first lines

[PHP] Call to object function, want to PHP interpret returned string

2009-07-06 Thread John Allsopp
Hi At the top of a webpage I have: ?php include_once(furniture.php); $myFurniture = new furniture(); echo $myFurniture-getTop(my company title); ? to deliver the first lines of HTML, everything in HEAD and the first bits of page furniture (menu, etc). In the furniture object in getTop(), I

Re: [PHP] Re: Call to object function, want to PHP interpret returned string

2009-07-06 Thread John Allsopp
David Robley wrote: John Allsopp wrote: Hi At the top of a webpage I have: ?php include_once(furniture.php); $myFurniture = new furniture(); echo $myFurniture-getTop(my company title); ? to deliver the first lines of HTML, everything in HEAD and the first bits of page furniture (menu

Re: [PHP] is_readable(http://.... text file) says not, but I can in browser

2009-01-11 Thread John Allsopp
Daniel Brown wrote: On Sun, Dec 28, 2008 at 13:02, John Allsopp j...@johnallsopp.co.uk wrote: $myFileLast = http://www.myDomain.com/text.txt;; if (is_readable($myFileLast)) { $fh = fopen($myFileLast, 'r'); $theDataLast = fread($fh, 200); fclose

Re: [PHP] is_readable(http://.... text file) says not, but I can in browser

2009-01-11 Thread John Allsopp
Nathan Nobbe wrote: On Sun, Dec 28, 2008 at 11:02 AM, John Allsopp j...@johnallsopp.co.ukwrote: Hi I'm sure this is simple for yous all but I'm not sure I know the answer. $myFileLast = http://www.myDomain.com/text.txt;; if (is_readable($myFileLast)) { $fh

Re: [PHP] is_readable(http://.... text file) says not, but I canin browser

2009-01-11 Thread John Allsopp
Nathan Rixham wrote: John Allsopp wrote: Nathan Nobbe wrote: On Sun, Dec 28, 2008 at 11:02 AM, John Allsopp j...@johnallsopp.co.ukwrote: Hi I'm sure this is simple for yous all but I'm not sure I know the answer. $myFileLast = http://www.myDomain.com/text.txt

[PHP] is_readable(http://.... text file) says not, but I can in browser

2008-12-28 Thread John Allsopp
Hi I'm sure this is simple for yous all but I'm not sure I know the answer. $myFileLast = http://www.myDomain.com/text.txt;; if (is_readable($myFileLast)) { $fh = fopen($myFileLast, 'r'); $theDataLast = fread($fh, 200); fclose($fh);

Re: [PHP] Re: Pear XML parser finding nothing in ATOM / Movable Type feed

2008-09-18 Thread John Allsopp
Nathan Rixham wrote: Atom and RSS are completely different; the only similarities lie in the fact they are both XML, and both used frequently for syndicating news. Really? OK, back to the books, thanks You need an atom parser; or just load the feed into DOMDocument.. SimplePie and RssPhp are

[PHP] Pear XML parser finding nothing in ATOM / Movable Type feed

2008-09-17 Thread John Allsopp
Hi I know nothing about Pear, so I don't know how to debug this: I've got a newly installed Movable Type blog with a couple of entries in it, and I just found from php.net the pear classes to parse an RSS feed, parser.php and rss.php, and this code from the PEAR site works require_once