[PHP] Re: inserting preexisting image inside dynamic image

2002-11-25 Thread Erwin
Eric Pierce wrote: > Hi there... > > Just wondering... when creating a dynamic image, is > there a way/fuction to insert an existing image using > x,y coordiantes for precision? Yes, there is...use imagecopy (http://www.php.net/imagecopy) Grtz Erwin -- PHP General Mai

[PHP] Re: Dumb POST Array question

2002-11-25 Thread Erwin
ts'] contains an array, you can indeed use the above syntax. Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: can't pass complete URL (part of the query string) from one script to another --??

2002-11-26 Thread Erwin
s getting captured correctly -- also - I removed the > javascript and saw it get passet in the url as a 'get' correctly.) > > but in the email script I try to display 'ref' and what I get is: > > 'http://mydomain.com/shop.php?val1=1' -- everything p

[PHP] Re: using mbstring without having /configure'd it

2002-11-26 Thread Erwin
Oliver Spiesshofer wrote: > Hi, > > Is it possible to use mbstring after setting the necessary values in > ini_set() or htaccess without having it enabled during /configure? Nope...the functions of mb are unknown, because you didn't compile them. Grtz Erwin -- PHP General M

[PHP] Re: & in Query String

2002-11-26 Thread Erwin
o browser which turns & in & in URL's. That would be very, very bad indeed! > Actually, you should specify the URL with the & > yourself, like this: > > Of course not...this is a HREF tag, which can use & instead of &. & is for displaying purposes only

[PHP] Re: Starting an application on web server

2002-11-26 Thread Erwin
s requesting some more information? > I also don't get any visual output on the server of the wolfmp.exe > starting up the game console. Don't you get any visual output if you use passthru instead of exec??? Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: & in Query String

2002-11-26 Thread Erwin
> I'll let you know what turns up (of course, the problem will stop > occurring once I add this info :-). As it always does ;-)) Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: need help with a chat code problem

2002-08-30 Thread Erwin
ause the min-function is a so called "group" function. Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Mail problem

2002-08-30 Thread Erwin
would it have to be >> directly amended in the php.ini file? I don't think this would stop emails from being sent. There are two ways to change the From header: - Use the function ini_set("sendmail_from", "" ); - Use "From: " as the fourth argument to you

[PHP] Re: Reg exp help

2002-08-30 Thread Erwin
uantifier", which matched everything until the next statement (in this case the "\n"). You can also use "$" instead of "\n", only the newline will not be stripped. "$" means end of line, while "\n" means newline. HTH, Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Mail problem

2002-08-30 Thread Erwin
lib/sendmail, so you could check that. Try file_exists, or open a pipe with popen. Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: "autocomplete" list box

2002-08-30 Thread Erwin
with DHTML, but it will never come close to Microsofts implementation. Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: unexpected T_SL

2002-09-02 Thread Erwin
o be honest, there is nothing wrong. It works in version 4.2.2 (at least, here it does) ;-)) Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] using shell_exec

2002-09-02 Thread Erwin
&& tar cvf /place/for/backup.tar files"); Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: PHP checkbox/hidden field question

2002-09-02 Thread Erwin
n print the hidden input's to the page in a for loop, while looping trough $d_c_arr. HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: str_replace question

2002-09-02 Thread Erwin
pended and prepended with and b) Use the code from Olinux Option B sounds best to me ;-)) HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: getimagesize with image in database

2002-09-02 Thread Erwin
t;> >> but it returns nothing. If I use a local file, without http it >> works. But I have no clue what's the problem here. Are you sure the file exists? Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Q:Making an 'expired event' for sessions

2002-09-02 Thread Erwin
a cookie which says that there is a session. If the session is gone, you can check that by checking the cookie and checking for a session. If the cookie states that there is a session, but there is no session, you know that it's gone. HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: turn off a warning with $GET_['var'];

2002-09-02 Thread Erwin
$_GET['status']){ try array_key_exists instead of isset. Neither isset nor array_key_exists should give warning messages. Maybe you have a very high errorlevel? Isset doens't give warnings if E_NOTICE is set as errorlevel. Grtz Erwin -- PHP General Mailing List (http://w

[PHP] Re: posting form values doesn't work

2002-09-02 Thread Erwin
>&group='; [ CUT Javascript code ] At first I thought is was JavaScript/HTML code, but I can see a little bit PHP now ;-)) The reason that it doens't work is simple. The variables are only available AFTER posting the form. Not during validation! You should just use Javascript to f

[PHP] Re: How to escape " in hidden field?

2002-09-02 Thread Erwin
alchars() function, so that "Hello \"world\"" will be written in pure HTML: "Hello "world"" HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: PHP checkbox/hidden field question

2002-09-02 Thread Erwin
Marek Kilimajer wrote: > You are wrong, this is from HTML 4.01 specification: > You're right. Thanks for your reply! Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: how do I send information to a php page from a menu list

2002-09-02 Thread Erwin
the onChange event? if so how may this be done? try: Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Newbie "Parse" error

2002-09-02 Thread Erwin
> I am sure that someone here can see somehting that I am too stupid > to... Here is my error: > > Parse error: parse error, unexpected T_VARIABLE in > send_contact_form.php on line 13 > > $subject = "Message From MCV Contact Form" Forgot a ";"? H

[PHP] Re: html to php with echo <<

2002-09-03 Thread Erwin
ust rename the file from index.html to index.php. HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Session problem

2002-09-03 Thread Erwin
ou have to push the Refresh button. You won't get this behaviour if the form is submitted with the GET method, because the variables are then part of the URL (and thus automatically submitted if you push the back button) HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: posting form values doesn't work

2002-09-03 Thread Erwin
n Javascript can be done by the client, like you do in your validation function. Getting them in PHP can only be done by the server. You cannot use these variables in Javascript code as $some_var. HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: header()-question

2002-09-03 Thread Erwin
nction createlinks() function createlinks() { ... } The function createlinks() has been defined more then once. You should check your include files. HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] rand()

2002-09-03 Thread Erwin
commandline) trough 100.000 iterations, and not one value was the same! I need it's purpose because I need a random value which is not to long. Hope you guys can help me out here! Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: rand()

2002-09-03 Thread Erwin
By the way, rand() will only return 0 if I call it with it's arguments. Without arguments it will return a random value. Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Apache 2.0

2002-09-04 Thread Erwin
; AddType application/x-httpd-php .php > > to httpd.conf, but my browser still doesn't show a php test page, it > rather prompts for download. Add the following to the bottom of your httpd.conf SetOutputFilter PHP SetInputFilter PHP HTH Erwin -- PHP General Mailing Li

[PHP] Re: Closing Frames...

2002-09-04 Thread Erwin
ipt disabled on their browser)... Closing frames and windows is done client side, so PHP can't do that. Besides, closing these things is done with Javascript, so you can't around it if you want to add this functionality. HTH Erwin -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] check for a number

2002-09-04 Thread Erwin
Steve Bradwell wrote: > is_int($f) will return true if $f is an integer, false otherwise. is_int will return false in this case, because it's a string. You have to use is_numeric HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] ending a session

2002-09-05 Thread Erwin
t_sessions and accept the negative sides of that (if it has any). HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] ending a session

2002-09-05 Thread Erwin
ase you have another two usergroups which can be a pain-in-the-ass: a) users that don't have JavaScript activated b) users (like me) that have a Popup killer Maybe, with all these solutions together, we can create the perfect logout script ;-)) Grtz Erwin -- PHP General Mailing

[PHP] Re: Undefined index, Undefined variable, Undefined constant....

2002-09-06 Thread Erwin
Jens Winberg wrote: > I'm having trouble with the newest version of PHP (4.2.2). > For example in a page I'm using the following code: > if ($_GET['action'] == "logout") { >//do something > } > > But I'm getting an error message that says: > ...log_message reports: PHP Notice: Undefined index

[PHP] Re: HTTP_SERVER_VARS not working. Please help

2002-09-06 Thread Erwin
Cirstoiu Aurel Sorin wrote: > I tried to use $HTTP_SERVER_VARS['HTTP_HOST'] but the result is null. > Is there an option so I can turn it on? If PHP > 4.1.0: try $_SERVER['HTTP_HOST'] instead. You can also set register_globals = On in the php.ini file (not recomm

[PHP] Re: wrong timestamp?

2002-09-06 Thread Erwin
ause of this my querry is not working, How > come this timestamp is wrong? It's not wrong...read the manual ;-)) Y = Year, 4 digits m = month, 2 digits d = day, 2 digits G = 24 hour, from "0" to "23" H = 24 hour, 2 digits i = minutes, 2 digits s = seconds, 2 digits Yo

[PHP] Re: sending email with linefeeds

2002-09-06 Thread Erwin
paste a generated mail message (including header information), so we can have a look at it... Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: file upload > 2 MB

2002-09-09 Thread Erwin
> # special settings for webmailer > >php_flag upload_max_filesize = 50M > Remove the = and use php_value php_value upload_max_filesize 2M HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: date question

2002-09-09 Thread Erwin
a date For example HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Upload Progress

2002-09-09 Thread Erwin
On the other side, the ASP solution is kind of the same as Jed's, so you are right, it isn't an argument. Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: POST form variables not being sent to destination page

2002-09-09 Thread Erwin
therefore I'm > assuming it's a problem with my installation, which is; > The test PHP is; > > Form Page: > > > > Untitled Document > > > > > > > Try adding another . We've had a problem where we *always* lost the first POST varia

[PHP] Re: POST form variables not being sent to destination page

2002-09-09 Thread Erwin
This took ages to find and was only posted within that last few days > on the PHP bug board, hope it helps you with your elusive first POST > variable. Whow, thanks man. It works like a webserver should work. All my problems are gone, even the huge POST problem I've had (bug #1926

[PHP] Re: changing session name

2002-09-10 Thread Erwin
Mohd_q wrote: > I want to change the default session name 'PHPSESSID' to say ex. > 'seid'. > > How can I do this without editing to the php.ini since I'm having a > site on a virtual host. http://www.php.net/session_name HTH Erwin -- PHP Gener

[PHP] Re: Generating CSV files on the fly and getting the browser to download

2002-09-10 Thread Erwin
wser can ignore it. They think it's a normal .csv file, which should be opened with (for instance) Excel... HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: mysql_insert_id

2002-09-11 Thread Erwin
ill returns the value of the AutoIncrement column. HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: sessions nightmare

2002-09-11 Thread Erwin
= $retrieved_itemno; $_SESSION["SESSION"] = $SESSION; test2.php: $SESSION= $_SESSION["SESSION"]; echo "The retrieved value equals to " . $SESSION["item"]; HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: user and password for socket connection

2002-09-12 Thread Erwin
} else { > fputs ($fp, $loginmessage); > while (!feof($fp)) { > echo fgets ($fp,128); > } > fclose ($fp); > } You could try using $url = "https://$user:$[EMAIL PROTECTED]"; I haven't tried this yet ;-)) HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: what is wrong?

2002-09-12 Thread Erwin
;; And as final addition, you probably have to use $_POST["new_password1"] Besides that, I would use the form of Lallous: if ( empty( trim( $_POST[ "new_password1" ] ) echo "Empty!"; HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] A question about .php file extension

2002-09-12 Thread Erwin
Adam Williams wrote: > make a directory called phptest and put a file, index.php in > it...never > tried it tho. In that case you will have to call http://localhost/phptest/?id=22 Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://ww

[PHP] Re: Displaying PDF file

2002-09-12 Thread Erwin
including will be parsed by the parser. I have no idea why some document don't give errors. You will have to use readfile instead: readfile( "../pdfs/whatever.pdf"); HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Displaying PDF file

2002-09-12 Thread Erwin
Joseph Szobody wrote: > Thanks Erwin, that helps but I'm still not getting it to work. > Should I still use the > > Header("Content-type: application/pdf"); > > line? > > I tried using readfile() keeping the header. When I click the link to &

[PHP] Re: php nuke problem

2002-09-12 Thread Erwin
admin.php and when i fill > that form,it just displays the same form over and over again...the > super user/ admin user does not get created... Probably it requires register_globals to be turned On??? Did you checked that? HTH Erwin -- PHP General Mailing List (http://www.php.net/) To

[PHP] Re: error handling

2002-09-12 Thread Erwin
I have access to > .htacces and no access to php.ini. Take a look at http://www.php.net/set_error_handler That's the easiest way to create your own error_handler class! HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: COOKIE Question.

2002-09-16 Thread Erwin
ess"]; > print $_COOKIE["$Access"]; > and even > print "$Access"; What about $_COOKIE["Access"] ??? Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: How to choose a crypt-standard in crypt()?

2002-09-17 Thread Erwin
ENGTH which tells you whether a regular two character salt applies to your system or the longer twelve character salt is applicable." HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Auto-increment value

2002-09-18 Thread Erwin
Scott Houseman wrote: > Hi there. > > You can use the function mysql_insert_id( [link id] ). > >> I'm using postgresql. Not if you're using PostGreSQL Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: MySQL > Access

2002-09-20 Thread Erwin
e Mysql-ODBC driver, which can be downloaded from www.mysql.com, and then import the tables with access Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Sessions

2002-09-20 Thread Erwin
works OK - I've tried output_buffering (on and off) - I've tried registered_globals (on and off) - I've tried using "session_write_close()" before leaving the page - I've checked the "session_start()" statement (Yes, it's there :-) ) I hope someone c

Re: [PHP] Sessions

2002-09-20 Thread Erwin
John Holmes wrote: > You have session_start() on the second page, too, right?? > Yes...the session_start() statement is in a global include file, which is included in all files which require it Grtz Erwin >> -Original Message----- >> From: Erwin [mailto:[EMAIL PROTECTED

[PHP] Re: why manual says 'don't use session_register'?

2002-09-24 Thread Erwin
ad of session_unregister('key'), the value will be removed from the $_SESSION array AND from the session file. I recommend following the manual and don't use the session_unregister, session_is_registered and session_register functions anymore. HTH Erwin -- PHP General Maili

[PHP] Re: PHP Installation under WinXP Apache 2.0.39

2002-09-24 Thread Erwin
ure could not be found. I think this problem is related with the interface change of Apache2. Since version 2.0.39 (?) the interface changed a bit, so some functions don't work. You'll have to compile the php4apache2.dll from PHP 4.3.x and use that with your Apache2. I'll se

[PHP] Re: problems with opendir()

2002-09-24 Thread Erwin
tual value. Use $_SERVER['DOCUMENT_ROOT'] . '/files/dir'OR "$_SERVER['DOCUMENT_ROOT']/files/dir" instead HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: looping through array with list()/each()

2002-09-25 Thread Erwin
gt; > reset($ser); > while ( list($key, $val) = each($ser) ); > { > echo "\$key = $key, \$val = $val"; > } Small typo: while ( list($key, $val) = each($ser) ); change into: while ( list($key, $val) = each($ser) ) Remove the ";" HTH Erwin P.S.: Take a break ;-)) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: shouldn't $_SERVER['PHP_SELF'] include the get info?

2002-09-26 Thread Erwin
lude all get data in the url? It is supposed to be like that...the PHP_SELF points to this file, and the filename has no arguments, thus the PHP_SELF variable don't have them either. You will have to use the $_GET array for the "aid=12" part. Grtz Erwin -- PHP General Maili

[PHP] Re: Including variables

2002-09-26 Thread Erwin
lose it, include it and delete it (with unlink, http://www.php.net/unlink). HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Tar Files and send back to browser

2002-09-26 Thread Erwin
n I search for the tar on the webserver I can't find it > anywhere. You have to send the appropriate headers to the browser, or PHP will send the default (text/plain) header. For a tar file the correct header is application/x-tar, send it with Header( 'Content-Type: application/x

[PHP] Re: shouldn't $_SERVER['PHP_SELF'] include the get info?

2002-09-26 Thread Erwin
Noodle Snacks wrote: > "Erwin" <[EMAIL PROTECTED]> wrote in message > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... >> Noodle Snacks wrote: > > [snipped] > >> >> It is supposed to be like that...the PHP_SELF points to this file, >>

Re: [PHP] Re: Tar Files and send back to browser

2002-09-26 Thread Erwin
says: Unexpected end of archive. > > Have you got a sollution on that? Yes...my mistake, use passthru( $command ) instead of system( $command ) Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Finding out when a Web page has changed

2002-09-26 Thread Erwin
Marek Kilimajer wrote: > Hope the sites have no banners :), they change all the time But the URL to the banners will be the same, so that's no change in the HTML code ;-)) > [SNIP] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Tar Files and send back to browser

2002-09-26 Thread Erwin
small footprint (about 1k-2k with one file), so the tar file should ALWAYS be bigger than the source file(s)... H...thinking about this...I'm sure you would like compression instead of archiving. Use gzip only instead of tar: - Set the header back to application/x-gzip - Change the command

Re: [PHP] Re: Tar Files and send back to browser

2002-09-26 Thread Erwin
downloads then (use Winzip ;-) ) Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Tar Files and send back to browser

2002-09-26 Thread Erwin
Sascha Braun wrote: > Do you know how to exclude the path informations in the tar archive? Yes, first chdir to the ../images directory http://www.php.net/getcwd http://www.php.net/chdir Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.

[PHP] Re: 4.0.2 => 4.2.3, form vars are empty?

2002-09-27 Thread Erwin
are fine, but GET/POST vars are continually > empty. I mean a form submission from .html to .php (about the > simplest thing possible) the variables are not getting populated with > their form values. Turn register_globals = On in the php.ini file... HTH Erwin -- PHP General Mailing List (ht

[PHP] Re: PHP Include Help

2002-09-30 Thread Erwin
es? Use nl2br: http://www.php.net/nl2br This function replaces all "\n" (newlines) with "\n" (HTML break with newline) HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Apache 1.3.26 + PHP 4.2.3

2002-10-01 Thread Erwin
n and has worked > for many versions. Its just with PHP 4.2.3 that it stops working. Is "apachectl graceful" an option? apachectl resided in the apache installation dir. Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Undefined index:

2002-10-02 Thread Erwin
if ( isset( $_POST['categorie'] ) && $_POST['categorie'] == 'New' ) } // Your code here } HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: quotes in text strings

2002-10-02 Thread Erwin
ENT_QUOTES); > and > htmlentities($string, ENT_QUOTES); > > but these don't seem to work (maybe its me). Probably you have magic_quotes_gpc set to On in php.ini...you can change this to Off, or you can use stripslashes() on the $string variable... HTH Erwin -- PHP General Mai

[PHP] Re: Thumbnail with GD

2002-10-04 Thread Erwin
e. You're resize script will have to look like this: resize.php You can invoke this with http:///resize.php?filename=img.jpg. You can create a nice directory listing this way, just call the resize.php script for every image on the page. Create the directory listing with the opendir function

[PHP] Re: help me please.

2002-10-04 Thread Erwin
')"); This query is wrong. An insert query can't have a WHERE clause...check the MySQL documentation about that. > > $upfile = "$UploadURL".$userfile_name; Change to: $upfile = $UploadUrl . $_FILES['userfile']['name'] > if ( !copy($user

Re: [PHP] Unix passwd file

2002-10-04 Thread Erwin
substr( 'phprocks', 0, 2 ) ) ) { // Validation succeeded } else { // Invalid password } Crypt can not be unencrypted, but you can of course compare the crypted passwords... HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Stuck at PHP4 installation( with Apache2 )

2002-10-03 Thread Erwin
y, because it's not required, but copy php4ts.dll to the system32 directory instead. If you're using any extensions that require external libraries (take a look in your php installation directory, subdirectory dlls), then they should be copied to. HTH Erwin -- PHP General Mailing Li

Re: [PHP] join() , can do that fast?

2002-10-07 Thread Erwin
Lallous wrote: > John, what you said would simply produce: >var x = ['str1,str2,str3'] > and not as I want: > var x = ['str1','str2','str3'] Elias, did you actually tried that? Because it does produce what you want... produces: x=

[PHP] Re: =Next to last record in a file=

2002-10-08 Thread Erwin
do this, store the element you will gain (pop will return the element it popped). There you have it... In code: http://waterdata.usgs.gov/ny/nwis/uv?format=rdb&period=1&site_no=01420500' ); array_pop( $content ); $current = array_pop( $content ); ?> HTH Erwin -- PHP Gene

[PHP] Re: Seek for a value in a html file ...

2002-10-09 Thread Erwin
is an array, where the elements are all the matching lines from the $content array, which is your inputfile. You can then filter out the value you want using strpos, strrpos and substr. HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: String manipulation

2002-10-24 Thread Erwin
preg_match( '/.*@test\.com$/', $_POST['email'] ) ) echo 'Valid'; else echo 'Not valid'; $_POST['email'] contains the email address, submitted by the form. HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Ereg help

2002-10-25 Thread Erwin
bet there is a much nicer (and maybe faster way), but this is by far the easiest (it doesn't cost one night) ;-)) One hundred thousand of these iterations took about 2 seconds... Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: exploding values into new variables

2002-10-28 Thread Erwin
es[0]; > > or > $first_piece = $pieces[0]; > echo $first_piece; > > Right? Right! Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: preg_replace and eval

2002-10-28 Thread Erwin
pattern. It seems the string is parsed backwards. To avoid this problem, be more specific in your regexp. Don't use (.*), but ([^{]*) instead. The regexp which works in your example is the following: /([^{]*){parent.([^{]*)}([^{]*)/e HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Making string upper/lowercase with regex?

2002-10-29 Thread Erwin
strtoupper() instead? >> >> Leif K-Brooks wrote: >>> I don't want the entire string upercase, just part of it as defined >>> by a regex. Then use preg_replace. The PHP website has an example to uppercase a part of a string using preg_replace(http://www.php.net/p

[PHP] Re: Another question

2002-10-29 Thread Erwin
an use JavaScript, something like top.document.title = 'Title' or document.title = 'Title' I'm not exactly sure which one (if any) of these works, but it's something like this... Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: How do you select?

2002-10-31 Thread Erwin
Steve Jackson wrote: > I want to the select the very last record from my MySQL DB. How do I > do it? If the table has an id, use select * from order by id desc limit 0,1 Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: why does eregi match for whitespace when there is none?

2002-11-01 Thread Erwin
above return true? There is no whitespace in the string. > What am I missing? Try using [[:space:]] when using eregi. See also http://www.developers-resources.com/stories.php?story=01/10/25/0549771 Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Session cookies

2002-11-03 Thread Erwin
The session id changes when you close the browser , as the default is > 0. Not because default is 0, but because there isn't any session yet. HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: fgets()

2002-11-03 Thread Erwin
ntents=""; > while (!feof($file)) > { > $filecontents.=fgets($file); > } > > this one worked well with PHP4.2.3 but with versions under PHP 4.2.0 > it didn't work > > So what else can i try to just get the whole contents of the file > into a string?

[PHP] Re: Address array?

2002-11-04 Thread Erwin
ip_name = $row["ship_name"]; $ship_address = $row["ship_address"]; $ship_city = $row["ship_city"]; $ship_zip = $row["ship_zip"]; $ship_country = $row["ship_country"]; // Do something... } } HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Battling with highlighting search criteria

2002-11-04 Thread Erwin
uot;This is a test, isn't it?"; $search = "is"; $replacement = '' . $search . ''; $result = str_replace( $search, $replacement, $result ); HTH Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Battling with highlighting search criteria

2002-11-04 Thread Erwin
the following one: $result = "This is a test, isn't it?"; $search = "is"; $result = preg_replace( '/(' . $search . ')/i', "\$1", $result ); Grtz Erwin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Battling with highlighting search criteria

2002-11-04 Thread Erwin
>> Try the following one: >> >> $result = "This is a test, isn't it?"; >> $search = "is"; >> >> $result = preg_replace( '/(' . $search . ')/i', "> class=\"highlight\">\$1", $result ); >

  1   2   >