Hi,
Saturday, January 3, 2004, 4:50:44 PM, you wrote:
C> You forgot to double slash the windows slash like: '\\'
C> I would write that same functionality as follows:
C> $sep = (PHP_OS == 'Windows')? '\\':'/';
C> if(substr($template_path,-1) == $sep)) $template_path .= $sep;
Not in single quote
s [mailto:[EMAIL PROTECTED]
Sent: Friday, January 02, 2004 7:24 PM
To: Ryan A
Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: Re[2]: [PHP] End slash, small problem.
Hi,
Saturday, January 3, 2004, 11:23:00 AM, you wrote:
RA> Hi,
RA> Thanks for replying.
RA> Basically after that path I
Hi,
Saturday, January 3, 2004, 11:23:00 AM, you wrote:
RA> Hi,
RA> Thanks for replying.
RA> Basically after that path I am adding a file "ryanFile.php" so I need that
RA> ending slash to always be in the path
RA> My question was exactly that...how do I "grab" the last character?
RA> Thanks,
RA>
substr()
http://us2.php.net/manual/en/function.substr.php
Regards
-M
-Original Message-
From: Ryan A [mailto:[EMAIL PROTECTED]
Sent: Friday, January 02, 2004 8:23 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP] End slash, small problem.
Hi,
Thanks for replying
o your check before that code is executed.
>
> Regards
> -M
>
> -Original Message-
> From: Ryan A [mailto:[EMAIL PROTECTED]
> Sent: Friday, January 02, 2004 8:08 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] End slash, small problem.
>
> Hi,
> Small problem, I
ge-
From: Ryan A [mailto:[EMAIL PROTECTED]
Sent: Friday, January 02, 2004 8:08 PM
To: [EMAIL PROTECTED]
Subject: [PHP] End slash, small problem.
Hi,
Small problem, I am asking my users to enter a path for something in a
textbox..
eg:
/home/blah/something
am confused as to how I can see if the
Hi,
Small problem, I am asking my users to enter a path for something in a
textbox..
eg:
/home/blah/something
am confused as to how I can see if the entered path has an ending slash, if
it has a end slash:
$hasSlash=1 else $hasSlash=0
then i can carry on with my output...
Thanks in advance.
Ch
7 matches
Mail list logo