php-general Digest 2 Mar 2008 02:30:58 - Issue 5324
Topics (messages 270802 through 270819):
Re: Calculating dates
270802 by: Nathan Nobbe
Re: RewriteRule help
270803 by: Greg Donald
270804 by: Per Jessen
Re: PHP on Windows
270805 by: Andrés Robinet
Hi all,
Anybody knows what apache RewriteRule to use if I want url:
http://www.aaa.comm/user//
be rewritten as:
http://www.aaa.comm/user/index.php//
It is not a php question. But now Im not in apache list and it's a
little hurry.
Any help, thank you very much.
--
Cheers,
Shelley
Daniel Brown wrote:
On Fri, Feb 29, 2008 at 5:22 AM, Shelley [EMAIL PROTECTED] wrote:
Hi all,
What's the command to use if I want to remove all the directories and
files except 'a.gz' under a directory?
There isn't a command in PHP to do this. You'd have to write a
script to
- Original Message -
From: Jim Lucas [EMAIL PROTECTED]
To: Dani Castaños [EMAIL PROTECTED]
Cc: PHP LIST php-general@lists.php.net
Sent: Saturday, March 01, 2008 2:36 AM
Subject: Re: [PHP] Get country from Phone number
Dani Castaños wrote:
Hi all!
I'm looking for some piece of code
Mr. Heyes more or less prompted me to go dig for my other, slightly
heavier version, that doesn't chop words up:
Sorry I hit Reply instead Reply All. Regardless, here's my str_curtail.
There is a bug in it that means if the string is all one word then it
gets curtailed to nada, but that's
Anybody knows what apache RewriteRule to use if I want url:
http://www.aaa.comm/user//
be rewritten as:
http://www.aaa.comm/user/index.php//
It is not a php question. But now Im not in apache list and it's a
little hurry.
If possible you could:
1. Make user a php script
2. Use the
Thanks. That's a nifty way of doing this. Ron
On Fri, 2008-02-29 at 22:08 -0800, Jim Lucas wrote:
Ron Piggott wrote:
Is there an easy way to calculate the number of days between two dates?
Example: 2008-02-27 - 2007-12-03 = 86 days
The dates will be in the format above -MM-DD
I like this way too but it will not work with a date before the first
January 1901.
Do you have another method?
Brice Favre
On Sat, Mar 1, 2008 at 7:08 AM, Jim Lucas [EMAIL PROTECTED] wrote:
Ron Piggott wrote:
Is there an easy way to calculate the number of days between two dates?
On 3/1/08, Shelley [EMAIL PROTECTED] wrote:
Anybody knows what apache RewriteRule to use if I want url:
http://www.aaa.comm/user//
be rewritten as:
http://www.aaa.comm/user/index.php//
RewriteRule ^user/([-a-zA-Z0-9]+)$ /index.php?user=$1 [NC,L]
--
Greg Donald
On Sat, Mar 1, 2008 at 8:42 AM, Brice [EMAIL PROTECTED] wrote:
I like this way too but it will not work with a date before the first
January 1901.
Do you have another method?
the DateTime class uses an unsigned 64 bit integer to represent the unix
timestamp internally. as a result it can
Shelley wrote:
Hi all,
Anybody knows what apache RewriteRule to use if I want url:
http://www.aaa.comm/user//
be rewritten as:
http://www.aaa.comm/user/index.php//
RewriteRule /user/([^/]+)/ /user/index.php/$1/
/Per Jessen, Zürich
--
PHP General Mailing List
-Original Message-
From: Erik SJMN [mailto:[EMAIL PROTECTED]
Sent: Friday, February 29, 2008 9:41 PM
To: php-general@lists.php.net
Subject: [PHP] PHP on Windows
I'm completely new to php and I'm trying to setup an online trouble ticket
system. After the user logs in and submits
hi
try XAMMP from xampp.org it is packaged with apace PHp mysql and filezilla
On Sat, Mar 1, 2008 at 9:51 PM, Andrés Robinet [EMAIL PROTECTED]
wrote:
-Original Message-
From: Erik SJMN [mailto:[EMAIL PROTECTED]
Sent: Friday, February 29, 2008 9:41 PM
To:
On Fri, Feb 29, 2008 at 10:02 PM, Richard S. Crawford
[EMAIL PROTECTED] wrote:
On Friday 29 February 2008 11:58:16 Daniel Brown wrote:
Get a new host that knows how to administer a web server. PHP 4.3
was released 27 December, 2002, with the latest from the 4.3 branch
(4.3.11) being
Put this at the top of of your include files
// *** Debug Only ***/
if(TRUE) // TRUE for debug only
{
ini_set(display_errors, on); //use off if users will see them
error_reporting(E_ALL);
echo 'span style=color:redError display and logging on/span ';
Dear PHP List Experts,
I'm trying to use Pear at my host, Leadhoster.
This line:
require_once('DB.php');
Gets this error:
Warning: main(DB.php): failed to open stream: No such file or directory in
/home/www/everoriginal.onlinewebshop.net/connect04.php on line 4
Fatal error: main(): Failed
I am running apache with php. I set up a curl script to send an xml
request to the php page I'm authoring and want to handle the xml on the
incoming message. My $_POST array is empty though. Is there some other
place I should be looking? $_SERVER shows the incoming message as a
post but again
On Sat, Mar 1, 2008 at 4:12 PM, Larry Brown
[EMAIL PROTECTED] wrote:
I am running apache with php. I set up a curl script to send an xml
request to the php page
did you use a request header to somehow set a mime type to indicate youre
looking for xml? could you show us this request, im not
I'm sending from a php cli with:
$post = '?xml version=1.0
encoding=UTF-8?Data'.$vendorCompanyID.'/Data';
$message = generatePage($page, $post);
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,'https://myserver/mytestpage.php');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
On Sat, Mar 1, 2008 at 3:41 PM, [EMAIL PROTECTED] wrote:
Dear PHP List Experts,
I'm trying to use Pear at my host, Leadhoster.
This line:
require_once('DB.php');
Gets this error:
Warning: main(DB.php): failed to open stream: No such file or directory in
On Sat, Mar 1, 2008 at 5:17 PM, Larry Brown
[EMAIL PROTECTED] wrote:
I'm sending from a php cli with:
$post = '?xml version=1.0
encoding=UTF-8?Data'.$vendorCompanyID.'/Data';
$message = generatePage($page, $post);
$ch = curl_init();
curl_setopt($ch,
Thanks for your help, Nathan!
maybe try
find /usr/local/php4/share/pear -name 'DB.php'
I tried putting that in my script, and got:
Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING in
/home/www/everoriginal.onlinewebshop.net/connect04.php on line 6
I'm thinking find is a
On Sat, Mar 1, 2008 at 6:24 PM, [EMAIL PROTECTED] wrote:
Thanks for your help, Nathan!
maybe try
find /usr/local/php4/share/pear -name 'DB.php'
I tried putting that in my script, and got:
Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING in
when you run you phpinfo script that you mentioned
in your first post, do you see pear in one of the sections there (not just
in the include path)?
A search on pear only yields this line:
include_path.:/usr/local/php4/share/pear.:/usr/local/php4/share/pear
Here is the page, so you can
PHP List, MySQL List
In my PHP environment, I have Magic Quotes turned off, and I use the
mysql_real_escape_string() function clean strings of SQL syntax before
inserting them into my database.
So the data stored in my database does not have escape characters in it.
Particularly, double and
It is quite possible (ie, I've done it) to install the PEAR modules you
need within your own web space. You just have to get the directory
structure and your include line right.
The PEAR system is just a bunch of php files so if you've got php you've
got all you really need.
--
... most
Thanks for the help Nathan. What I'm looking for though is how to
accept and read the incoming XML the way I was sending it in curl. I am
currently using that curl mechanism on the cli to connect to another
remote XML server successfully. I want to keep that side of the
equation the same. I
The incoming message to the server is:
POST /vendorXML.html HTTP/1.0
MIME-Version: 1.0
Content-type: text/html
Content-length: 114
Content-transfer-encoding: text
Request-number: 1
Document-type: Request
Interface-Version: Test 1.4
Connection: close
?xml version=1.0
On Sat, Mar 1, 2008 at 9:33 PM, Larry Brown
[EMAIL PROTECTED] wrote:
Thanks for the help Nathan. What I'm looking for though is how to
accept and read the incoming XML the way I was sending it in curl. I am
currently using that curl mechanism on the cli to connect to another
remote XML
You can get what you post either with:
$postText = trim(file_get_contents('php://input');
Or with:
$postText = $GLOBALS[HTTP_RAW_POST_DATA];
About HTTP_RAW_POST_DATA http://us2.php.net/manual/en/reserved.variables.php
Read the notes here http://us2.php.net/variables.predefined
It should be
On Sat, Mar 1, 2008 at 9:33 PM, Larry Brown
[EMAIL PROTECTED] wrote:
Thanks for the help Nathan. What I'm looking for though is how to
accept and read the incoming XML the way I was sending it in curl. I am
currently using that curl mechanism on the cli to connect to another
remote XML
On Sat, Mar 1, 2008 at 7:57 PM, [EMAIL PROTECTED] wrote:
when you run you phpinfo script that you mentioned
in your first post, do you see pear in one of the sections there (not
just
in the include path)?
A search on pear only yields this line:
include_path
This is what I was looking for. Thank you. I could not change the
client since that client is being used for other servers in its current
configuration. All I needed was a way to get to the XML string coming
in.
$postText = trim(file_get_contents('php://input');
worked perfectly. Now that
Hi all,
I've tried googling around to find some blogs with decent information
on whether Zend Eclipse is mature enough to make the jump over from
5.5.x just yet.
Admittedly, I've dropped Zend Studio as of late and been writing all
of my code in TextMate -- but at the end of the day when a
34 matches
Mail list logo