php-general Digest 20 Oct 2006 06:50:39 - Issue 4411
Topics (messages 243360 through 243371):
Re: User question for PHP
243360 by: Christian Heinrich
243361 by: Al
243362 by: Andy Hultgren
243369 by: Chris
Weird stack trace in error_log from PDOException
PHP List,
I have a system where the code parses the URL and creates objects based
on the classes named in the link.
In order to prevent a user typing in a URL that contains an object that
doesn't exist, and getting an error, I'm trying to set up an error
handler class, called ErrorHandler,
On Fri, 2006-10-20 at 15:50 +0900, Dave M G wrote:
I have a system where the code parses the URL and creates objects based
on the classes named in the link.
In order to prevent a user typing in a URL that contains an object that
doesn't exist, and getting an error, I'm trying to set up an
PHP List,
I took a snippet of code right off the php.net site to use trim on all
the elements of an array.
Theoretically, it should test if the element in an array is in turn
another array, and break it down to the next level until it gets to a
string it can use trim on.
This is the code:
On Fri, 2006-10-20 at 16:04 +0900, Dave M G wrote:
PHP List,
I took a snippet of code right off the php.net site to use trim on all
the elements of an array.
Theoretically, it should test if the element in an array is in turn
another array, and break it down to the next level until it
On Fri, 20 Oct 2006 15:49:14 +1000, Chris wrote:
Andy Hultgren wrote:
To whoever was asking this (sorry didn't see the original email):
Is it possible to have a PHP script execute as the user of the domain
instead of the webserver? So when I upload files through a PHP script
they are owned
On Fri, 20 Oct 2006 16:04:27 +0900, Dave M G wrote:
PHP List,
I took a snippet of code right off the php.net site to use trim on all
the elements of an array.
Theoretically, it should test if the element in an array is in turn
another array, and break it down to the next level until it
PHP List,
This problem is a little hard to describe. Please forgive me in advance
if it's not clear.
I have set up my .htaccess file to work with my PHP script to create
friendly URLs.
For example, the URL mysite.com/user/login will take the user to a page
where a user logs in.
It does
Chris skrev:
Patrik Jansson wrote:
Hello,
I'm having some difficulties with open_basedir. If I include the
prefix /home/web25637/ in open_basedir shouldn't it include every
directory within this? We're getting this error:
Warning: file_exists() [function.file-exists]: open_basedir
Is anyone aware of a PHP/MySQL app that would be used by telemarketing
staff to track calls, do follow-ups, allow scripting, etc.? We could
write something in house but we are pressed for time. I have been poking
around the web this morning, but have not found much.
TVMIA!
SugarCRM?
--
PHP List,
This problem is a little hard to describe. Please forgive me in advance
if it's not clear.
I have set up my .htaccess file to work with my PHP script to create
friendly URLs.
For example, the URL mysite.com/user/login will take the user to a page
where a user logs in.
Colin Guthrie wrote:
Patrik Jansson wrote:
I ran into problems with openbase_dir when using symlinks... They only
really reared their ugly head when I upgraded to 5.1.6 before that they
were OK (tho' if memory serves I had to add both the symlink location
and the directory it pointed to.
Is it possible to use php to check that the .css file in the html of a
web page is the correct one e.g. check if the file included in the html
is new.css.
I think I will have to write a regex but if anyone has any ideas (or
already has a regex to do this), it would be much appreciated.
Is it possible to receive information on a html site, such as the
language, date modified?
If so how would I go about doing this?
Thanks,
Marc
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
# [EMAIL PROTECTED] / 2006-10-20 15:50:32 +0900:
set_error_handler(ErrorHandler::handleError());
Inside my ErrorHandler, I have this:
public static function handleError($errno, $errstr, $errfile, $errline)
{
echo Hey dude! Error! . $errno . $errstr . $errfile . $errline ;
}
However, I
# [EMAIL PROTECTED] / 2006-10-18 17:23:53 +0200:
Is it possible to receive information on a html site, such as the
language, date modified?
If so how would I go about doing this?
Your question is very vague, so I'm taking the liberty of
interpretation.
-
# [EMAIL PROTECTED] / 2006-10-20 17:00:05 +0900:
header(Location: /);
header(/local/server/www/directory/);
Do you know that both headers are invalid?
--
How many Vietnam vets does it take to screw in a light bulb?
You don't know, man. You don't KNOW.
Cause you weren't THERE.
Edward Kay wrote:
Thanks for your suggestions John. At the moment, I do need to run it as a
CGI as I need different php.ini files for each virtual host.
For what it's worth, when you use PHP as a module, you can change almost
all settings in php ini on a per-virtual host basis using the Apache
Patrik Jansson wrote:
Anyway, are symlinks to blame here?
I've added the real path into open_basedir, I also removed the // error
but still I get the restriction message:
So then I changed the absolute path in Joomla from /home/... to
/usr/home/...
and now I don't get the error anymore so
Colin Guthrie wrote:
Well, I was never sure that it was a bug or not. I wasn't sure if it was
my distro's packaging and any custom patches it applies and also where
it was some x86_64 wierdness.
Recently (last week) it was confirmed to me that it was not x86_64 at
fault, but it was still my
Hi all, I am having issues with users not being able to post their details
to my site. The system uses sessions, so when they hit the index page a test
cookie is set thus:
setcookie('djst', 'test');
and then I test whether that cookie is set on the next page. If not, I
direct the users to an
The way you're setting cookies (without a time parameter), it's set to
expire at the end of the current session. Though it should work
regardless, try setting an expire time:
setcookie('djst', 'test', time()+3600); // expire in an hour
On 10/20/06, Dave Goodchild [EMAIL PROTECTED] wrote:
Hi
I noticed that this bug is already to be found in the bug
database.
This is exactly how I'm experiencing it:
http://bugs.php.net/bug.php?id=37556
In that report they link the reader to
http://bugs.php.net/bug.php?id=30188 which is also applicable.
Although I can't understand the last answer:
Thanks for the response,
I think I have solved the problem using the code in the attached text
document.
Thanks for the help,
Marc
Roman Neuhauser wrote:
# [EMAIL PROTECTED] / 2006-10-18 17:23:53 +0200:
Is it possible to receive information on a html site, such as the
language, date
On 10/20/06, Ivo F.A.C. Fokkema [EMAIL PROTECTED] wrote:
On Fri, 20 Oct 2006 15:49:14 +1000, Chris wrote:
Andy Hultgren wrote:
To whoever was asking this (sorry didn't see the original email):
Is it possible to have a PHP script execute as the user of the domain
instead of the webserver?
-- Forwarded message --
From: andrew newman [EMAIL PROTECTED]
Date: Oct 20, 2006 2:30 PM
Subject: Parsing and using URL variables
To: php-general-digest@lists.php.net
Hello
I am very new to PHP and I am trying to parse the values of variables
from a URL into a web page. to
On Oct 20, 2006, at 4:00 AM, Dave M G wrote:
PHP List,
This problem is a little hard to describe. Please forgive me in
advance if it's not clear.
I have set up my .htaccess file to work with my PHP script to
create friendly URLs.
[snip]
I thought it had something to do with setting
Hi everyone
I have a variable with UTF-8 text inside it and I want to convert this
text to windows encode, is it possible in very easy way ?
Thanks
---
Ahmad
http://www.v-tadawul.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
looks like your having fun ... but before you go building using
something that is going to cause you major security headaches go to this
site and read, read, read:
http://phpsec.org/
and remember NEVER TRUST USER INPUT (or data from *any* outside source);
currently
your example will
DOCUMENTATION php://input is not available with
enctype=multipart/form-data.
What I should do if I really need to get multipart data? I want to
implement my own form-data parser with PHP5. Can I at least turn off the
PHP's one to be able to use php://input with multipart?
--
PHP General
On Fri, 20 Oct 2006 23:24:14 +1000, chris smith wrote:
On 10/20/06, Ivo F.A.C. Fokkema [EMAIL PROTECTED] wrote:
On Fri, 20 Oct 2006 15:49:14 +1000, Chris wrote:
Andy Hultgren wrote:
To whoever was asking this (sorry didn't see the original email):
Is it possible to have a PHP script
I have PHP/PostgreSQL application were i got a search page with some items
to search, am building the search query on server side.
I need to display a paginated search and for this i need to get the total
count of lines matching the search before OFFSET/LIMITing my page, am i
obliged to repeat
On Fri, 20 Oct 2006 16:57:16 +0300, Ahmad Al-Twaijiry wrote:
Hi everyone
I have a variable with UTF-8 text inside it and I want to convert this
text to windows encode, is it possible in very easy way ?
Thanks
---
Ahmad
Hi Ahmad,
utf8_decode() will decode your string to ISO-8859-1.
On Fri, 20 Oct 2006 17:04:35 +0200, Fourat Zouari wrote:
I have PHP/PostgreSQL application were i got a search page with some items
to search, am building the search query on server side.
I need to display a paginated search and for this i need to get the total
count of lines matching the
# [EMAIL PROTECTED] / 2006-10-20 16:57:16 +0300:
I have a variable with UTF-8 text inside it and I want to convert this
text to windows encode, is it possible in very easy way ?
http://php.net/iconv
--
How many Vietnam vets does it take to screw in a light bulb?
You don't know, man. You
On 20 Oct 2006, at 02:00 , Dave M G wrote:
So... my question is, why is the /user portion of my URL being
retained as a directory?
You need RewriteEngine On and RewriteBase and RewriteCond and
RewriteRule, it sounds like.
Not really a php issue per se.
--
I wrote this song two hours
On Fri, 2006-10-20 at 17:22 +0200, Ivo F.A.C. Fokkema wrote:
On Fri, 20 Oct 2006 17:04:35 +0200, Fourat Zouari wrote:
I have PHP/PostgreSQL application were i got a search page with some items
to search, am building the search query on server side.
I need to display a paginated search
Robert Cummings wrote:
On Thu, 2006-10-19 at 23:58 -0500, Larry Garfield wrote:
That depends on what your data structure is, exactly, and what sort of
tree
structure you want on the other side. Please be more specific.
On Thursday 19 October 2006 09:08, Angelo Zanetti wrote:
Hi
On Fri, 2006-10-20 at 09:20 -0700, Jürgen Wind wrote:
for web browser:
// WooohoOO!
//
echo 'pre';
print_r( $tree );
True, but I do quick sample scripts from the command-line :D
Cheers,
Rob.
--
..
| InterJinn
The canonical PHP example of web-scraping:
?php echo file_get_contents('http://php.net/');?
fails on a machine I'm using.
I'm laying out here all the things I've done and eliminated, and it
got awfully long...
Short Version:
FC4 + LAMPP on 2 different private IP boxes at day job
?php echo file_get_contents('http://php.net/');?
takes only 2 seconds here.
w2k php5.14 FF1.5.0.7
--
View this message in context:
http://www.nabble.com/connectivity-weirdness-tf2481786.html#a6920671
Sent from the PHP - General mailing list archive at Nabble.com.
--
PHP General Mailing List
For what it's worth, for me telnet php.net 80 (then GET ...) takes ~25
seconds, most of which seems to be the reverse lookup. If I just telnet
directly to php.net's IP directly and do the same, it's instant. Doing
file_get_contents takes less than 1s numerically or not.
jon
(Replied directly
Marc Roberts wrote:
Thanks for the response,
I think I have solved the problem using the code in the attached text
document.
Thanks for the help,
Marc
Roman Neuhauser wrote:
# [EMAIL PROTECTED] / 2006-10-18 17:23:53 +0200:
Is it possible to receive information on a html site,
Hi all. I have an online events directory and am having some issues with
date calculations. I have a table of dates (next year) and an events table -
which have a many to many relationship and so use an intermediary mapping
table called dates_events. All good - when the user enters a single,
Dave Goodchild wrote:
Hi all, I am having issues with users not being able to post their details
to my site. The system uses sessions, so when they hit the index page a
test
cookie is set thus:
setcookie('djst', 'test');
and then I test whether that cookie is set on the next page.
Hello,
Regarding PHP5 bug #35296, http://bugs.php.net/bug.php?id=35296
I assume that it has been fixed in PHP5 for a while now (any version higher
than PHP 5.0.5 ).
Could someone tell me if PHP4 has been corrected as well ? in other word, what
is the oldest version of PHP4 that contains
On 10/21/06, Ivo F.A.C. Fokkema [EMAIL PROTECTED] wrote:
On Fri, 20 Oct 2006 23:24:14 +1000, chris smith wrote:
On 10/20/06, Ivo F.A.C. Fokkema [EMAIL PROTECTED] wrote:
On Fri, 20 Oct 2006 15:49:14 +1000, Chris wrote:
Andy Hultgren wrote:
To whoever was asking this (sorry didn't see the
Robert Cummings wrote:
On Fri, 2006-10-20 at 09:20 -0700, Jürgen Wind wrote:
for web browser:
// WooohoOO!
myself, I'm more partial to
// YeeHaw!
//
echo 'pre';
print_r( $tree );
True, but I do quick sample scripts from the command-line :D
Cheers,
Rob.
--
PHP
chris smith wrote:
On 10/21/06, Ivo F.A.C. Fokkema [EMAIL PROTECTED] wrote:
On Fri, 20 Oct 2006 23:24:14 +1000, chris smith wrote:
On 10/20/06, Ivo F.A.C. Fokkema [EMAIL PROTECTED] wrote:
To my experience, apache (with PHP running as www-data or nobody or
whatever) will not be
On 10/21/06, Jochem Maas [EMAIL PROTECTED] wrote:
chris smith wrote:
On 10/21/06, Ivo F.A.C. Fokkema [EMAIL PROTECTED] wrote:
On Fri, 20 Oct 2006 23:24:14 +1000, chris smith wrote:
On 10/20/06, Ivo F.A.C. Fokkema [EMAIL PROTECTED] wrote:
To my experience, apache (with PHP running
50 matches
Mail list logo