Re: [PHP] Session Problem

2007-02-20 Thread Fergus Gibson
Brad Bonkoski wrote: > How do you move from one page to the other? You have to pass the > session along, I believe.. > Something like: > $s = SID; // session contant > page2.php?$s You only need to pass the session identifier in the query string if you aren't using cookies. By default, sessions

[PHP] Re: Securing user table with sha function

2007-02-20 Thread Fergus Gibson
Haydar Tuna wrote: > 1) If you protect your site from SQL Injection, you must replace all quote > and blank character in your form data. (with string functions) A better approach is data inspection. For example, if you know a field should only ever contain letters, you can use ctype_alpha() to c

[PHP] Re: Securing user table with sha function

2007-02-20 Thread Fergus Gibson
Tim wrote: > Now moving on into other aspects of security :P I was thinking of a way to > secure my login inputs the best way possible. [...] Maybe I'm missing something, but why not simply inspect and clean input to ensure that it's always properly escaped and safe to send to your database? It s

Re: [PHP] counting hyperlink clicks in php

2007-02-20 Thread Fergus Gibson
Brad Bonkoski wrote: > I think the best way to do this would be to set an onClick (Javascript) > event handler for each of the links, and then use AJAX style stuff to > send the information to PHP on the server side, then PHP can log the > link that was clicked, and keep track of the most clicked l

Re: [PHP] css in mail()

2007-02-20 Thread Fergus Gibson
Sancar Saran wrote: > $mail=" > > > Title > ".$data." > > > Html content > > "; I stopped being a designer quite a long time ago, and I never learned how to compose HTML e-mail because I think it's a blight. I do, however, work with some talented designers, and they (and Google)

[PHP] Re: Change in 5.2.1 re. parsing of URL

2007-02-20 Thread Fergus Gibson
Lewis Kapell wrote: > http://www.mydomain.com/mypage.php/phonypage.pdf > > In this example there is a PHP script called mypage.php which serves > up a PDF. Putting the extra text at the end of the URL makes it > appear to the user's browser that the URL ends with '.pdf' rather > than '.php'. We

[PHP] Re: re another hand wringer

2007-02-20 Thread Fergus Gibson
jekillen wrote: > for($i = 0; $i < $flen; $i++) // now it works > { >array_push($edata, $_POST["a_$z"]); >print $_POST["a_$z"].''; // prints all values. >$z++; > }; I recommend you consider changing your loop to: for ($

[PHP] Re: WHERE problem

2007-02-20 Thread Fergus Gibson
How about this instead, Mike? "%s"-Omniversalism.com', $fortune[0] ); // some more code ?> MySQL is implemented in random code, so it can probably perform this operation faster, and this code is much cleaner. You may want to move away from mysql since it's essentially deprecated. I have switch

[PHP] Re: Securing user table with sha function

2007-02-20 Thread Haydar Tuna
Hello again, if you crypt your usernames, it happened many problems. As you know, if you crypt any string to SHA1, you don't decrypt again. You cannot use username in your application. in my many application, I have crpyted password , I haven't cryrpt usernames. Becuase I used username for

Re: [PHP] Re: WHERE problem

2007-02-20 Thread Németh Zoltán
2007. 02. 20, kedd keltezéssel 01.33-kor Fergus Gibson ezt írta: > How about this instead, Mike? > > // some code > > $fortune = mysql_query("SELECT text FROM fortunes ORDER BY RAND() LIMIT 1"); > $fortune = mysql_fetch_row($fortune); > $fortune = sprintf( > '"%s"-Omniversalism.com', > $fortune[

RE: [PHP] Re: Securing user table with sha function

2007-02-20 Thread Tim
> -Message d'origine- > De : Haydar Tuna [mailto:[EMAIL PROTECTED] > Envoyé : mardi 20 février 2007 10:34 > À : php-general@lists.php.net > Objet : [PHP] Re: Securing user table with sha function > > Hello again, > if you crypt your usernames, it happened many problems. > As you

RE: [PHP] Re: Securing user table with sha function

2007-02-20 Thread Tim
> -Message d'origine- > De : Fergus Gibson [mailto:[EMAIL PROTECTED] > Envoyé : lundi 19 février 2007 12:01 > À : php-general@lists.php.net > Objet : [PHP] Re: Securing user table with sha function > > Tim wrote: > > Now moving on into other aspects of security :P I was thinking of a

Re: [PHP] Re: Securing user table with sha function

2007-02-20 Thread Satyam
- Original Message - From: "Tim" <[EMAIL PROTECTED]> -Message d'origine- De : Haydar Tuna [mailto:[EMAIL PROTECTED] Envoyé : mardi 20 février 2007 10:34 À : php-general@lists.php.net Objet : [PHP] Re: Securing user table with sha function Hello again, if you crypt you

[PHP] Mozilla/Opera issue

2007-02-20 Thread Chris Aitken
Hi All, I am clutching at straws here, but I have come across an issue that I don't know whether it's a PHP problem in my coding, or HTML, or something entirely different but I've never seen this happen before, and this list has always helped me out in the past with odd problems. I am devel

Re: [PHP] Mozilla/Opera issue

2007-02-20 Thread Németh Zoltán
2007. 02. 20, kedd keltezéssel 21.40-kor Chris Aitken ezt írta: > Hi All, > > > > I am clutching at straws here, but I have come across an issue that I don't > know whether it's a PHP problem in my coding, or HTML, or something entirely > different but I've never seen this happen before, and th

Re: [PHP] Mozilla/Opera issue

2007-02-20 Thread clive
Your code is probably flawed,try putting some debug code in, echo out some variables and see what happens. -- Regards, Clive. Real Time Travel Connections {No electrons were harmed in the creation, transmission or reading of this email. However, many were excited and some may well have enj

[PHP] Install / update php rpm packages with FC6

2007-02-20 Thread edwardspl
Dear All, Mine is FC6 System... When I install the php rpm package, the problem as the following : [EMAIL PROTECTED] php]$ rpm -qa | grep "libc" glibc-common-2.5-3 libcap-devel-1.10-25 libcroco-0.6.1-2.1 glibc-headers-2.5-3 glibc-2.5-3 libcap-1.10-25 libc-client2006-2006e-2.fc6 glibc-devel-2.5-

[PHP] PDO database drivers

2007-02-20 Thread Sandy Keathley
I upgraded PHP 5.2 => 5.2.1 and added PDO support. It installed the SQLLITE driver by default. I wanted to add the MYSQL driver. I ran pecl install PDO_MYSQL and it failed with an autoconf error. I then downloaded the driver from pecl and unpacked it, but there were no instructions on installi

Re: [PHP] PDO database drivers

2007-02-20 Thread Jon Anderson
Sandy Keathley wrote: I upgraded PHP 5.2 => 5.2.1 and added PDO support. It installed the SQLLITE driver by default. I wanted to add the MYSQL driver. I ran pecl install PDO_MYSQL and it failed with an autoconf error. It probably depends on how you're installing PHP. If you're using a dist

Re: [PHP] Re: LOL, preg_match still not working.

2007-02-20 Thread Al
I sorry, what is the variable text in the message. Is there any text that is always constant, e.g., "This is a test of the emergency broadcast system." Inherently, your object seems obvious. The problem is that you are not providing enough examples. Show us some that you want to match AND som

[PHP] Problems processing UNIX timestamps in events directory

2007-02-20 Thread Dave Goodchild
Hi all. I have an odd problem. I am building an events directory and when users search, they provide a date range ie Feb 16 2007 to March 12 2007 as one of the options for searching. The system then creates an array of timestamps from this and then polls the database for all events whose lifetime

Re: [PHP] Classified Ads Script

2007-02-20 Thread Miles Thompson
On 2/19/07, Matt Arnilo S. Baluyos (Mailing Lists) < [EMAIL PROTECTED]> wrote: Hello everyone, I'm planning to put up a local classified ads website and I'm looking for an open-source script for this. I've already had some links from Google and Sourceforge but I'd like to get some opinions on

Re: [PHP] Problems processing UNIX timestamps in events directory

2007-02-20 Thread Arpad Ray
Dave Goodchild wrote: I have converted the user-friendly date output to timestamps to check and sure enough, when the user selects a start date before March 26 2007, March 26 2007 is output as: 1174863600 ...after that it becomes: 117486 ...a difference of 3600 Is this anything to do w

Re: [PHP] Language construct

2007-02-20 Thread Satyam
echo, include and a few others are language constructs because they are part of the language itself rather than being functions in the same category as regular functions are. This means that they are integral part of the language, just like 'if', or any operator +, *, etc, though they look pre

[PHP] Language construct

2007-02-20 Thread Balasubramanyam A
Hello all, I'm new to this group and I'm learning PHP. I want to know what is the exact definition for "Language Construct". Could someone please explain about this?

Re: [PHP] Re: Change in 5.2.1 re. parsing of URL

2007-02-20 Thread Lewis Kapell
We are already using the Content-type header (I should have mentioned that in my first message). And to say that the user's browser is misconfigured is no solution, since we don't have the ability to reconfigure it. If all of our users were on a local network there would be no problem. But t

[PHP] Latin letter problem!

2007-02-20 Thread Delta Storm
Hi, I'm building an simple CMS system. I have built almost everything but one thing buggs me... I have a MySQL database built for publishing news (Id,title,newsContent,timestamp). And I have a php web page that displays that content. The problem is with the charset, in the database the set

[PHP] Manual contradiction concerning string access?

2007-02-20 Thread Christian Heinrich
Dear list, today, I read in a german PHP forum about a problem with accessing an offset of a string. For example, if you have a variable like $string = "this is my string"; and you want to access the third character at once, I would suggest to use $string{2} so this will return the "i". T

Re: [PHP] WHERE problem

2007-02-20 Thread Jim Lucas
Mike Shanley wrote: I'd like to think I understood code a little better than this, but I've got a problem with my WHERE... I know it's the WHERE because I get a good result when I leave it out. And the random function is also working... I honestly can't figure it out. Thanks in advance for he

Re: [PHP] Manual contradiction concerning string access?

2007-02-20 Thread Németh Zoltán
AFAIK the english manual is more up to date, so I would follow that greets Zoltán Németh 2007. 02. 20, kedd keltezéssel 17.15-kor Christian Heinrich ezt írta: > Dear list, > > today, I read in a german PHP forum about a problem with accessing an > offset of a string. > > For example, if you ha

Re: [PHP] WHERE problem

2007-02-20 Thread Németh Zoltán
2007. 02. 20, kedd keltezéssel 08.17-kor Jim Lucas ezt írta: > Mike Shanley wrote: > > I'd like to think I understood code a little better than this, but I've > > got a problem with my WHERE... > > > > I know it's the WHERE because I get a good result when I leave it out. > > And the random func

Re: [PHP] WHERE problem

2007-02-20 Thread Jim Lucas
Németh Zoltán wrote: 2007. 02. 20, kedd keltezéssel 08.17-kor Jim Lucas ezt írta: Mike Shanley wrote: I'd like to think I understood code a little better than this, but I've got a problem with my WHERE... I know it's the WHERE because I get a good result when I leave it out. And the random f

Re: [PHP] WHERE problem

2007-02-20 Thread Jim Lucas
Németh Zoltán wrote: 2007. 02. 20, kedd keltezéssel 08.17-kor Jim Lucas ezt írta: Mike Shanley wrote: I'd like to think I understood code a little better than this, but I've got a problem with my WHERE... I know it's the WHERE because I get a good result when I leave it out. And the random f

[PHP] Understanding session variables with input field and register_global

2007-02-20 Thread Otto Wyss
I've an input field in a form and with register_global I can use this field in PHP as variable $username. Yet if I use a session variable $_SESSION['username'] = 'value' the variable $username gets the same value. On the other side when I enter a value in the input field, the session variabl

Re: [PHP] WHERE problem

2007-02-20 Thread Németh Zoltán
2007. 02. 20, kedd keltezéssel 08.28-kor Jim Lucas ezt írta: > Németh Zoltán wrote: > > 2007. 02. 20, kedd keltezéssel 08.17-kor Jim Lucas ezt írta: > >> Mike Shanley wrote: > >>> I'd like to think I understood code a little better than this, but I've > >>> got a problem with my WHERE... > >>> > >

Re: [PHP] WHERE problem

2007-02-20 Thread tg-php
Different strokes for different folks... Might I toss a new recommendation into the mix? SELECT text FROM fortunes ORDER BY RAND() LIMIT 1; = = = Original message = = = N~~meth Zolt~~n wrote: > 2007. 02. 20, kedd keltez~~ssel 08.17-kor Jim Lucas ezt ~~rta: >> Mike Shanley wrote: >>> I'd like

RE: [PHP] Understanding session variables with input field and register_global

2007-02-20 Thread Jay Blanchard
[snip] I've an input field in a form http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] WHERE problem

2007-02-20 Thread Jay Blanchard
[snip] Different strokes for different folks... Might I toss a new recommendation into the mix? SELECT text FROM fortunes ORDER BY RAND() LIMIT 1; [/snip] I suggested that yesterday. :) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Understanding session variables with input field and register_global

2007-02-20 Thread Németh Zoltán
2007. 02. 20, kedd keltezéssel 17.32-kor Otto Wyss ezt írta: > I've an input field in a form > > > and with register_global I can use this field in PHP as variable > $username. Yet if I use a session variable > > $_SESSION['username'] = 'value' > > the variable $username gets the same value.

RE: [PHP] Understanding session variables with input field and register_global

2007-02-20 Thread Brad Fuller
> -Original Message- > From: Otto Wyss [mailto:[EMAIL PROTECTED] > Sent: Tuesday, February 20, 2007 11:32 AM > To: php-general@lists.php.net > Subject: [PHP] Understanding session variables with input field and > register_global > > I've an input field in a form > > > and with register_

Re: [PHP] WHERE problem

2007-02-20 Thread Németh Zoltán
2007. 02. 20, kedd keltezéssel 11.39-kor [EMAIL PROTECTED] ezt írta: > Different strokes for different folks... > > Might I toss a new recommendation into the mix? > > SELECT text FROM fortunes ORDER BY RAND() LIMIT 1; > that's not new :) a couple of people recommended it earlier today/yesterda

Re: [PHP] Re: Change in 5.2.1 re. parsing of URL

2007-02-20 Thread Fergus Gibson
Lewis Kapell wrote: > We are already using the Content-type header (I should have mentioned > that in my first message). Hmmm. So you have a PHP script that sets the mimetype correctly and then outputs straight PDF data, but the user's browser does not accept it as a PDF because the extension of

RE: [PHP] WHERE problem

2007-02-20 Thread tg-php
Ah.. sorry Jay. I had like 8,000 emails today and must have missed some of the original responses. Or maybe I'm just trying to look smart by riding on your coat-tails. Either way, apologies for the repeated information. -TG = = = Original message = = = [snip] Different strokes for different

Re: [PHP] Re: Change in 5.2.1 re. parsing of URL

2007-02-20 Thread Lewis Kapell
Fergus Gibson wrote: Lewis Kapell wrote: We are already using the Content-type header (I should have mentioned that in my first message). Hmmm. So you have a PHP script that sets the mimetype correctly and then outputs straight PDF data, but the user's browser does not accept it as a PDF be

Re: [PHP] Manual contradiction concerning string access?

2007-02-20 Thread Robert Cummings
On Tue, 2007-02-20 at 17:21 +0100, Németh Zoltán wrote: > AFAIK the english manual is more up to date, so I would follow that > > greets > Zoltán Németh > > 2007. 02. 20, kedd keltezéssel 17.15-kor Christian Heinrich ezt írta: > > Dear list, > > > > today, I read in a german PHP forum about a pr

Re: [PHP] Change in 5.2.1 re. parsing of URL

2007-02-20 Thread Jim Lucas
Lewis Kapell wrote: If this has nothing to do with PHP, maybe you can explain why the behavior was broken when I upgraded from 5.2.0 to 5.2.1, and started working again the instant I reverted back to 5.2.0. No other configuration changes were made on the web server. ?? Thank you, Lewis Kap

RE: [PHP] Install / update php rpm packages with FC6

2007-02-20 Thread Peter Lauri
Do you really need to use an RPM package to install a PHP on FC. Why not "yum install php" instead... and for any extension you might want you just install that as well "yum install php-gd" as example. Best regards, Peter Lauri www.dwsasia.com - company web site www.lauri.se - personal web site w

Re: [PHP] Latin letter problem!

2007-02-20 Thread Dotan Cohen
On 20/02/07, Delta Storm <[EMAIL PROTECTED]> wrote: Hi, I'm building an simple CMS system. I have built almost everything but one thing buggs me... I have a MySQL database built for publishing news (Id,title,newsContent,timestamp). And I have a php web page that displays that content. The prob

RE: [PHP] Latin letter problem!

2007-02-20 Thread Peter Lauri
How are you setting the charset of the web page? Are you using header() or using html head section to set it? Best regards, Peter Lauri www.dwsasia.com - company web site www.lauri.se - personal web site www.carbonfree.org.uk - become Carbon Free -Original Message- From: Delta Storm [ma

Re: [PHP] Latin letter problem!

2007-02-20 Thread Dotan Cohen
On 20/02/07, Peter Lauri <[EMAIL PROTECTED]> wrote: How are you setting the charset of the web page? Are you using header() or using html head section to set it? First, the header() function. Then again in the tag, and a final time in the meta tag. This way cached pages and pages stored on di

[PHP] php forcing a post??

2007-02-20 Thread blackwater dev
I currently have an html page that posts to a cgi function. I need to interject some php in the middle. So, the form will post to itself, the php page will catch the post, check on thing and then pass along to the cgi page but the cgi page only handles posts. How can I still php in the middle a

[PHP] Re: php forcing a post??

2007-02-20 Thread Al
One simple way would be to have php send the page to the client. Then,it will look for the response. blackwater dev wrote: I currently have an html page that posts to a cgi function. I need to interject some php in the middle. So, the form will post to itself, the php page will catch the pos

Re: [PHP] Re: php forcing a post??

2007-02-20 Thread blackwater dev
Currently the form posts to /cgi/process Process does all sorts of stuff. I basically just want to step in the middle and do one small php thing and then send the form on to the process cgi script just like the form had posted it there. On 2/20/07, Al <[EMAIL PROTECTED]> wrote: One simple wa

RE: [PHP] php forcing a post??

2007-02-20 Thread Peter Lauri
fsockopen can probably help you with that http://www.php.net/fsockopen Best regards, Peter Lauri www.dwsasia.com - company web site www.lauri.se - personal web site www.carbonfree.org.uk - become Carbon Free -Original Message- From: blackwater dev [mailto:[EMAIL PROTECTED] Sent: Tuesd

RE: [PHP] php forcing a post??

2007-02-20 Thread Peter Lauri
Or cURL: http://php.net/curl Best regards, Peter Lauri www.dwsasia.com - company web site www.lauri.se - personal web site www.carbonfree.org.uk - become Carbon Free -Original Message- From: blackwater dev [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 20, 2007 9:45 PM To: php-gene

Re: [PHP] php forcing a post??

2007-02-20 Thread Stut
Peter Lauri wrote: Or cURL: http://php.net/curl Seems like a lot of work to me, not to mention added complexity. I highly doubt there's anything you can do in PHP that you can't do in the CGI script. If you really must do this, the easiest way would be to have the CGI call out to a PHP scr

Re: [PHP] php forcing a post??

2007-02-20 Thread Richard Lynch
On Tue, February 20, 2007 1:45 pm, blackwater dev wrote: > I currently have an html page that posts to a cgi function. I need to > interject some php in the middle. So, the form will post to itself, > the php > page will catch the post, check on thing and then pass along to the > cgi page > but t

Re: [PHP] Understanding session variables with input field and register_global

2007-02-20 Thread Richard Lynch
On Tue, February 20, 2007 10:32 am, Otto Wyss wrote: > I've an input field in a form > > > and with register_global I can use this field in PHP as variable > $username. You really really should turn OFF register_global for new code development... > Yet if I use a session variable > > $_SESSION['

[PHP] HTML form data to utf-8?

2007-02-20 Thread Jay Paulson
Just a general question that I don¹t know the answer to. I have users inputting data via an HTML form. I want to make sure that if they cut and paste from say Word that all the weird characters are converted to plain text (preferably utf-8 since that¹s what my database is). How would I go about

Re: [PHP] Manual contradiction concerning string access?

2007-02-20 Thread Richard Lynch
On Tue, February 20, 2007 10:15 am, Christian Heinrich wrote: > today, I read in a german PHP forum about a problem with accessing an > offset of a string. > > For example, if you have a variable like > > $string = "this is my string"; > > and you want to access the third character at once, I would

Re: [PHP] Latin letter problem!

2007-02-20 Thread Richard Lynch
I believe you want to send a query something like: mysql_query("SET CHARACTER SET 'utf-8'"); to convince PHP / MySQL client/server interaction to also be in UTF-8, on top of the internal storage engine storing things in UTF-8. More info about this SET stuff is at: http://dev.mysql.com/ I found t

Re: [PHP] Latin letter problem!

2007-02-20 Thread Richard Lynch
PS Mozilla-based browsers want your charset in the HTTP Content-type header IE and IE-knockoff browsers want your charset in the META tags. You have to do *both* to get all browsers to play nicely. Sorry. On Tue, February 20, 2007 10:03 am, Delta Storm wrote: > Hi, > > I'm building an simple C

Re: [PHP] WHERE problem

2007-02-20 Thread Mike Shanley
The reason I didn't go with the suggestions for this approach is that I want to accept new submissions to the database whose default id = 0. Thus, I can moderate them on the way in by giving them non-0 numbers. (I've changed the database row count call to fit the implementation since my posting

Re: [PHP] Problems processing UNIX timestamps in events directory

2007-02-20 Thread Jochem Maas
Dave Goodchild wrote: > Hi all. I have an odd problem. > > I am building an events directory and when users search, they provide a > date > range ie Feb 16 2007 to March 12 2007 as one of the options for searching. > The system then creates an array of timestamps from this and then polls the > dat

Re: [PHP] Language construct

2007-02-20 Thread Richard Lynch
On Tue, February 20, 2007 8:32 am, Balasubramanyam A wrote: > I'm new to this group and I'm learning PHP. I want to know what is the > exact > definition for "Language Construct". Could someone please explain > about > this? It's kind of like the "core language definition" of things such as: if (

Re: [PHP] Problems processing UNIX timestamps in events directory

2007-02-20 Thread Richard Lynch
On Tue, February 20, 2007 8:25 am, Dave Goodchild wrote: > I am building an events directory and when users search, they provide > a date > range ie Feb 16 2007 to March 12 2007 as one of the options for > searching. > The system then creates an array of timestamps from this and then Why would you

Re: [PHP] Mozilla/Opera issue

2007-02-20 Thread Richard Lynch
We'd have to see source, but odds are really good that you are doing something like this: $page = $_SESSION['page']; $query = "select stuff from reeds where .. limit 10 * $page"; $_SESSION['page'] = $_GET['page']; So you are updating the 'page' a bit "too late" Of course, you've got a few hundre

Re: [PHP] Classified Ads Script

2007-02-20 Thread Richard Lynch
On Mon, February 19, 2007 6:50 pm, Matt Arnilo S. Baluyos (Mailing Lists) wrote: > Hello everyone, > > I'm planning to put up a local classified ads website and I'm looking > for an open-source script for this. > > I've already had some links from Google and Sourceforge but I'd like > to get some o

Re: [PHP] WHERE problem

2007-02-20 Thread Richard Lynch
On Mon, February 19, 2007 2:32 pm, Bruce Cowin wrote: Mike Shanley <[EMAIL PROTECTED]> 20/02/2007 9:23:08 a.m. >>> > I'd like to think I understood code a little better than this, but > I've > got a problem with my WHERE... > > I know it's the WHERE because I get a good result when I leav

Re: [PHP] WHERE problem

2007-02-20 Thread Richard Lynch
On Tue, February 20, 2007 10:46 am, Németh Zoltán wrote: > 2007. 02. 20, kedd keltezéssel 11.39-kor > [EMAIL PROTECTED] > ezt írta: >> Different strokes for different folks... >> >> Might I toss a new recommendation into the mix? >> >> SELECT text FROM fortunes ORDER BY RAND() LIMIT 1; >> > > tha

Re: [PHP] WHERE problem

2007-02-20 Thread Richard Lynch
WHERE id > 0 would take care of that. Or, better yet, SEPARETE your 'id' field from your 'approved' field and don't try to be cheap with a one-byte (or even one-bit in some DBs) field. Over-loading the data field definition with dual meaning almost always turns into a problem down the line, in m

Re: [PHP] Change in 5.2.1 re. parsing of URL

2007-02-20 Thread Richard Lynch
On Mon, February 19, 2007 10:20 am, Lewis Kapell wrote: > There seems to be a behavior change introduced in 5.2.1 and I would > like > to know if it was deliberate. > > A couple of years ago, PHP introduced functionality that made it > possible to use a certain trick. I don't know how to describe

Re: [PHP] Re: remote fopen not working, despite allow_url_fopen = on

2007-02-20 Thread Richard Lynch
On Mon, February 19, 2007 9:43 am, alex handle wrote: > A minute ago i tried to run my test script (remote.php) on the shell > and the > remote fopen works!! > The problem must be within the php apache module or apache self. > Is there a way to debug the php apache module? Step #1. Create a page w

Re: [PHP] css in mail()

2007-02-20 Thread Richard Lynch
On Mon, February 19, 2007 9:03 am, Danial Rahmanzadeh wrote: > how can i use css with mail()? > thank u Don't. HTML enhanced (cough, cough) email is used predominantly by spammers, so if you do this, you'll be back here in a few days/weeks/months asking what you can do to get your email to get th

Re: [PHP] serialize() and special ANSI characters

2007-02-20 Thread Richard Lynch
Just a guess: You could perhaps run all your data through base64 encoding or somesuch to be certain the characters to be serialized are all "nice" On Mon, February 19, 2007 8:56 am, Youri LACAN-BARTLEY wrote: > Hi all, > > I'm just curious to find out if I'm the only person to have bumped > into

Re: [PHP] css in mail()

2007-02-20 Thread Richard Lynch
On Mon, February 19, 2007 10:56 am, Sancar Saran wrote: > On Monday 19 February 2007 17:03, Danial Rahmanzadeh wrote: >> how can i use css with mail()? >> thank u > > $data =''; > $fp = fopen ("site/themes/".$arrStat['theme']."/css/main.css","r"); > while (!feof($fp)) { $data.= fgets($fp, 16384);

Re: [PHP] HTML form data to utf-8?

2007-02-20 Thread Richard Lynch
On Tue, February 20, 2007 3:49 pm, Jay Paulson wrote: > Just a general question that I don¹t know the answer to. I have users > inputting data via an HTML form. I want to make sure that if they cut > and > paste from say Word that all the weird characters are converted to > plain > text (preferab

Re: [PHP] Another hand wringer

2007-02-20 Thread Richard Lynch
On Sun, February 18, 2007 3:06 pm, jekillen wrote: > iterator $i and given a_$i+1 names. If I test for the field names > on post literally, a_1, a_2, a_...n, the values are getting posted > properly. Save yourself a LOT of headaches and index-munging and just do this: Then: $a = $_POST['a'];

Re: [PHP] needed Yahoo like window for db query.

2007-02-20 Thread Richard Lynch
Use "View Source" on the Yahoo! page. There's no PHP in this question at all. It's all HTML, CSS, and JavaScript. On Sun, February 18, 2007 3:23 am, Chris Carter wrote: > > Need some help on getting some database result in a css popup like > yahoo. The > requirement is to open a div or a window

Re: [PHP] $_FILES path on client's machine?

2007-02-20 Thread Richard Lynch
On Sat, February 17, 2007 8:19 pm, Skip Evans wrote: > I get the feeling from not finding an argument for > the path on the client's machine for the complete > path of a file in $_FILES that it might not be > available for security reasons? Yes. It's none of your business where I store the file o

Re: [PHP] PHP Startup: Unable to load dynamic library

2007-02-20 Thread Richard Lynch
If those files exist, you have probably managed to mix-n-match extension versions with your PHP install. You can't do that. Extension versions and PHP version have to match. If those files don't exist at all, you forgot to ask for these extensions when you re-compiled PHP, or forgot to use your

Re: [PHP] Catch STDERR

2007-02-20 Thread Richard Lynch
On Sat, February 17, 2007 2:49 pm, Peter Lauri wrote: > I am executing exec('some cool command', $stdout, $exitcode); > > That is fine. I get what I in the beginning wanted. However, now I > need to > catch the STDERR that the command is generating as well. Some of you > might > tell me to redirect

RE: [PHP] LOL, preg_match still not working.

2007-02-20 Thread Richard Lynch
On Sat, February 17, 2007 8:50 am, Beauford wrote: > I've been over this a thousand times with various users on this list > and > escaping this and escaping that just doesn't matter. > > The error is that it thinks valid characters are invalid. In the case > of the > example I included, the ! and t

Re: [PHP] counting hyperlink clicks in php

2007-02-20 Thread Richard Lynch
On Sat, February 17, 2007 1:53 pm, clive wrote: > Denis L. Menezes wrote: >> Dear friends. >> >> I have a site where I have news headers. I wish to count the clicks >> on the >> news headers so that I can see how many times each of the the news >> has been >> viewed. This way I can show the "most v

Re: [PHP] Securing user table with sha function

2007-02-20 Thread Richard Lynch
Your DB still has to link user X with the other table which has their contact info, or the login is kinda useless, as you don't know who they are easily... I suppose that after authentication you could look up the user ID in a totally separate query... But now suppose they change their email addr

Re: [PHP] Re: Securing user table with sha function

2007-02-20 Thread Richard Lynch
On Mon, February 19, 2007 5:12 am, Fergus Gibson wrote: >> 4) if user forget his or her password, you can send email to the >> user when >> the user answer password protected question. > > Kinda impossible if the password is hashed, isn't it? What a strange > thought, though. I guess all those si

RE: [PHP] Re: Securing user table with sha function

2007-02-20 Thread Richard Lynch
On Tue, February 20, 2007 4:08 am, Tim wrote: > > >> -Message d'origine- >> De : Haydar Tuna [mailto:[EMAIL PROTECTED] >> Envoyé : mardi 20 février 2007 10:34 >> À : php-general@lists.php.net >> Objet : [PHP] Re: Securing user table with sha function >> >> Hello again, >> if you crypt

Re: [PHP] Quick organizational question...

2007-02-20 Thread Richard Lynch
As a beginner this is probably a Bad Idea to try to implement... You'll probably do it "wrong" anyway, on top of the mistakes you'll make building the application in the first place. Unless you have a lot of time to research MVC (Model View Controller) setups, and figure out what makes them tick,

Re: [PHP] reverse http authentication

2007-02-20 Thread Richard Lynch
On Fri, February 16, 2007 4:38 pm, Chris W wrote: > I want to read a page that is protected with http authentication. How > do I pass the user name and password to be authenticated with my php > code? If you can't get http://username:[EMAIL PROTECTED] to work, try http://php.net/curl -- Some pe

Re: [PHP] css in mail()

2007-02-20 Thread Sancar Saran
Hi, On Wednesday 21 February 2007 01:14, Richard Lynch wrote: > On Mon, February 19, 2007 10:56 am, Sancar Saran wrote: > > On Monday 19 February 2007 17:03, Danial Rahmanzadeh wrote: > >> how can i use css with mail()? > >> thank u > > > > > $data =''; > > $fp = fopen ("site/themes/".$arrStat['th

[PHP] New To PHP

2007-02-20 Thread Larry Chu
I am new to php and was trying to view the code below. I do see in my browser the question that is being asked, but for some reason the answer is not displayed. I am copying this from a book and am sure I have typed everything as it should be typed. Can you please tell mw what might be wrong?

Re: [PHP] New To PHP

2007-02-20 Thread Mike Shanley
Does your server support php? Also, some hosting services require that any file with php in it must end with .php ... At least, those are my two guesses... Larry Chu wrote: Q: This Creature can change color to blend in with its surroundings. What is its name? A: Chameleon'; ?>

[PHP] Re: New To PHP

2007-02-20 Thread Haydar TUNA
Hello, if you test your machine support PHP, you can use the following script. if this script properly execute, your machine can execute php script. if not you must support PHP.:) -- Haydar TUNA Republic Of Turkey - Ministry of National Education Education Technology Department Anka

Re: [PHP] Understanding session variables with input field and register_global

2007-02-20 Thread Haydar TUNA
Hello, Can you send your code? I can help you :) -- Haydar TUNA Republic Of Turkey - Ministry of National Education Education Technology Department Ankara / TURKEY Web: http://www.haydartuna.net ""Jay Blanchard"" <[EMAIL PROTECTED]>, haber iletisinde sunlari yazdi:[EMAIL PROTECTED] [sni

[PHP] Re: php forcing a post??

2007-02-20 Thread Haydar TUNA
Hello, You can use the tutorial in the following link :) http://www.phpbuilder.com/tips/item.php?id=239 -- Haydar TUNA Republic Of Turkey - Ministry of National Education Education Technology Department Ankara / TURKEY Web: http://www.haydartuna.net ""blackwater dev"" <[EMAIL PROTECTED]>

RE: [PHP] Catch STDERR

2007-02-20 Thread Peter Lauri
[snip] Do you need STDERR to go "out" to, err, wherever it goes, *AND* get it into your PHP script? Perhaps 'tee' (man tee) would let you do that. Or do you just need STDOUT in one variable, and STDERR in another, both in PHP? I think you could do something in shell to re-bind STDOUT to some ot

RE: [PHP] New To PHP

2007-02-20 Thread dhorton
Are you opening the .php file directly with your browser or via a web server? Does the web server have PHP support, and is it enabled? (PHP is server side, not browser side). Try creating the simple file on the webserver "phpinfo.php" containing just - ---

RE: [PHP] css in mail()

2007-02-20 Thread Peter Lauri
If you are just using the code snippet below you will probably get problems in Outlook and some other clients. This because you haven't set the proper header. But I actually need to assume you did send with a more sophisticated version. Otherwise KMAIL probably displayed it incorrectly as well. B

Re: [PHP] Catch STDERR

2007-02-20 Thread steve
What are your speed requirements? You can use the ssh functions can ssh2_exec into yourself. You can get the error stream separately then... After the connection is open, it is basically as fast as exec. But there is a hit on connection. I wouldn't use this in webpage environment, but I do use it

Re: [PHP] Re: Securing user table with sha function

2007-02-20 Thread Haydar Tuna
Hello, Yes you are right I have no idea what he is doing. I'm sorry. I write a book now about PHP and I want to help people anywhere in the world. I like helping people because I'm a linux user. I am membership of Linux Community in Turkey. As you know, linux users share their knowledges or

  1   2   >