Re: [PHP] register globals :|

2003-03-26 Thread Leif K-Brooks
e the script resides). cheers, - Sebastian - Original Message - From: "Leif K-Brooks" <[EMAIL PROTECTED]> | http://www.php.net/manual/en/function.import-request-variables.php at | the top of the script, or use .htaccess to change RG to on. | | Sebastian wrote: | | >Is there

Re: [PHP] html_quickform - array question

2003-03-26 Thread Leif K-Brooks
Are you trying to print/echo it? That converts it to a string first. Either print_r it, var_dump it, or do something else with it. Charles Kline wrote: hi all, using html_quickform (pear) and it has a date type that passes the date info like this: array(24) { ["lr_pub_date"]=> array(3) {

Re: [PHP] html_quickform - array question

2003-03-26 Thread Leif K-Brooks
ething like this: $thedate = $lr_form->getSubmitValue('lr_pub_date'); echo "The month: $thedate['m']"; Is that what you meant? - Charles On Wednesday, March 26, 2003, at 09:31 PM, Leif K-Brooks wrote: Are you trying to print/echo it? That converts it to a string first.

Re: [PHP] Retrieving newly created ID from MySQL?

2003-03-26 Thread Leif K-Brooks
The manual is your friend! :) Have a look at http://www.php.net/manual/en/function.mysql-insert-id.php. Ben Cheng wrote: If I have a MySQL table with an auto-incrementing ID field, is there an easy way to retrieve the new ID after I insert a new row into the table? For example, if I insert a

Re: [PHP] Send Output to Printer?

2003-03-26 Thread Leif K-Brooks
PHP is server-side; it can't do anything to the client. You'll need to use javascript, or some other client-side technology. Nicole wrote: anyone know of a good tutorial for using PHP to send output to a printer? have a report that returns paged display (e.g., 20 rows max per page) ... too man

Re: [PHP] Internet Explorer toolbar

2003-03-27 Thread Leif K-Brooks
PHP is server-side. It runs on the server, NOT the client. It has no way to do anything to the client. Try javascript. Manuel Ochoa wrote: Is there any way of using php to launch a new browser without the IE toolbars? -- The above message is encrypted with double rot13 encoding. Any unaut

Re: [PHP] Why this script doesn't work?

2003-03-27 Thread Leif K-Brooks
http://www.php.net/manual/en/security.registerglobals.php J. P. wrote: I'm using Apache 2.0.44 with Win XP and PHP version 4.3.1! -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law. -- PHP G

Re: [PHP] last questions

2003-03-27 Thread Jason k Larson
Search the list archives, this question gets asked (and answered) a lot. http://marc.theaimsgroup.com/?l=php-general HTH, Jason k Larson Haseeb Iqbal wrote: thanx to all those who replied to my previous question. 1 more question.i need help with reqular expressions.i want to check valid (email

Re: [PHP] Re: Internet Explorer toolbar

2003-03-27 Thread Leif K-Brooks
Correct, but he asked about doing it with PHP. Peter Houchin wrote: yes there is java script Dan wrote: On Thu, 27 Mar 2003 12:32:06 -0800 (PST), [EMAIL PROTECTED] (Manuel Ochoa) wrote: Is there any way of using php to launch a new browser without the IE toolbars? No. PHP is server side, no

Re: [PHP] Re: Internet Explorer toolbar

2003-03-27 Thread Leif K-Brooks
d. = Original Message From Leif K-Brooks <[EMAIL PROTECTED]> = Correct, but he asked about doing it with PHP. Peter Houchin wrote: yes there is java script Dan wrote: On Thu, 27 Mar 2003 12:32:06 -0800 (PST), [EMAIL PROTECTED] (Manuel Ochoa) wrote: Is there any way of

Re: [PHP] Re: Internet Explorer toolbar

2003-03-27 Thread Leif K-Brooks
Correct, but he asked for a PHP solution. HE DID NOT ASK FOR A JAVASCRIPT SOLUTION, AND YOU SHOULD NOT DISCUSS CLIENT-SIDE MATTERS ON THE PHP LIST! Dan Rossi wrote: ??? who cares i gave a solution, there is no other #**#% way -Original Message- From: Leif K-Brooks [mailto:[EMAIL

Re: [PHP] Re: Internet Explorer toolbar

2003-03-28 Thread Leif K-Brooks
echoing javascript ? -Original Message- From: Philip J. Newman [mailto:[EMAIL PROTECTED] Sent: Friday, March 28, 2003 6:49 PM To: Dan Rossi; Leif K-Brooks Cc: Peter Houchin; Dan; php-general Subject: Re: [PHP] Re: Internet Explorer toolbar Now Now children. - Original Message - From

Re: [PHP] Problem with "=& new" and locally created instances

2003-03-28 Thread Jason k Larson
Maybe I'm missing something here ... but what is the point of trying to create a reference to a new object ... it hasn't been ceated prior to make reference to. Can't you simply create the new object and then make whatever (if needed) references? -- Jason k Larson Jens von Pi

Re: [PHP] dynamic/multidimensional arrays in classes

2003-03-28 Thread Jason k Larson
PHP3 it is in all versions of PHP4. If you can't use foreach, writing the while loop differently (not using each()) should work better. HTH, Jason k Larson Patrick Teague wrote: I'm currently having a problem with another array in a class & I can't figure it out - class myClas

Re: [PHP] Problem with "=& new" and locally created instances

2003-03-28 Thread Jason k Larson
s my values prior were magically recreated after the object was instanciated. Rasmus, any ideas here? I'm thinking this is a bug. -- Jason k Larson Jens von Pilgrim wrote: Hello, Jason wrote: JL> Maybe I'm missing something here ... but what is the point of trying JL> to create

Re: [PHP] Re: Internet Explorer toolbar

2003-03-28 Thread Leif K-Brooks
Agreed, but it should be discussed off-list. The PHP list is a place to discuss PHP. Ashley M. Kirchner wrote: Leif K-Brooks wrote: I never said there was one, I simply said that a PHP solution was requested and you gave a javascript solution. That has nothing to do with the PHP (!) list

Re: [PHP] Redirec.t

2003-03-28 Thread Leif K-Brooks
header("Location: http://php.net/header";); Johnny Martinez wrote: Hi all, Can someone tell me the function to redirect a browser to a specific page? Johnny For example: code... code... code finished. redirect("http://www.domain.com/admin.php";); ?> -- The above message is encrypted with d

Re: [PHP] Redirec.t

2003-03-28 Thread Leif K-Brooks
Try putting: ob_start(); at the top of your file (before ANY output is done). Johnny Martinez wrote: Forgive me. I'm new to php. I put the function in my function.php include file which is loaded before I display anything. I want to redirect the browser to a new url once the php script is finishe

Re: [PHP] Redirec.t

2003-03-28 Thread Leif K-Brooks
mes... PHP Architect - A monthly magazine for PHP Professionals. Get your copy today. http://www.phparch.com/ -Original Message- From: Johnny Martinez [mailto:[EMAIL PROTECTED] Sent: Friday, March 28, 2003 8:37 PM To: 'Leif K-Brooks'; Johnny Martinez Cc: '[EMAIL PROTECTED]&#x

Re: [PHP] Is there a PHP for Dummies?

2003-03-28 Thread Leif K-Brooks
After a quick search of the php manual, I came upon http://www.php.net/manual/en/ref.info.php#ini.magic-quotes-gpc, which says: Sets the magic_quotes state for GPC (Get/Post/Cookie) operations. When magic_quotes are on, all ' (single-quote), " (double quote), \ (backslash) and NUL's are escaped

Re: [PHP] Is there a PHP for Dummies?

2003-03-28 Thread Leif K-Brooks
t find the PHP manual very helpful - I tend to get more out of the users comments than the actual manual.. - Original Message - From: "Leif K-Brooks" <[EMAIL PROTECTED]> To: "Beauford.2002" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Friday, Marc

Re: [PHP] re: jason wong (was: locate)

2003-03-29 Thread Leif K-Brooks
I have to agree with Jason Wong, this list if for PHP and PHP only. If you want to discuss something else, do it somewhere else. The volume of the list is high enough with legitimate questions... Joseph Bannon wrote: You really are taking advantage of people's generosity in answering your OT

Re: [PHP] Is there a PHP for Dummies?

2003-03-29 Thread Leif K-Brooks
y understand it is to look at other peoples code and write your own. B. - Original Message - From: Leif K-Brooks <mailto:[EMAIL PROTECTED]> To: Beauford.2002 <mailto:[EMAIL PROTECTED]> Sent: Saturday, March 29, 2003 9:03 AM Subject: Re: [PHP] Is there a P

Re: [PHP] accessing result-set with associative array

2003-03-30 Thread Leif K-Brooks
It doesn't include the table name. Use name, albumid, etc. anders thoresson wrote: Hi, I've the query "SELECT albums.name, albums.albumid, accessrights.albumid, accessrights.userid FROM albums, accessrights WHERE accessrights.userid = '$id' AND albums.albumid = accessrights.albumid". It wor

Re: [PHP] Parsing CSS files

2003-03-31 Thread Leif K-Brooks
Why do you need to do this in the first place? If you're trying to create dynamic CSS, the .php extension will be fine as long as you send the proper content-type header. Liam Gibbs wrote: Is there any way of making PHP parse files with a CSS extension? -- The above message is encrypted wi

Re: [PHP] if statment

2003-03-31 Thread Leif K-Brooks
You should be using if(!isset($HTTP_GET_VARS['id'])){ Otherwise, it generates an eror when it simply doesn't exist. "" and nothing (an unset variable) are NOT the same. Tim Haskins wrote: below is what I have currently its empty Now when I change the == to <> I receive the following error:

Re: [PHP] Question on response time, SQL vs. PHP

2003-03-31 Thread Leif K-Brooks
It's faster to use count(*), because it just has to fetch a count of the rows (but not the rows themselves). If you're retrieving the rows anyway, you should use mysql_num_rows, Liam Gibbs wrote: I'm trying to do a count(*) in SQL. Would it be faster to do a or b below? a: just do a simple qu

Re: [PHP] whats this!!!!

2003-04-01 Thread Jason k Larson
It's an April Fools joke ... nicely done too. Chris Edwards wrote: read: http://php.weblogs.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Stylesheets, are they run?

2003-04-01 Thread Leif K-Brooks
Most likely not, but this has to do with the browser and not PHP. Liam Gibbs wrote: Here I go again with the stylesheets. ;) Anyway, if a user has stylesheets turned off, is a stylesheet file even run? Like, if I have them turned off and I have a stylesheet, say, SS.php. Will SS.php run or will i

Re: [PHP] Stylesheets, are they run?

2003-04-01 Thread Leif K-Brooks
Not true, any decently-optimized browser won't fetch a style sheet it doesn't plan to use. Clint Tredway wrote: Your ss.php will still run, but the browser will not render the styles in the page. Clint -Original Message- From: Leif K-Brooks [mailto:[EMAIL PROTECTED] Sen

Re: [PHP] Command line php

2003-04-01 Thread Leif K-Brooks
STDIN is a file reference. Use the standard file functions (fread, for example) on it. John Nichel wrote: How do I capture standard input? $name = STDIN; echo ( "Hello " . STDIN . "\n" ); ?> -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to d

Re: [PHP] Wierd PHP Image

2003-04-01 Thread Leif K-Brooks
Removing it will anger Thies. I suggest you bow to Thies, perhaps he will be satisfied. Sebastian wrote: sorry what is Thies?, I have this too in my phpinfo... do i need it? Should i get rid of it? It started to appear when I complied GD Library with mcrypt support. cheers, - Sebastian - O

Re: [PHP] $_SERVER[REMOTE_ADDR]

2003-04-01 Thread Leif K-Brooks
First of all, you should be using quotes around string array keys. $_SERVER['REMOTE_ADDR'] is more correct. Anyway, my guess is there's a proxy here somewhere. John wrote: Makes me think.. what exactly the $_SERVER[REMOTE_ADDR] is doing Cause it does not really show the actual IP

Re: [PHP] Wierd PHP Image

2003-04-01 Thread Jason k Larson
I hope you all can take a joke, cause this is just a result of April Fools day. Try looking at your phpinfo script again tomorrow. And ignore Don Read ... his suggestion is just plain evil. -- Jason k Larson Sebastian wrote: sorry what is Thies?, I have this too in my phpinfo... do i need it

Re: [PHP] How to disable cache, image headers?

2003-04-01 Thread Leif K-Brooks
What's wrong with using a "trick" like that in a professioanl application? It doesn't hurt anything, and more importantly, IT WORKS! If your client(s) only care about it not using "tricks", I wouldn't reccomend doing work for them. Arnaud De Bruyn wrote: I don't want to use a trick like addin

Re: [PHP] Php.ini doesn't exit

2003-04-02 Thread Leif K-Brooks
If it doesn't exist, it will use default settings. To see where it's looking for php.ini, use phpinfo(). Javier Carreras wrote: Hi all, Where does PHP get its settings if php.ini file doesn't exist? BTW- I want to enable sockets that are not enabled. Could I do that without creating a php.ini

Re: [PHP] chill out

2003-04-02 Thread Leif K-Brooks
It's not people who don't know everything I have a problem. It's people who ask questions when the answer is right in front of their nose. [EMAIL PROTECTED] wrote: We subscribe to a few email lists on various languages. This list would have to be the worst for anyone learning - the amount of

Re: [PHP] php.ini not being used?

2003-04-02 Thread Leif K-Brooks
It's using default settings. You'll have to recompile PHP to change where it looks for php.ini, or you can move your php.ini file into that location. Justin French wrote: Hi, I can't believe I've never bothered to learn this stuff, so I apologise for being totally dumb in advance :P phpinfo()

Re: [PHP] Deleting Objects

2003-04-02 Thread Leif K-Brooks
That will work perfectly. [EMAIL PROTECTED] wrote: How does one delete an object? For example: $object = new Class(...); . $object = new Class(...); I want to throw away the old object and create a new, freshly initialized one using the same variable. Is the above

Re: [PHP] Deleting Objects

2003-04-02 Thread Leif K-Brooks
Not exactly true. unset() destroys the reference to the value, not the value itself. For instance, error_reporting(E_ALL); $var1 = "foo"; $var2 = &$var1; print "$var1\n$var2\n\n"; unset($var1); print "$var1\n$var2"; will output: foo foo Notice: Undefined variable: var1 in PHPDocument1 on li

Re: [PHP] QUESTION - user management

2003-04-02 Thread Leif K-Brooks
Keeping track of the last time each username / IP address has viewed a page, and assuming that any user who was seen less than 5 minutes (or so) ago is online. [EMAIL PROTECTED] wrote: How do applications know how many users are logged into the system? For example postnuke will tell you '3 user

Re: [PHP] magic quotes

2003-04-03 Thread Leif K-Brooks
That's exactly what magic_quotes_runtime does. It adds slashes to data at runtime - including data returned from functions such as mysql_fetch_(assoc/row/array/object). Justin French wrote: Hi all, Can I just have a quick head check on magic quotes runtime (&gpc)? I have them both set to O

Re: [PHP] space

2003-04-03 Thread Leif K-Brooks
The manual is your friend! :) www.php.net/nl2br Diksha Neel wrote: hi all! in an html file thru a php script, i have to put in some data. i am using variable $string to write the data as under. what i want to know is how can i ensure that the value of $badd1 and $area get written on different lin

[PHP] Memory problem...

2003-04-03 Thread Leif K-Brooks
I've posted this before, but still haven't been able to solve it. Often, users will get "Fatal error: Allowed memory size of 15728640 bytes exhausted (tried to allocate 86460 bytes) in Unknown on line 0". I'm not doing anything very memory-intensive, and this sometimes does mention a specific l

Re: [PHP] REPLY NEEDED

2003-04-03 Thread Leif K-Brooks
Based on the information gathered about thousands of people, you believe they would all be in a position to help you? :) PATRICK KOFI wrote: BASED ON INFORMATION GATHERED ABOUT YOU, WE BELIEVE YOU WOULD BE IN A POSITION TO HELP US IN TRANSFERING THIS FUND (US$31.5M) INTO A SAFE ACCOUNT. IT HAS B

Re: [PHP] generate all permutations possible? (twist)

2003-04-03 Thread Leif K-Brooks
Try this (minimal testing, un-optimized): function permutations($letters,$num){ $last = str_repeat($letters{0},$num); $result = array(); while($last != str_repeat(lastchar($letters),$num)){ $result[] = $last; $last = char_add($letters,$last,$num-1); } $result[] = $last;

Re: [PHP] command line

2003-04-03 Thread Leif K-Brooks
http://www.php.net/manual/en/ref.exec.php Randy Johnson wrote: What would be the syntax for executing a command line php script from the web. and is there way to check the staus of the script via the web ie is it stil running or not? Randy -- The above message is encrypted with double rot

Re: [PHP] dynamic IF statement

2003-04-04 Thread Leif K-Brooks
If I understand you right, you want: if (HTTP_GET_VARS["id"] == $row_rsProducts['prID']){ ...do stuff... } Tim Haskins wrote: How does one create a statement that basically says: " ) { ?> Basically, I want to say, "show if url value is equal to this database record's ID value - The last part is

Re: [PHP] Session Variables and Posting

2003-04-04 Thread Leif K-Brooks
http://www.php.net/manual/en/security.registerglobals.php Van Andel, Robbert wrote: Is there a way that I can prevent session variables getting values from query strings. I want them to receive values only from posted forms. Robbert van Andel -- The above message is encrypted with double ro

Re: [PHP] Found a bug in 4.2.3 re: and echo vs.

2003-04-04 Thread Leif K-Brooks
Works fine for me, php 4.2.1. Daevid Vincent wrote: Here, try this bullshit... I can't upgrade to a more recent version as I'm not in control of the server, but I've tried it with both 4.1.2 and 4.2.3 on linux with a RH install. Can anyone confirm or dispute this bug exists in later versions? Ho

Re: [PHP] how do I strip out data from a url?

2003-04-04 Thread Leif K-Brooks
//Beware, untested! preg_match('|.*([0-9]{10}).*|',$_SERVER['HTTP_REFERER'],$matches); $number = $matches[1]; Damon wrote: Hi, I have a realatively easy problem that I need help on. I want to take a 10-digit number out of a referring url and put it in a variable. Eg. www.jimmy.com/mypage/xy

Re: [PHP] Re: Found a bug in 4.2.3 re: and echo vs.

2003-04-04 Thread Leif K-Brooks
Neither works. You're doing something like this in your other code: function foo(){ echo "foo"; } echo foo(); The foo() doesn't return the (non-existant) value from echo, it simply echo()s and returns nothing, and there's nothing wrong with echo()ing nothing. It would fail if you were using

Re: [PHP] Found a bug in 4.2.3 re: and echo vs.

2003-04-04 Thread Leif K-Brooks
Of course you can concatenate a string with a function! It works perfectly for me. Pablo wrote: On 04/04/2003 7:06 PM, Daevid Vincent ([EMAIL PROTECTED]) wrote: Here, try this bullshit... Try this. Change this line: echo "".alarmLightMySQL().""; to this, and you will get the expected

Re: [PHP] Right Click

2003-04-05 Thread Leif K-Brooks
There NEEDS to be a manual page for this! PHP is SERVER-SIDE! That means that once the page loads (actually, a little before that), PHP is done. IT DOES NOT KEEP RUNNING! IT RUNS ON THE SERVER'S MACHINE, NOT THE CLIENT! RTFA! Shantenese Williams wrote: Does anyone know if there is a funct

Re: [PHP] Right Click

2003-04-05 Thread Leif K-Brooks
nk jscript even html is OT ! = Original Message From Leif K-Brooks <[EMAIL PROTECTED]> = There NEEDS to be a manual page for this! PHP is SERVER-SIDE! That means that once the page loads (actually, a little before that), PHP is done. IT DOES NOT KEEP RUNNING! IT RUNS ON THE SERV

Re: [PHP] alignment

2003-04-06 Thread Leif K-Brooks
This has asbolutley nothing to do with PHP! Ask it on an HTML list. Diksha Neel wrote: dear all, hi! an html file is being created by my php script. i have used tables for the alignment of html file's text and images. i have an image and the value of variable $cname to be displayed in a cell. i

Re: [PHP] Allowing punctuation marks in regular expressions

2003-06-06 Thread Leif K-Brooks
It's using the case-insensitive switch. Dan Joseph wrote: Also, if you want upper case letters, make sure you add A-Z: -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law. -- PHP General Mailin

Re: [PHP] Gracefully dealing with Cookies OFF

2003-06-06 Thread Leif K-Brooks
I don't have a study in front of me, but I'm fairly sure that cookies are much more likely to be enabled than javascript. I reccomend opening a normal popup using a link with a target, and opening a sized popup and returning false with javascript in an onclick property. Something like: Open po

Re: [PHP] Do not display page errors...

2003-06-06 Thread Leif K-Brooks
You need to set it from a .htaccess file or php.ini to hide parse errors. John W. Holmes wrote: error_reporting(0); -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law. -- PHP General Mailing Li

Re: [PHP] Php handling apache's error directive?

2003-06-06 Thread Leif K-Brooks
$_SERVER['REQUEST_URI'] Miranda, Joel Louie M wrote: Can I use php to be apache's error directive? I mean, im trying to change apache's error directive But at the same time I can only change the page and couldn't see what error it was, I can send it only to a page with an error saying 404, etc bu

Re: [PHP] Web Server Firewall Suggested

2003-06-07 Thread Jason k Larson
e excess that I use, or prerouting tables, for that matter. -- Jason k Larson Luis Lebron wrote: I know there is a lot of expertise on running web servers in this group. So, I'm going to ask a couple of questions. I am currently a public web server with an iptables firewall. A securit

Re: [PHP] Capturing HTTP Response

2003-06-07 Thread Jason k Larson
This is all dependent on how you are performing the transaction. Are you using raw sockets to connect or perhaps cURL? The answer lies in that when whatever is making the connection and reading the data returned, the headers will be sent there. -- Jason k Larson Ralph wrote: Hi, I&#

Re: [PHP] How to determine if output buffering is on?

2003-06-07 Thread Leif K-Brooks
Yay, a hack! The correct answer is ob_get_level(). Jim Lucas wrote: output some html and then try and do an header() redirect. if it works, then some sort of buffering is turned on. if it fails and tells you that output has already been sent to the browser, then it isn't turned on. Jim Lucas -

Re: [PHP] About Guest Book\'s messages....

2003-05-28 Thread Jason k Larson
g. note that this is completely untested, I just wrote it here in email. Hope that helps. -- Jason k Larson fongming wrote: Hi, Sir: There

Re: [PHP] id & name when identifying html elements

2003-05-28 Thread Jason k Larson
an identical 'name' attribute could be used several times without conflict. For PHP use, you have to use the 'name' attribute, but you've already figured that out. -- Jason k Larson -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] flawless script

2003-05-28 Thread Jason k Larson
est. Hope that helps. -- Jason k Larson -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Variables don't pass... *sniff*

2003-05-28 Thread Leif K-Brooks
To maintain absolute compatibility, just use $HTTP_GET_VARS. It's availalable in all PHP versions, just deprectaed in versions here $_GET is available. [EMAIL PROTECTED] wrote: Thank you! =) Okay, okay... Sorry to keep rambling on like this, but I just need to get this 100% straight: I read

[PHP] Re: secure code

2003-05-28 Thread Anil Kumar K.
Here is exactly what you are looking for: "The Open Web Application Security Project" http://www.owasp.org/ best. Anil On Wed, 28 May 2003, Tim Burgan wrote: > Hello, > > I'm wondering if you can recommend any resources that discuss writing secure > code and how to put the best methods in

Re: [PHP] PHP redirect

2003-05-29 Thread Leif K-Brooks
Actually, the standards require an absolute URL, e.g. header("Location: http://foo.com/bar/baz/something.php";); David Grant wrote: It might also be an idea to give the filename as a path relative to the root directory, e.g. header("Location: /foo/bar/index.php"); -- The above message is enc

Re: [PHP] generate random

2003-05-30 Thread Leif K-Brooks
I reccomend you RTFM! www.php.net/rand www.php.net/mt_rand Marius wrote: how to generate random number ? -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law. -- PHP General Mailing List (http

Re: [PHP] PHP- Converting to and from TIMESTAMPS

2003-05-30 Thread Leif K-Brooks
If you'd bothered to RTFM, you'd know both answers already. strtotime() for number one, and date() accepts an optional second argument (the timestamp). Ian Gray wrote: I am wanting one field on a table in one of my MYSQL databases to contain different dates and times as a epoch timestamps. Fi

Re: [PHP] problem with pop3 check

2003-06-01 Thread Jason k Larson
Shouldn't the correct suntax for pop3 be: $mbox = imap_open ("{mail.hot.ee:110/pop3}", "pop3testing", "testing"); http://us2.php.net/imap_open -- Jason k Larson -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] problem with pop3 check

2003-06-01 Thread Jason k Larson
("{mail.hot.ee:110/pop3/notls}INBOX", "pop3testing", "testing"); Hope that helps. -- Jason k Larson -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Installation problem

2003-06-01 Thread Jason k Larson
Call it a hunch ... ./configure --with-apxs2=/usr/local/apache2/bin/apxs \ --with-mysql=/usr/local/mysql -- Jason k Larson Ron Dyck wrote: I'm currently attempting to upgrade to the latest version of php. When I run: ./configure --with-apxs2=/usr/local/apache2/bin/apxs \ --with-mysql

Re: [PHP] Sending a http body

2003-06-02 Thread Leif K-Brooks
www.php.net/flush Roland Welker wrote: Hi, I am a bit of a newby in php, so I hope the group my forgive me, if I ask a question answered before. The presumtion: php is first evaluating the complete script, before sending anything back to the browser. The situation: I have got a script, which ret

Re: [PHP] Use of undefined constant PHP_SELF - assumed 'PHP_SELF'

2003-06-03 Thread Leif K-Brooks
http://us3.php.net/types.array#language.types.array.foo-bar Øystein Håland wrote: What's the difference (and what's correct)? With the use of error_reporting = E_ALL in php.ini I get an error as mentioned above. In the code I use $_SERVER[PHP_SELF]. Changing this to $_SERVER['PHP_SELF'] report

Re: [PHP] how to get rid off this auto repsonse from TechSupport@bonzi.com?

2003-06-03 Thread Leif K-Brooks
My guess is that some moron subscribed [EMAIL PROTECTED] to the list. I'm sure a moderator will remove it soon enough. hui zhang wrote: how to get rid off this auto repsonse from [EMAIL PROTECTED] everytime i post in this news group i got auto repsonse from bonzi. is this bonzi the host of th

Re: [PHP] Re: Migration from register_globals=on to register_globals=off

2003-06-04 Thread Leif K-Brooks
Uh, I think you mean echo $_POST['path']; and echo $_GET['path']; Jonathan Wilkes wrote: Hi, What he means is that with "register_globals=off" you cannot do this: echo $path you need to do this (if the variable is sent by "POST" action) echo _POST('path') and through "GET" echo _GET('path

Re: [PHP] Re: Migration from register_globals=on to register_globals=off

2003-06-04 Thread Leif K-Brooks
Uh, just putting those variables at the top of your page won't help you. You need to do something with them. Esteban Fernández wrote: When you recivied that error ?, in a form ?, if is in a Form just put in the top of .php files this code $HTTP_GET_VARS["variable2"]; $HTTP_GET_VARS["variable3"]

Re: [PHP] php and mcrypt on windows

2003-06-04 Thread Leif K-Brooks
Please RTFM before asking questions! http://php.net/mcrypt answers your question. Gilberto Garcia Jr. wrote: How I can use php and mcrypt on windows? I mean. What I have to do to turn php able to use mcrypt function on windows. Thanks -- The above message is encrypted with double rot13 enco

Re: [PHP] Cookies and Expirations

2003-06-04 Thread Leif K-Brooks
The browser simply doesn't provide this information. You may be able to do it with javascript, but certainly not PHP. Tom Ray [Lists] wrote: Simple question: How do I check the expiration of a cookie that has been set? I can't seem to find it on php.net, if it is there..please provide the prop

Re: [PHP] Re: Using register_globals

2003-06-05 Thread Leif K-Brooks
It's true that register_globals being on only makes sloppy code more insecure. Most people aren't going to write perfect code, though. It's incredibly annoying to have to unset every variable that shouldn't be from an outside source. Even if you do so, it's very likely that you will forget o

Re: [PHP] Re: Using register_globals

2003-06-05 Thread Leif K-Brooks
e are other cases like this. I generally initialize variables before using them, but there's always going to be a time when someone forgets. That shouldn't present a security hazard, which is why I think register_globals should *always* be off. Rasmus Lerdorf wrote: On Wed, 4 Jun 2003

Re: [PHP] POST Variables get passed as GET variables.

2003-06-05 Thread Leif K-Brooks
This has absolutley nothing to do with PHP, and is a client-side issue. Michael A Smith wrote: Hey, So I've got this form that passes POST variables. However, they keep getting passed as get variables. Example: Get's sent to it as: url.php?action=something What's going on here? This is a n

Re: [PHP] [Newman] How to pass an image through PHP.

2003-06-07 Thread Leif K-Brooks
Not sure what you mean, but try passthru(). Philip J. Newman wrote: I would like to know where i should be looking to pass an image through PHP Thanks / Phil -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full

Re: [PHP] SESSION ISSUES

2003-06-08 Thread Jason k Larson
http://us2.php.net/manual/en/function.session-set-cookie-params.php set the domain strictly to "test.com" not "subdomain.test.com" etc etc -- Jason k Larson Dale wrote: HELP? I AM ABOUT TO PULL MY HAIR OUT? I have already spent time reading over the online php manual and

Re: [PHP] Need a safe way to get user supplied data into a varaible.

2003-06-08 Thread Leif K-Brooks
Why not just use file() and friends? Simon Coggins wrote: Hi, After lots of looking I've worked out I can't use heredoc for what I want. Does anyone else have any better ideas on how to do this: I have a template file that is used to generate a html page. in this template I currently have: $body

Re: [PHP] Session not working?

2003-06-09 Thread Leif K-Brooks
Use a browser that displays errors properly, like Mozilla. Frank Keessen wrote: Hi, It's pointing towards the booking.php (which is the 'sender' page..) Exact error message: The Page cannot be displayed.. So it's no 404.. I think.. Frank - Original Message - From: "Emma Jane Hogbin"

Re: [PHP] reading/writing the value of an / text value

2003-06-09 Thread Leif K-Brooks
This has nothing to do with PHP! Bruce Douglas wrote: Hi. I have a question regarding the DOM model. Does anyone know how to write to the / text value using the DOM model. I more or less can write to / attributes of the DOM. but I can't figure out how to write (or read) the text of a - attribute

Re: [PHP] sessions, IE and pop-up windows

2003-06-09 Thread Jason k Larson
Try adding the SessionID to the URL. openEdit("add=event&cellid=10&"); or a little better: $thisSession = Session_Name().'='.Session_ID(); openEdit("add=event&cellid=10&"); Then of course the editsmall.php must still do a session_start somewhere. --

Re: [PHP] solved Re: [PHP] sessions, IE and pop-up windows

2003-06-09 Thread Jason k Larson
*woot!* :) I love being right. ;) -- Jason k Larson Emma Jane Hogbin wrote: What ended up working was passing the session ID to the pop-up window "manually" by including it in the function (and thus the URL). emma -- PHP General Mailing List (http://www.php.net/) To unsubscr

Re: [PHP] string question

2003-06-11 Thread Leif K-Brooks
Put quotes around the value attribute of your input tag, for example Mukta Telang wrote: Hi, if a string is: $x="A.B. XYZ"; and if I post it as a hidden form control and echo $_POST['x'] then I get: A.B. and not "A.B. XYZ" ! What should I do? Mukta -- The above message is enc

Re: [PHP] Re: Help with a UBB Code style parser...

2003-06-11 Thread Leif K-Brooks
Even better, try my BBCode class. Much more flexible. http://www.phpclasses.org/browse.html/package/951.html Manuel Lemos wrote: Hello, You may want to try this class: Class: UBBCode http://www.phpclasses.org/ubb -- The above message is encrypted with double rot13 encoding. Any unauthorized

Re: [PHP] Eval or $$ are they the same or is $$ safer

2003-06-11 Thread Leif K-Brooks
Use $$ unless you need to use eval. Easier to read, faster to process. Also safer if you don't validate form data. Jason Lehman wrote: Is $$ the same as eval or is it different and my main question is, is it safer to use to for processing form data? -- The above message is encrypted with

Re: [PHP] nl2br

2003-06-11 Thread Leif K-Brooks
That's plain wrong. This is the /world wide/ web, not the IE users' club. Either stop that BS or keep off of the internet! Miles Thompson wrote: We limited our users to using IE -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be pro

Re: [PHP] nl2br

2003-06-11 Thread Leif K-Brooks
And it's my choice to tell him to go to hell. chris sherwood wrote: if they choose to limit to ie thats their choice ... -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law. -- PHP General Maili

Re: [PHP] nl2br

2003-06-11 Thread Leif K-Brooks
Standards-compliant HTML can be written just as cheaply and easily as IE-compliant HTML. If I chose to make my restraunt inaccessible to wheel chairs, I would have to face the consquences. chris sherwood wrote: That's true but how would you feel if you made some choices and then had people cri

Re: [PHP] checking is session_start is already set

2003-06-11 Thread Leif K-Brooks
if(!session_id()){ //Session not started } [EMAIL PROTECTED] wrote: dumb question but how can i check if i have loaded the session_start function without actually checking for a particular session variable , i need to know as to prevent it being called twise within my DB class which is seperate fr

Re: [PHP] Eval or $$ are they the same or is $$ safer

2003-06-11 Thread Leif K-Brooks
$$ is perfectly explained in the variable variables section. Shawn McKenzie wrote: Can you expand on this? I haven't found a ref to the $$ except for variable variables. $$ What does it do? How is it used? Thanks! Shawn "Leif K-Brooks" <[EMAIL PROTECTED]> wrote in message

Re: [PHP] array

2003-06-12 Thread Leif K-Brooks
Nothing as far as I can tell. It works fine for me. Diana Castillo wrote: If I write a code like this, $room_type=array(); $room_type[0][0]=4; echo "value in array is ".$room_type[0][0]; yet I dont get any results out, what did i do wrong? -- The above message is encrypted with double rot13

<    1   2   3   4   5   6   7   8   9   >