[PHP-DB] Passing the value of a variable from PHP to JavaScript.

2004-02-27 Thread Prabu Subroto
Dear my friends... I have my code like this : == ?php echo html script language='JavaScript' function tes(){ document.write('pJavaScript/p'); window.location.replace('http://192.168.23.1/coba/coba.php?vtes=$vtes'); } /script body ; echo diforward ke javascript; echo select

SV: [PHP-DB] Passing the value of a variable from PHP to JavaScript.

2004-02-27 Thread Henrik Hornemann
Hi, Where is the value of $vtes comming from? If it's a parameter in the call of your script, try something like ?php $vtes = $_GET[vtes]; echo Or even better dont use php to echo all of your javascript or html, but just the relevant values, like this: html script language='JavaScript'

Re: [PHP-DB] Passing the value of a variable from PHP to JavaScript.

2004-02-27 Thread Steve Davies
Hi Prabu you need to add a few bits: in the function: function tes(){ vtes = theform.vtes.value; #added line document.write('pJavaScript/p'); window.location.replace('http://127.0.0.1/coba/coba.php?vtes=' + vtes); #altered line in the body: form name='theform' and /form before the /html may

[PHP-DB] Using printer in Php code

2004-02-27 Thread Mücella Erdem Efe
I use the Php 4.3.3 on WindowsXP with Apache Server I want to use $handle = printer_open(PCLAB1); statement in my php program But it does not work. Almost I have defined the extension=php_printer.dll and printer.default_printer = PCLAB1in the c:/windows/php.ini file. The error is

Re: [PHP-DB] Database Search Engine ?

2004-02-27 Thread Muhammed Mamedov
I see. But what if I am using mySQL? *by the way, can you tell me from where I get them. -M.Mamedov - Original Message - From: Joshua D. Drake [EMAIL PROTECTED] To: Muhammed Mamedov [EMAIL PROTECTED] Cc: phpdb [EMAIL PROTECTED] Sent: Thursday, February 26, 2004 12:59 PM Subject: Re:

Re: [PHP-DB] Using printer in Php code

2004-02-27 Thread Erwin Kerk
Mücella Erdem Efe wrote: I use the Php 4.3.3 on WindowsXP with Apache Server I want to use $handle = printer_open(PCLAB1); statement in my php program But it does not work. Almost I have defined the extension=php_printer.dll and printer.default_printer = PCLAB1in the

[PHP-DB] User Authentication

2004-02-27 Thread Craig Hoffman
Hello, I could use some help here. I have a script that checks a user name and password against the MySQL DB. I have it set as a function so I included/require it on the page. Here is the script: function login($username, $password) // check username and password with db { // connect to db

Re: [PHP-DB] User Authentication

2004-02-27 Thread Erwin Kerk
Craig Hoffman wrote: $result = (select user_id password FROM users WHERE username='$username' AND password=md5('$password')); password is a reserved word. try this instead: $result = (select user_id password FROM users WHERE username='$username' AND `password`=md5('$password')); Erwin Kerk

Re: [PHP-DB] User Authentication

2004-02-27 Thread Peter Beckman
Try fixing your SQL: $result = (select user_id, password FROM users WHERE username='$username'... You forgot a comma between user_id and password. On Fri, 27 Feb 2004, Craig Hoffman wrote: // check if username $result = (select user_id password FROM users WHERE username='$username'

Re: [PHP-DB] User Authentication

2004-02-27 Thread Erwin Kerk
Peter Beckman wrote: Try fixing your SQL: $result = (select user_id, password FROM users WHERE username='$username'... You forgot a comma between user_id and password. Yup, that too. Oops, missed it too. Erwin Kerk Web Developer -- PHP Database Mailing List (http://www.php.net/) To

Re: [PHP-DB] User Authentication

2004-02-27 Thread Jason Wong
On Friday 27 February 2004 22:26, Craig Hoffman wrote: I could use some help here. I have a script that checks a user name and password against the MySQL DB. I have it set as a function so I included/require it on the page. Here is the script: [snip] When I change the return false to

Re: [PHP-DB] User Authentication

2004-02-27 Thread Erwin Kerk
Jason Wong wrote: You aren't actually performing any queries -- you're missing a mysql_query(). Ah. Did i mis that too? Unbelievable Erwin Kerk Web Developer -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DB] User Authentication

2004-02-27 Thread Craig Hoffman
Thanks - I can't believe I missed that. :( Craig __ Craig Hoffman - eClimb Media v: (847) 644 - 8914 f: (847) 866 - 1946 e: [EMAIL PROTECTED] w: www.eclimbmedia.com _ On Feb 27, 2004, at 8:34 AM, Jason Wong wrote: On Friday 27

Re: [PHP-DB] User Authentication

2004-02-27 Thread Jason Wong
On Friday 27 February 2004 22:42, Craig Hoffman wrote: Thanks - I can't believe I missed that. :( And I'm sure you'll want to stick in a mysql_error() as well. -- Jason Wong - Gremlins Associates - www.gremlins.biz Open Source Software Systems Integrators * Web Design Hosting * Internet

Re: [PHP-DB] Using printer in Php code

2004-02-27 Thread Erwin Kerk
Mucella (Erdem) Efe wrote: Yes I restart it and I solved the problem. Thank you. But at this time I can't use the printer that is not connected to the web server directly . I want to use a printer which is being used by web server as a network printer.Is it possible or not? Hmmm, I don't think

[PHP-DB] Uploading files

2004-02-27 Thread nikos
Hello list Allthough I set my PHP.in upload_max_file=4M my system refused to upload files bigger than 1M and the browser send an server not found error. Does anybody know anything about that? Thank you -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP-DB] Uploading files

2004-02-27 Thread Adam Voigt
Your max post size needs to be upped to, try making it 6M and see if that makes a difference. On Fri, 2004-02-27 at 10:05, nikos wrote: Hello list Allthough I set my PHP.in upload_max_file=4M my system refused to upload files bigger than 1M and the browser send an server not found error.

[PHP-DB] INSERT dynamic values problem - Need help urgently!

2004-02-27 Thread irinchiang
Hi all: I am trying to create a registration form whereby one of the user input is as follows: (a drop down menu with values retrieved from DB): - td class=lighter width=350Class Code:/td td class=lighter width=450

Re: [PHP-DB] INSERT dynamic values problem - Need help urgently!

2004-02-27 Thread Mikael Grön
Irin, First of all, you need to do this instead of what you're doing: while ($row = mysql_fetch_row($sql)) Second, this value should be storable just as any other values. i.e. mysql_query(insert into database (table) values(' . $_POST['class_code'] . ')); I hope this helps you a bit. Regards,

Re: [PHP-DB] Uploading files

2004-02-27 Thread nikos
It is allready 8M - Original Message - From: Adam Voigt [EMAIL PROTECTED] To: nikos [EMAIL PROTECTED] Cc: PHP-mailist [EMAIL PROTECTED] Sent: Friday, February 27, 2004 5:13 PM Subject: Re: [PHP-DB] Uploading files Your max post size needs to be upped to, try making it 6M and see if

Re: [PHP-DB] Uploading files

2004-02-27 Thread Adam Voigt
If your on a slow connection, it might be timing out. Try putting: set_time_limit(0); At the top of the page where the file is being uploaded to (not from), and see if that helps. On Fri, 2004-02-27 at 10:29, nikos wrote: It is allready 8M - Original Message - From: Adam Voigt

Re: [PHP-DB] SQL File Import problem (Was: HELP!!!)

2004-02-27 Thread Ricardo Lopes
I have the same problem right now, after a very short search in google i found this: http://www.mysql.com/documentation/mysql/bychapter/manual_Problems.html#Gone _away In my case i get the message max_allowed_packet is too small because i was trying to insert an image 1M into the database.

Re: [PHP-DB] INSERT dynamic values problem - Need help urgently!

2004-02-27 Thread Pavel Lobovich
Hi all: I am trying to create a registration form whereby one of the user input is as follows: (a drop down menu with values retrieved from DB): - td class=lighter width=350Class Code:/td td class=lighter

Re: [PHP-DB] Uploading files

2004-02-27 Thread Pavel Lobovich
If your on a slow connection, it might be timing out. Try putting: set_time_limit(0); At the top of the page where the file is being uploaded to (not from), and see if that helps. You dont have to do it. Script execution will not start before all posted files are uploaded. If your

Re: [PHP-DB] Passing the value of a variable from PHP to JavaScript.

2004-02-27 Thread Pavel Lobovich
Here is the working code: ?php echo html script language='JavaScript' function tes(){ document.write('pJavaScript/p'); o=document.getElementById('myselect'); window.location.replace('http://192.168.23.1/coba/coba.php?vtes='+o.value); } /script body ; echo diforward ke javascript; echo select

Re: [PHP-DB] PHP ODBC and Pervasive.SQL

2004-02-27 Thread Pascal Schaedeli
Robert, Thank you very much for your post: odbtp solved the problem and gave me a head start on moving the site to a Linux box. Pascal Robert Twitty [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi Pascal The odbc extension uses ODBC 2, while Access and Pervasive are most likely

Re: [PHP-DB] INSERT dynamic values problem - Need help urgently!

2004-02-27 Thread Daniel Clark
Try: OPTION VALUE=\$row['class_code']\ .$row[class_code]. /option; while ($row = mysql_fetch_array($sql)) { print OPTION VALUE=\$class_code\ .$row[class_code]. /option; } $result = $db-query($sql); -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP-DB] Uploading files

2004-02-27 Thread nikos
Pavel my form works fine with files 1M - Original Message - From: Pavel Lobovich [EMAIL PROTECTED] To: [EMAIL PROTECTED] Cc: PHP-mailist [EMAIL PROTECTED] Sent: Friday, February 27, 2004 6:50 PM Subject: Re: [PHP-DB] Uploading files If your on a slow connection, it might be timing

Re: [PHP-DB] Uploading files

2004-02-27 Thread nikos
Adam, everything happens rapidly. I dont think that the connection is the problem. I work in a local lan. Thank you - Original Message - From: Adam Voigt [EMAIL PROTECTED] To: nikos [EMAIL PROTECTED] Cc: PHP-mailist [EMAIL PROTECTED] Sent: Friday, February 27, 2004 5:38 PM Subject: Re:

Re: [PHP-DB] Uploading files

2004-02-27 Thread Daniel Brunner
Hello, Are you uploading files into MYSQL or any other DB?? Or are you uploading the files to a directory and inserting the location of the file in the database?? Dan On Feb 27, 2004, at 3:19 PM, [EMAIL PROTECTED] wrote: Pavel my form works fine with files 1M - Original Message -

[PHP-DB] Re: passing parameter to function

2004-02-27 Thread David Robley
In article [EMAIL PROTECTED], [EMAIL PROTECTED] says... Hi, Say I have a script that knows the value of a variable $codename. The script contains a function that needs to know the value of $codename. What is the syntax for passing the parameter to the function? Example: the script knows

Re: [PHP-DB] Uploading files

2004-02-27 Thread nikos
Im just doing a copy(...) in first place. In second Ill put some information in MySQL. I've made application inserting photos in BLOB columns without problems. Now I want to copy big files (5M) in my server. - Original Message - From: Daniel Brunner [EMAIL PROTECTED] To: [EMAIL