Re: [PHP] Regular Expression help need

2008-07-27 Thread James Dempster
On Fri, Jul 25, 2008 at 1:08 PM, Shelley [EMAIL PROTECTED] wrote: Hi Richard, Not exactly actually. What I mean is: Before: phi strongRichard/strong, good morninglt;/p After: phi strongRichard/stronggt;, amp; good morninglt;/p I hope it's clear now. On Fri, Jul 25, 2008 at 7:53 PM,

Re: [PHP] Passing arguments as they are received to another function

2008-07-12 Thread James Dempster
You might want to take a look at http://php.net/manual/en/function.call-user-func-array.php On Sat, Jul 12, 2008 at 4:57 PM, Luigi Perroti [EMAIL PROTECTED] wrote: Hello, I'm trying to implement a few simple wrappers for some PHP functions. Here's an example of what I'm trying to do:

Re: [PHP] Passing arguments as they are received to another function

2008-07-12 Thread James Dempster
: On Sat, Jul 12, 2008 at 6:00 PM, James Dempster wrote: You might want to take a look at http://php.net/manual/en/function.call-user-func-array.php Thank you very much for your suggestion. I've looked into it but I guess this doesn't work with what I'm trying to do, although what you

Re: [PHP] escape character in query string

2008-06-23 Thread James Dempster
for a space I belive a plus sign would work + try the urlencode function it would make it much easier. /James Dempster On Mon, Jun 23, 2008 at 3:34 AM, joaquinbordado [EMAIL PROTECTED] wrote: would someone happen to know the escape character for query string? here is my querysting my.php

Re: [PHP] climb up the path

2008-06-18 Thread James Dempster
Personally I use. ?php require_once(dirname(dirname(__FILE__)).'/config.php'); I think it's what most people do. /James Dempster On Wed, Jun 18, 2008 at 1:31 PM, Iv Ray [EMAIL PROTECTED] wrote: hi all, i need a way to get the path to the parent folder of the folder i am in. one dirty way

Re: [PHP] Avoid object twice

2008-06-03 Thread James Dempster
I don't see how it's possible for you to get Hello after Good, when the file that cause's Hello is required to do Good /James On Mon, Jun 2, 2008 at 2:00 PM, Yui Hiroaki [EMAIL PROTECTED] wrote: Please take a look at code. a.php $obj=new my(Hello); $obj-buff(); Class

Re: [PHP] Avoid object twice

2008-06-03 Thread James Dempster
/; } } /James Dempster On Tue, Jun 3, 2008 at 9:17 AM, Yui Hiroaki [EMAIL PROTECTED] wrote: HI! I had mistake in code in php. When I excute My.php, it say Hello When I excute b.php, it say Hello Good I would like to execute b.php and show only Good If you know it ,please teach me

Re: [PHP] Storing £ (pound sterling) sign and displaying in HTML email

2008-06-02 Thread James Dempster
This is most likely a character encoding issue. Check that the html encoding is set to the same type as what your storing it as in mysql. /James On Mon, Jun 2, 2008 at 10:26 PM, Graham Cossey [EMAIL PROTECTED] wrote: Could someone please point me in the right direction here please? I have a

Re: [PHP] Good HTML parser needed

2008-05-14 Thread James Dempster
PROTECTED] wrote: On Wed, 2008-05-14 at 11:18 -0400, Eric Butera wrote: On Tue, May 13, 2008 at 4:07 AM, James Dempster [EMAIL PROTECTED] wrote: http://htmlpurifier.org/ -- /James This is the only real solution. That depends... if I'm the webmaster and I want to input

Re: [PHP] Good HTML parser needed

2008-05-13 Thread James Dempster
http://htmlpurifier.org/ -- /James On Tue, May 13, 2008 at 4:34 AM, Shelley [EMAIL PROTECTED] wrote: Hi all, The fact is that I have a site that allow users to post hypertext articles. However, I saw that sometimes, because of their careless input, the articles is not rendered correctly.

Re: [PHP] Replacing accented characters by non-accented characters

2008-05-12 Thread James Dempster
maybe try iconv (http://uk.php.net/manual/en/function.iconv.php) e.g. echo iconv('ISO-8859-1', 'UTF-8//TRANSLIT', 'français'); -- /James On Mon, May 12, 2008 at 4:09 PM, Yannick Warnier [EMAIL PROTECTED] wrote: Hello, I've been trying to find something nice to transform an accentuated

Re: [PHP] Replacing accented characters by non-accented characters

2008-05-12 Thread James Dempster
oops wrong way round echo iconv('UTF-8', 'ISO-8859-1//TRANSLIT', 'français'); On Mon, May 12, 2008 at 4:27 PM, James Dempster [EMAIL PROTECTED] wrote: maybe try iconv (http://uk.php.net/manual/en/function.iconv.php) e.g. echo iconv('ISO-8859-1', 'UTF-8//TRANSLIT', 'français'); -- /James

Re: [PHP] Get array as string --Help

2008-05-09 Thread James Dempster
serialize -- /James On Fri, May 9, 2008 at 10:40 AM, Shelley [EMAIL PROTECTED] wrote: Hi all, If I have an array like this: $arr = array ( 'c' = 'd', 'e' = 'f'); How can I convert this array into a string? I want to write an array into a file. Thanks in

Re: [PHP] Re: Question regarding fopen

2008-05-01 Thread James Dempster
?php $foldersystem = getcwd().'/test1'; $id = '54961'; $imgstr = 'tdtdtdtd'; //uniqid(); $i = 2; $imagenamesmall = $foldersystem . '/' . $id . $imgstr . '-s' . $i . '.jpg'; echo $imagenamesmall; // For debugging purposses -- returns exactly what I want. //attempt to create folder

Re: [PHP] Re: Question regarding fopen

2008-05-01 Thread James Dempster
it... But then the value is wrong again :S I've never had a problem like this.. Very strange.. 2008/5/1 James Dempster [EMAIL PROTECTED]: ?php $foldersystem = getcwd().'/test1'; $id = '54961'; $imgstr = 'tdtdtdtd'; //uniqid(); $i = 2; $imagenamesmall = $foldersystem . '/' . $id . $imgstr . '-s

Re: [PHP] Help with preg_match_all regex for alt tags

2008-04-29 Thread James Dempster
try preg_match_all('/img[^]*alt=([^]*)/i', $subject, $result); -- /James On Tue, Apr 29, 2008 at 8:18 PM, Joe Harman [EMAIL PROTECTED] wrote: Hey y'all ... i am having alittle trouble with this regex for finding ALT tags for images... Here is my statement

Re: [PHP] PHP debugger

2008-04-28 Thread James Dempster
I'd suggest Xdebug http://xdebug.org/ -- /James On Mon, Apr 28, 2008 at 12:00 PM, J. Manuel Velasco - UBILIBET [EMAIL PROTECTED] wrote: Hello, Anybody knows a good debugger for PHP and basic usage? I've found: http://dd.cron.ru/dbg/, what do you think about it ? Thanks. --

Re: [PHP] Big companies that use PHP?

2008-04-24 Thread James Dempster
there is the php easter eggshttp://shiflett.org/blog/2006/feb/php-easter-eggswhich show that it's php. but most large companies turn that off. expose_php = 'off' -- /James On Thu, Apr 24, 2008 at 8:54 AM, Tom Chubb [EMAIL PROTECTED] wrote: On 23/04/2008, Thiago Pojda [EMAIL PROTECTED]

Re: [PHP] need pop-up in progress alert

2008-04-18 Thread James Dempster
As a suggestion you could store a progress of the function in the session and make regular calls via ajax back to the server for the progress. -- /James On Fri, Apr 18, 2008 at 3:42 PM, Steve Holmes [EMAIL PROTECTED] wrote: Greetings, I'm relatively new to PHP and I've been lurking for a while