[PHP] Strange 1 after include

2002-09-23 Thread César Aracena
Hi all, I’m wondering why does a number 1 appears in the output after the included text has been showed. I have a menu file for including and I just put ?=include(“menu.inc”)? but then the output shows: Back to Index 1 and I don’t have that number in either my script nor my include file. If

Re: [PHP] Strange 1 after include

2002-09-23 Thread Chase Urich
?=include(“menu.inc”)? tells PHP to echo out the result of include(“menu.inc”), which just happens to be a success code (1). The second for simply includes the file without echoing out anything. Chase On Mon, 2002-09-23 at 02:45, César Aracena wrote: Hi all, I’m wondering why does a number

RE: [PHP] Wrap content with a layout file

2002-09-23 Thread Michael Egan
I generally do the same - have a header and footer file which create a three column table. The content then fits into the central column. Other ways of doing this might be to use frames (though many disapprove of frames) or to use the iframe tag - the latter is something I only recently became

Re: [PHP] Wrap content with a layout file

2002-09-23 Thread Justin French
Generally I like to have header and footer, but you should look at the template engines out there (smarty for example) for some inspiration. This for example, would work fine for a WIDE range of pages: file.php?include=something: ? $include = $_GET['include']; $file =

[PHP] Re: ASP PHP

2002-09-23 Thread Ernani Joppert Pontes Martins
Try to search for asp2php at google.com []'s Ernani Nwakaji Eppie [EMAIL PROTECTED] escreveu na mensagem news:[EMAIL PROTECTED]... Does anyone know if there is a script that converts ASP to PHP?? Thanks in advance Nwakaji -- PHP General Mailing List (http://www.php.net/) To

[PHP] Function: return multple values

2002-09-23 Thread Faisal Abdullah
Hi people. Is it possible to return multiple values in a function. For instance, i want to do something like this: function calculate_money($sum) { // some hanky panky calculations return $type; return $amount; } Thanks! Sincerely, Faisal __ -- PHP

RE: [PHP] Help with mail...

2002-09-23 Thread John Holmes
It's just part of the rules. Variables are not evaluated when they are between single quotes, they are between double quotes. Echo 'This is $var'; Will output that string, literally. Echo This is $var; Will take the value of $var, if any, and place it in the string. ---John Holmes...

RE: [PHP] Function: return multple values

2002-09-23 Thread Jon Haworth
Hi Faisal, Is it possible to return multiple values in a function. For instance, i want to do something like this: function calculate_money($sum) { // some hanky panky calculations return $type; return $amount; } You have to return the values in an array, and use list() to break

[PHP] session_start function breaks flush function in 4.2.1

2002-09-23 Thread Chris Andrew
I use a script which initially sends a friendly message to a browser, and then goes about some lengthy processing. The browser is IE and I am aware of the 256 byte issue. The script worked nicely in php.4.1.1 but since installing 4.2.1, the flush function doesn't do its job. However, it works if

[PHP] RE: Update undefined List Values in DB

2002-09-23 Thread Tim Ward
make your checkboxes in the form an array with the index being the customer id. e.g. in the form ... foreach($customers as $cust) { echo(tr); ... echo(input type='hidden' name='status[{$cust[id]}]' value='0'); echo(input type='checkbox' name='status[{$cust[id]}]');

[PHP] Safe mode and directory permission

2002-09-23 Thread Rudolf Wolf
Hello, I'm working with Safe mode and I have a big trouble how the PHP is behaved. I have the web root and under them is directory, where my scripts are. This is my situation: rwxr-xr-x www www /var/www/htdocs Web root rwxr-xr-x www www /var/www/htdocs/test

RE: [PHP] mysql_num_rows error

2002-09-23 Thread John Holmes
I am new to php and that the folowing error: Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/tbonestu/public_html/smallimages.php i dont know what i am doing wrong here is the code: $db = mysql_pconnect(connect info);

[PHP] foreach, side effect or good behaviour?

2002-09-23 Thread Jean-Pierre Arneodo
Hi, $a=1; $b=$a; foreach(array(2,3) as $b); echo a=$a; // Print a=3 Is it the behaviour expected in a foreach loop? JP ___ Do You Yahoo!? -- Une adresse yahoo.fr gratuite et en français ! Yahoo! Mail : http://fr.mail.yahoo.com -- PHP

Re: [PHP] Replace linefeed/newline from text inputs with br tag?

2002-09-23 Thread David T-G
John, et al -- ...and then John Holmes said... % % If i have a textarea form input for users and they enter in return % spaces, % how can i replace the ascci chars with html tags? % % It'd be great if they had a function for this...they could call it % nl2br() or something... Yeah. It

RE: [PHP] Replace linefeed/newline from text inputs with br tag?

2002-09-23 Thread John Holmes
Okay, you got me on that one, but why do you need to remove the newlines? It should be stored in the database (if you're doing so) with the newlines and not the HTML breaks. You only use the nl2br() to output it on a web page, so who cares if the new lines are still there? The manual page

[PHP] == case-sensitive?

2002-09-23 Thread Hawk
I've never really payed attention to this before, but now I noticed that == is case-sensitive, how do I make it == with different cases ? Håkan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: foreach, side effect or good behaviour?

2002-09-23 Thread Stephan Seidt
It's good behavoiur because everytime even a reference gets a value, also the target which it is pointing on should get the same value. On Mon, 23 Sep 2002 12:57:56 +0200 (CEST), [EMAIL PROTECTED] (Jean-Pierre arneodo) wrote: Hi, $a=1; $b=$a; foreach(array(2,3) as $b); echo a=$a; //

Re: [PHP] == case-sensitive?

2002-09-23 Thread Krzysztof Dziekiewicz
I've never really payed attention to this before, but now I noticed that == is case-sensitive, how do I make it == with different cases ? if(strtolower($a) == strtolower($b)) -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

RE: [PHP] == case-sensitive?

2002-09-23 Thread Jon Haworth
Hi Hawk, I've never really payed attention to this before, but now I noticed that == is case-sensitive, how do I make it == with different cases ? Just force the case while you're comparing the two: if (strtolower($a) == strtolower($b)) { echo case-insensitive match; } else { echo no

RE: [PHP] == case-sensitive?

2002-09-23 Thread Ford, Mike [LSS]
-Original Message- From: Hawk [mailto:[EMAIL PROTECTED]] Sent: 23 September 2002 12:33 To: [EMAIL PROTECTED] Subject: [PHP] == case-sensitive? I've never really payed attention to this before, but now I noticed that == is case-sensitive, how do I make it == with different

Re: [PHP] Replace linefeed/newline from text inputs with br tag?

2002-09-23 Thread David T-G
John, et al -- ...and then John Holmes said... % % Okay, you got me on that one, but why do you need to remove the In my case, I had a newline-delimited file of field@@data field@@data field@@data and when the data had an embedded newline like comment@@this is a long comment

[PHP] Confused

2002-09-23 Thread Rankin, Randy
I have two MySQL tables, groups and users: groups: group_id, group_name users: user_id, user_name, group_id, etc. I would like to produce one table for each group which will list all the members for that particular group. For example: Blue (group_id 1) Tom

RE: [PHP] Confused

2002-09-23 Thread M . A . Bond
Nope, Do a select like so: Select user_name, group_name from users,groups where users.group_id=groups_id order by group_name; Then do a php loop (you'll need to find the eact php commands, this is just an example): While (!$results-EOF) { If ($results[group_name]!=$old_groupname) {

RE: [PHP] mysql_num_rows error

2002-09-23 Thread M . A . Bond
I am new to php and that the folowing error: Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/tbonestu/public_html/smallimages.php i dont know what i am doing wrong here is the code: $db = mysql_pconnect(connect info);

RE: [PHP] mysql_num_rows error

2002-09-23 Thread Jon Haworth
Hi Nick, I am new to php and that the folowing error: Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/tbonestu/public_html/smallimages.php i dont know what i am doing wrong here is the code: $db = mysql_pconnect(connect info); Along with

[PHP] URL Rewriting

2002-09-23 Thread Bill Farrell
Greetings, all, I've been using PHP for a couple of years now and only recently (since upgrading to RH7.3) began to experience an odd problem. When navigating around my site or when I run HT://Dig across it the links are suddenly being rewritten back as

[PHP] How do I use a Javascript variable in PHP?

2002-09-23 Thread Tom
Hi all, I hope this is the right place to pose my question, so here goes: - I have a javascript function called calcMonth() and given a number it will return a date i.e. month = calcMonth( 57 ) - month will be 'sept 2002' The problem I`m having is at the beginning of my PHP file I`m

RE: [PHP] URL Rewriting

2002-09-23 Thread Jon Haworth
Hi Bill, I've been using PHP for a couple of years now and only recently (since upgrading to RH7.3) began to experience an odd problem. When navigating around my site or when I run HT://Dig across it the links are suddenly being rewritten back as

Re: [PHP] How do I use a Javascript variable in PHP?

2002-09-23 Thread Support @ Fourthrealm.com
Tom, JavaScript is a client side language, while PHP is server side. This means that the PHP is parsed and evaluated before it ever reaches the surfers browser. And since the JavaScript variable will not be available until it is created by the browser, there is no way to interact with it.

php-general Digest 23 Sep 2002 13:42:11 -0000 Issue 1602

2002-09-23 Thread php-general-digest-help
php-general Digest 23 Sep 2002 13:42:11 - Issue 1602 Topics (messages 117221 through 117272): Specify authentication for SMTP mailserver? 117221 by: Joseph Szobody 117241 by: Manuel Lemos 117242 by: Pablo Oliva Re: mysql password function 117222 by: John

[PHP] How long do sessions last

2002-09-23 Thread DonPro
Hi, If I use sessions (not session cookies) by issuing a session_start() and then log in to an area of my web site, I understand that the session will last until either I close my browser or issue a session_unset() followed by a session_destroy(). If I log in and walk away from my PC, will the

[PHP] Re: How do I use a Javascript variable in PHP?

2002-09-23 Thread Ivo
You could do this ONLY by passing the var to a new URL with the desired php (your script). Otherwise the php will be executed (on the server) before JS (which will be executed on the client after receiving the php result page) regards Ivo Tom [EMAIL PROTECTED] wrote in message [EMAIL

[PHP] Re: Function: return multple values

2002-09-23 Thread Ivo
You can only as an array: function calculate_money($sum) { // some hanky panky calculations $myArr[] = $type; $myArr[] = $amount; return $myArr; } or shorter: function calculate_money($sum) { return array($type, $amount); } Faisal Abdullah [EMAIL PROTECTED] wrote in message

[PHP] Non-functioning db 'include'

2002-09-23 Thread Andre Dubuc
I've streamlined all files by using an include for db access. Everything works except the main registration file which is set to https. When I 'include' a file, the db access doesn't work: all other input that accesses the db does, except for one that first calls a 'randomizer' function,

[PHP] Re: session_start function breaks flush function in 4.2.1

2002-09-23 Thread Ivo
Flush is not reliable to do what is supposed for different reasons explained in http://www.php.net/manual/en/function.flush.php If you want to omit session_start you could substitude it with $_SESSION['whatever_name'] = 'myvqlue'; Note: Do not use global $_SESSION regads Ivo Chris Andrew

Re: [PHP] Non-functioning db 'include'

2002-09-23 Thread Geoff
Once you go to https://www.yoursite.com you are at a completely new url as far as the browser is concerned so you need to include using the full http://www.yoursite.com/yourinclude.inc syntax or throw another copy of your include db file in your directory for secure serving Not sure if this is

[PHP] 0 byte session files.

2002-09-23 Thread jacob
Hello, I run a site that operates across 4 load balanaced servers and we seem to be getting a problem where session files are created with 0 bytes (contain no data) on 2 of the 4 servers. All the servers are FreeBSD 4.5 running Apache 1.3.26 and PHP 4.2.3. Any suggestions would be

[PHP] How do i assign Integers only and not real numbers?

2002-09-23 Thread Tom
Hi all, I have a line of code that assigns a new year number: - $years = $years + ( $themonth / 12 ); but sometimes $years == 1998.08 or $year == 2002.75 etc... I cant find anything like a round() or floor() function in PHP so that year would be 1998 or 2002 only. Does anyone know

RE: [PHP] How do i assign Integers only and not real numbers?

2002-09-23 Thread M . A . Bond
You could cast it to an int, although the manual warns that you can get spurious errors upon casting an unknown fraction, so be careful. $year= (int) ($years); Mark -Original Message- From: Tom [mailto:[EMAIL PROTECTED]] Sent: 23 September 2002 15:47 To: [EMAIL PROTECTED] Subject:

Re: [PHP] How long do sessions last

2002-09-23 Thread 1LT John W. Holmes
If I use sessions (not session cookies) by issuing a session_start() and then log in to an area of my web site, I understand that the session will last until either I close my browser or issue a session_unset() followed by a session_destroy(). If I log in and walk away from my PC, will the

Re: [PHP] 0 byte session files.

2002-09-23 Thread 1LT John W. Holmes
I ran into a problem with sessions on sourceforge, which uses load balancing. What's probably happening for you is that each server is looking in it's own /tmp directory for the sessions. So, a user logs on from a page on Server A, which creates a good session file on Server A for the user. Now,

RE: [PHP] How do I use a Javascript variable in PHP?

2002-09-23 Thread kale
You cann't from php but you can from javascript. For exemple: file - script language=JavaScript Function insert_value(){ Document.form_name.text_box_name.value = javascript_value; } /script form method=post name=form_name input

Re: [PHP] How do i assign Integers only and not real numbers?

2002-09-23 Thread Support @ Fourthrealm.com
Hi Tom, Try this: $years = round($years + ( $themonth / 12 )); From the manual: float round ( float val [, int precision]) Returns the rounded value of val to specified precision (number of digits after the decimal point). precision can also be negative or zero (default). ceil() and floor()

Re: [PHP] Create Thumbnails from image

2002-09-23 Thread -=| Julien Bonastre |=-
OMG.. This is the second question tonight I answer that I was just working on today :-p hah.. Ok.. simple.. here's my code I used today for www.operation-scifi.com/lobby Thing is.. It's about as understandable to other's as hieroglyphics.. Therefore.. a simple solution.. do this: ?

Re: [PHP] Confused

2002-09-23 Thread -=| Julien Bonastre |=-
well it depends how you want to go about it.. I have done something exactly like this, this morning.. :-p Firstly.. you can use a normal SQL SELECT statement, but use GROUPing to seperate the groups in this case and ORDER them alphabetically or something.. Next.. You can do something like

[PHP] Visual Studio .NET as PHP IDE

2002-09-23 Thread Chris Boget
Does anyone use VStudio .NET as your IDE in developing PHP Scripts? If so, have you found a way to make it so that it understands PHP? In particular color coding and the understanding of where functions start and end (for the solution explorer, etc). I'm starting to get into C# and I'd like to

Re: [PHP] Redirection

2002-09-23 Thread -=| Julien Bonastre |=-
Yes that's right.. It's a standard HTTP/1.0 command I'm pretty sure so yeah. Actually referring to the rfc docs it could date back to even eariler HTTP standards too.. Hmm.. Yeah just don't send anything but header's and you can successfully redir. with that header(Location: xxx); function..

Re: [PHP] Non-functioning db 'include'

2002-09-23 Thread Andre Dubuc
Thanks Geoff, I tried what you suggested, but now the db burps the stuff back. Perhaps, for two lousy lines of code, I'll leave it as it is. Too much trouble to figure why it doesn't like it without actually having the site live. Right now everything passes through 'localhost' which has been

Re: [PHP] How do i assign Integers only and not real numbers?

2002-09-23 Thread 1LT John W. Holmes
If you end up using floor(), watch for floating point errors. You could expect your division to come out to a whole number, say 12, but be represented by 11.999 in the computer. So that'll floor() to 11. You can add a fluff to your division to counteract this: $years = floor($years +

Re: [PHP] Visual Studio .NET as PHP IDE

2002-09-23 Thread Chris Boget
try jext ... http://jext.org has a good PHP code browser and can colourise C# and PHP. I appreciate the suggestion but I wanted to know specifically about using VStudio .NET as an IDE for PHP. Don't know what other features you'd want for C# ... In VStudio .NET, the RAD features, for

[PHP] MySQL vs. basic text file

2002-09-23 Thread Doug Parker
often i use text files at my data sources, delimted by the | symbol. i simply delimit the fields of each line, then when i need to open them, i open the text file, populate an array with each line, then explode the fields for each to get the corresponding values. i use this method for

RE: [PHP] MySQL vs. basic text file

2002-09-23 Thread Steve Bradwell
Well, one major advantage I have found using MySQL verses txt files is the simple implementation of transactions, if you are doing multiple transactions that are related, it is nice to simply rollback all other statements if one fails or commit if they work. Of course you can do this other ways

Re: [PHP] MySQL vs. basic text file

2002-09-23 Thread Steve Werby
Doug Parker [EMAIL PROTECTED] wrote: i was wondering if there is anything i'm not thinking of that perhaps would push me to favor using php and mysql instead of the plain old text file. It sounds like you're basically asking why one would want to use a relational database. Standardization,

Re: [PHP] MySQL vs. basic text file

2002-09-23 Thread John S. Huggins
I was doing this too with good old AWK CGI scripts and text data files. Once I imported the data into MySQL I said, Well this is not much benefit. Then I started sorting. Then I accessed the information from a different application. Then I wrote a maintenance application so my customer could

[PHP] file reading/writing question.

2002-09-23 Thread Tim Nields
I'm using 4.2.2 on a Linux 7.1 system. The problem that I am encountering is copying the contents out of a pdf file and writing them to a new file. I've tried fopen() in concert with fread() and fwrite() with no success. The file is created, but the file size is markedly smaller. I've also

RE: [PHP] How do i assign Integers only and not real numbers?

2002-09-23 Thread Tom Callaghan
Thanks for the answers all, I`ve combined the floor and the precision answer and it does exactly what I want it to do. Cheers, Tom -Original Message- From: 1LT John W. Holmes [mailto:[EMAIL PROTECTED]] Sent: 23 September 2002 16:24 To: Tom; [EMAIL PROTECTED]; Support @ Fourthrealm.com

RE: [PHP] MySQL vs. basic text file

2002-09-23 Thread David Buerer
Speed Accessability Features Security Performance Simplicity Reusability Indexing Record-Locking To name a few. however, in your situation, it's an existing application which is working great and which no one has any complaints over. If it ain't broke, don't fix it. For your next application,

[PHP] open_basedir and ..?

2002-09-23 Thread Thomas -Balu- Walter
I am not sure how open_basedir restricts myself. In fact I have problems with files that begin with ../. I can not include those files, and get the following Warning: open_basedir restriction in effect. File is in wrong directory in

[PHP] Disabling cookies per website

2002-09-23 Thread Richard Fox
Is there a way to disable cookies not for all sites but on a per site basis? If I do an ini_set() on session.use_cookies will all sites be afftected or only the site I am on? Thanks, Rich

[PHP] Searching a db

2002-09-23 Thread Joshua E Minnie
Hey all, I am looking for a way to search a MySQL DB based on a users input string. The string would be searched on particular fields in my DB, which is already setup. The problem I am having is that I want to be able to return strings that match all *or* part of their string. Right now it

[PHP] PHP and JavaScript

2002-09-23 Thread skitum
Hi all, The following code will drive me mad coz it always shows the JavaScript functions and I'd like know why: ? if(isset($validar)) { $clinom=strlen($clinombre); $clinif=strlen($clinifcif); $clidir=strlen($clidireccion); $cliloc=strlen($clilocalidad); $clipro=strlen($cliprovincia);

[PHP] passing by reference via the variable arg list

2002-09-23 Thread Trevor Dowling
Can anyone help with this? I am relativly new to PHP and am trying to use variable numbers of parameters to functions using the func_get_arg(). However, I am unable to determine the correct syntax for passing by reference via the variable arg list. Trevor /* This Works Fine */ function

[PHP] freetype - problems with true type and transprency

2002-09-23 Thread andy
Hi there, I am trying to put text into an image. There are some problems where I do not find a solution for. The image is a jpg and stored on the filesystem. Now I would like to create a stamp in trutype font verdana with a name. Just the text on the image. I experianced following problems: o

[PHP] Error with file upload: No file uploaded in Unknown on line 0

2002-09-23 Thread Jason Young
I have some code that a user can set a description about an item to be posted, and then add some image files of the item. Its a 3x3 frame of input type=file fields, along with an 'include' line for each one.. only selecting a file with the 'Browse' button, or entering a website manually will

[PHP] Re: Searching a db

2002-09-23 Thread Joseph Szobody
Joshua, I learned a ton by reading this tutorial. See if it helps... http://www.zend.com/zend/tut/tutorial-Ferrara.php Joseph Joshua E Minnie [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hey all, I am looking for a way to search a MySQL DB based on a

[PHP] Why my php pages are cached in browsers?

2002-09-23 Thread Raphael Hamzagic
Hi, In browsers, my php pages are cached. All the code that is returned by php are stored. In version 4.1 this not ocurred, anybody can help me? Thanks Rapha -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] right name for IfModule bla.c

2002-09-23 Thread Andreas Hasenack
What is the right name to use in apache's (2.0.41-dev) IfModule directive to test if the php4 module is loaded? I'm including the file below via httpd.conf's Include statement but the part between the IfModule is being completely ignored: Directory /srv/www/default/html/acid AllowOverride

[PHP] How to get count of dimensions in multi array?

2002-09-23 Thread Stefan
Hello, I´m trying to figer out how to get the number och dimensions of a array.. It isn´t the problem to get the count of elements with count(), it´s the number of dimensions i am stuck at :( Any tips would be appreciated. Best regards, Stefan -- PHP General Mailing List

Re: [PHP] session_start() -- no more output

2002-09-23 Thread Hans Wilmer
On Sun, Sep 22, 2002 at 06:03:50PM -0500, Michael Sims wrote: ?php session_register(bunt); phpinfo(); ? This is just a simple example. The problem is that the script produces no output at all when called with the browser. Is it possible that display_errors is set to Off in your

[PHP] Re: How to get count of dimensions in multi array?

2002-09-23 Thread nicos
Use a foreach syntax. -- Nicos - CHAILLAN Nicolas [EMAIL PROTECTED] www.WorldAKT.com - Hébergement de sites Internet Stefan [EMAIL PROTECTED] a écrit dans le message de news: [EMAIL PROTECTED] Hello, I´m trying to figer out how to get the number och dimensions of a array.. It isn´t the

[PHP] Sockets

2002-09-23 Thread Martin W Jørgensen
Is it possible to read and write to multiple sockets at once with php? Can anyone please answer that question? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Import Stamp PDF's

2002-09-23 Thread Jerry
In article [EMAIL PROTECTED], [EMAIL PROTECTED] (Miles Thompson) wrote: Each evening I distribute a newsletter to approx 500 subscribers, and I want to stamp each copy I send with the name, email address and subscriber number of the recipient. I've not done any programmatic PDF

[PHP] Problem uploading a file (bug in PHP 4.2.3 !?) worked with 4.2.2

2002-09-23 Thread Jose Fandos
Hi, I was working on some code and couldn't get the following form to return anything under Windows XP with Apache 1.3.26 and PHP 4.2.3. I've just tried in a Solaris machine with same versions of Apache and PHP and it works just fine. Same with a Linux machine running Red Hat and same versions

[PHP] in a logic loop!

2002-09-23 Thread Naintara Jain
I have a logic problem: I have a complicated query. The main thing is that I have an ID, and for a particular ID, I may have between 1 to 3 rows returned. The rows returned are variable, that is for 1 particular ID there might just be 1 row and at a later time it may have 3 rows. But what I

[PHP] any string function to...

2002-09-23 Thread Taylor York
Is there any string function to put backslashes on any characters that are used in regular expressions? IE ()[];.^*$ etc. Thank you, Taylor -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Sockets

2002-09-23 Thread Philip Hallstrom
Yes. See the online manual notes in the Socket Functions section for links to examples. On Mon, 23 Sep 2002, Martin W Jørgensen wrote: Is it possible to read and write to multiple sockets at once with php? Can anyone please answer that question? -- PHP General Mailing List

[PHP] date functions

2002-09-23 Thread Patrick
i got 2 dates and i want to know how many minutes between em,, like: $date1 = date(Y-m-j H:i); $date2 = date(Y-m-j H:i, strtotime(now) + 1800); $minutes = date_something($date1, $date2); echo there are $minutes between, $date1 and $date2; regards patrick -- PHP General Mailing List

Re: [PHP] Problem uploading a file (bug in PHP 4.2.3 !?) worked with 4.2.2

2002-09-23 Thread 1LT John W. Holmes
What are the settings for upload_tmp_dir and file_uploads in the php.ini on the windows box? Does the Apache user have permission to write to that directory if it's valid? ---John Holmes... - Original Message - From: Jose Fandos [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday,

Re: [PHP] date functions

2002-09-23 Thread Support @ Fourthrealm.com
Patrick Off the top of my head... Convert both date1 and date2 to unix timestamps, and subtract one from the other. That will give you the number of seconds between them. Then, convert to hours, minutes, etc as required. Peter At 10:38 PM 9/23/2002 +0200, Patrick wrote: i got 2 dates and

Fw: [PHP] How to get count of dimensions in multi array?

2002-09-23 Thread Kevin Stone
Here.. I wrote this simple recursive function for a project a while back. Enjoy.. ? echo matrixdepth($myarray); function matrixdepth($array, $depth = 1) { foreach ($array as $key = $val) { if (is_array($array[$key])) { $depth++;

RE: [PHP] Problem uploading a file (bug in PHP 4.2.3 !?) worked with 4.2.2

2002-09-23 Thread Jose
I did go back to PHP 4.2.2 to double check and it doesn't work there either. -Original Message- From: Jose Fandos [mailto:[EMAIL PROTECTED]] Sent: 23 September 2002 21:12 To: [EMAIL PROTECTED] Subject: [PHP] Problem uploading a file (bug in PHP 4.2.3 !?) worked with 4.2.2 Hi,

[PHP] Re: [PHP-DB] advise needed for 'authorized only' site

2002-09-23 Thread Peter J. Schoenster
On 23 Sep 2002 at 8:14, [EMAIL PROTECTED] wrote: I have set up a section of my company site for use by authorized dealers only. I am currently using mysql authorization, which works for the first page, but if someone were to type in the url of an underlying page they would be able to get in

RE: [PHP] Problem uploading a file (bug in PHP 4.2.3 !?) worked with 4.2.2

2002-09-23 Thread Jose
Hi, The upload_tmp_dir in php.ini: ; Temporary directory for HTTP uploaded files (will use system default if not ; specified). ;upload_tmp_dir = So it uses c:\windows\temp And file upload: ; Whether to allow HTTP file uploads. file_uploads = On The directory is valid and Apache should have

Fw: [PHP] date functions

2002-09-23 Thread Kevin Stone
You should be working with UNIX timestamps here. Convert the dates to human readble only after you've done the calcuations. -Kevin - Original Message - From: Patrick [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, September 23, 2002 2:38 PM Subject: [PHP] date functions i got

Re: [PHP] algorythm question

2002-09-23 Thread Barýþ
ok, now it's clear why i must use '|' instead of '+'. i still couldn't get what happens with bits but you don't have to explain more. i know that it's about bitwise operators, and how they handle numbers. no! ok! i just got it! thank you again. --- bob parker [EMAIL PROTECTED] wrote: Couple

[PHP] Frusration using Sessions!!!

2002-09-23 Thread Don
Hi, I am having trouble with sessions. I've created a user login/password section that uses session variables. Within this section, I have a form where the user enters data and submits. When the user clicks on the Browser back button, they should get back to the form with their data intact.

Re: [PHP] Re: session_start function breaks flush function in 4.2.1

2002-09-23 Thread Michael Sims
Chris Andrew [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I use a script which initially sends a friendly message to a browser, and then goes about some lengthy processing. The browser is IE and I am aware of the 256 byte issue. The script worked nicely in

[PHP] Mail problem with more than 1k users

2002-09-23 Thread Research and Development
Hello. I wrote a PHP script that will pull records from a database (emails) and then mail something to the emails in the result set. Pretty simple and it worked. Now that the database has over 1 thousand records I began to experience performance problems. I figured that my problem was that

[PHP] backup script

2002-09-23 Thread Research and Development
Hello. Can someone point me to an example of a script that backs up de database and the web directory and its files? Thanks in advance. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] backup script

2002-09-23 Thread Peter Houchin
do ya self a fav. and look @ phpbuilder, phpwizard etc and and a look will take ya 2 mins to find what your looking for :) -Original Message- From: Research and Development [mailto:[EMAIL PROTECTED]] Sent: Tuesday, 24 September 2002 9:18 AM To: PHP General List Subject: [PHP] backup

RE: [PHP] Mail problem with more than 1k users

2002-09-23 Thread Mark Charette
I've had no problems using qmail-inject and MySQL to send over 100K emails in a day. I doubt it's an MySQL problem unless you've done something drastically wrong; perhaps you're bandwidth limited? -Original Message- From: Research and Development [mailto:[EMAIL PROTECTED]] Hello. I

Re: [PHP] any string function to...

2002-09-23 Thread Oscar F
Taylor, You can use: quotemeta($string) for . \\ + * ? [ ^ ] ( $ ). hth. Oscar F.- Taylor York wrote: Is there any string function to put backslashes on any characters that are used in regular expressions? IE ()[];.^*$ etc. Thank you, Taylor -- PHP General Mailing List

[PHP] Encryption Question

2002-09-23 Thread Tom Ray
I want to compare a password to a encrypted password stored in my mySQL database using password('password'), what's the best way to compare the two? Encrypted the password sent by the user and compare or pull the password from the database based on username, decrypt it and then compare? --

RE: [PHP] Encryption Question

2002-09-23 Thread John Holmes
I want to compare a password to a encrypted password stored in my mySQL database using password('password'), what's the best way to compare the two? Encrypted the password sent by the user and compare or pull the password from the database based on username, decrypt it and then compare?

[PHP] Need help.

2002-09-23 Thread Rekha Das
I am using php-4.1.2 and apache-1.3.26. I am allowing users to download files from my site. The problem is that the file is not downloded fully. After downloading say 84%, the counter stops and download manager says that the download is complete. This problem is intermittent. Sometimes the file

[PHP] PHP.exe crash Problem

2002-09-23 Thread simanhew
Hi all, One of my pages always crashes php.exe on Windows XP. I can not find any logic error in my code. Does anybody have any experience to handle the problem like this ? Thanks in advance, Siman -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

[PHP] Another Encryption question

2002-09-23 Thread Tom Ray
I dipped into mcrypt about a month or so, and did this script back then. I had it working, it would kick out the encrypted data for me but today when I test it I get a Fatal error: Call to undefined function: mcrypt_create_iv() in test2.php on line 3. And I don't understand why...any help

[PHP] Crypt() =or= md5()

2002-09-23 Thread Anthony Ritter
I get the following line when trying to use the crypt() function in php .. Fatal error: Call to undefined function: crypt() in c:\program files\apache group\apache\htdocs\handleform1.php on line 16 However, when I

[PHP] Re: PHP.exe crash Problem

2002-09-23 Thread nicos
We need to see the page. -- Nicos - CHAILLAN Nicolas [EMAIL PROTECTED] www.WorldAKT.com - Hébergement de sites Internet Simanhew [EMAIL PROTECTED] a écrit dans le message de news: [EMAIL PROTECTED] Hi all, One of my pages always crashes php.exe on Windows XP. I can not find any logic

Re: [PHP] PHP.exe crash Problem

2002-09-23 Thread Oscar F
That's happened to me while trying to run a PHP script that handles Form-based file uploading. The scripts work fine on *nix enviroments. Any toughts?. Oscar F.- simanhew wrote: Hi all, One of my pages always crashes php.exe on Windows XP. I can not find any logic error in my code. Does

  1   2   >