Perfect
Thankyou
Henry
"Erik Price" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>
> On Tuesday, July 2, 2002, at 01:52 PM, Henry wrote:
>
> > Imagine I have a piece of text
> >
> > "Dear [firstname]
> >
> > Thankyou for purchasing [product] on [date].
> >
On Tuesday, July 2, 2002, at 01:52 PM, Henry wrote:
> Imagine I have a piece of text
>
> "Dear [firstname]
>
> Thankyou for purchasing [product] on [date].
>
> We're sure you'll be very [expectation].
>
> Ta Very much."
>
> Whats the easiest way to replace all the things in square brackets with
Nothing will be inserted if the variable is empty, so you could just use
$firstname, $product, $date, etc. inside your "letter". The main problem is
adding logic to your "letter" to respond appropriately based on the value of
different variables. For example:
$MailBody = "";
if (empty($firstnam
If you're on a unix/linux system, you can use an AWK script
-Original Message-
From: Peter Sienkiewicz [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, January 16, 2002 2:32 PM
To: [EMAIL PROTECTED]
Subject: [PHP] find and replace help.. VERY important
Hello ladies and gentlemen,
I need a
ad/write/execute)
>
> The plus + can be substituted with a minus - to remove specific
> permissions, and any combination of r, w, and x can exist in there.
>
>
> - Original Message -
> From: "Shrout, Ryan" <[EMAIL PROTECTED]>
> To: "
permissions, and any combination of r, w, and x can exist in there.
- Original Message -
From: "Shrout, Ryan" <[EMAIL PROTECTED]>
To: "'Matt Kaufman'" <[EMAIL PROTECTED]>
Sent: Monday, July 30, 2001 12:14 PM
Subject: RE: [PHP] Find and Replace
> Thanks
I forget, actually :)
Here's a tutorial on it though -
http://www.bruce-hamilton.com/tutorials/chmod.shtml
Matt Kaufman
- Original Message -
From: "Shrout, Ryan" <[EMAIL PROTECTED]>
To: "'Matt Kaufman'" <[EMAIL PROTECTED]>
Sent: Monday, Jul
On 30-Jul-2001 Shrout, Ryan wrote:
> This isn't exactly PHP I need help with, but it relates to what I learned
> about security. Up until now, I have been using *.inc extensions for my
> include files. Well, I didn't realize until recently that anyone can view
> these files. So, I want to rena
On Monday 30 July 2001 20:14, [EMAIL PROTECTED] wrote:
> It's also possible (if you're allowed to change the httpd.conf file) to put
> in a directive, something like
>
> Order deny,allow
> Deny from all
>
This is also by far the safest technique (other than moving the included
files outside y
Try this:
---cut---
###
# Finds all *.inc from current directory and rename then to *.inc.php
# then edit that file and replace all references to it as well
# I haven't tested this, but it should work, but don't be a dumbass and not
make a backup copy
# of your files before runnin
TECTED]
Subject: Re: [PHP] Find and Replace
Oh, vi has a find and replace feature if you want to do it through the
terminal.
Matt Kaufman
- Original Message -
From: "Shrout, Ryan" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, July 30, 2001 12:06 PM
Subject
I just setup apache to parse *.inc files through php.
Nathan Cook
[EMAIL PROTECTED]
- Original Message -
From: "Shrout, Ryan" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, July 30, 2001 1:06 PM
Subject: [PHP] Find and Replace
> This isn't exactly PHP I need help with, but i
!!Be careful of this, its super powerful!!
try it on 1 test file first and then do the wildcard...
from the unix command line:
bash>perl -p -i -e s/myself.inc/myself.inc.php/ *.php
so its:
perl -p -i -e s/original_text/text_to_replace/ file_name(s)
- Original Message -
From: "Shr
Oh, vi has a find and replace feature if you want to do it through the
terminal.
Matt Kaufman
- Original Message -
From: "Shrout, Ryan" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, July 30, 2001 12:06 PM
Subject: [PHP] Find and Replace
> This isn't exactly PHP I need help
There are a lot of text editors that allow you to find and replace - vi even
does.
You can also CHMOD the *.inc files to allow only the owner to access them -
I don't even use the *.inc or *.inc.php function, you can do without it (eg
include.php, settings.php instead of include.inc or settings.i
15 matches
Mail list logo