[PHP] Sessions can be dangerous

2003-05-31 Thread George Whiffen
Dear All, There doesn't seem to be much discussion of the disadvantages and long term dangers of using php sessions. So let's redress the balance: 1. Heterogeneous Code Environments php session data is not easily accessible from non-php code e.g. Perl/C/ASP etc. In contrast, either

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

2003-05-30 Thread George Whiffen
Daniel, Switch register_globals back on, and everything works as it always did. So do it! All this fuss about register_globals being insecure is a complete load of rubbish. This issue really bores me, but it seems programmers are wasting a lot of time on it, so I guess I'd better run through

[PHP] Re: sessions and domains

2003-05-30 Thread George Whiffen
Bk wrote: Hi I've to set up a shared shopping cart to buy items from four different sites and pay them at once passing trough a single checkout. Provided that these sites are hosted on the same server (actually in the same directory), but have different names, is it possible to share php

[PHP] Re: MySQL Date

2003-03-24 Thread George Whiffen
Why not get MySQL to compare your date with today? e.g. select if(Booking_Date = curdate(),'booked','free') as Todays_Status ... $Todays_Status = mysql_result($result,$i, Todays_Status); echo you are $Todays_Status today; I find it is much, much safer to only use the database for finding out

[PHP] Re: New window, new session

2002-06-25 Thread George Whiffen
Riaan Stander wrote: Hi there I know this is not a php specific question, but I don't know where else to ask. I've got the following situation. The website I'm currently working on has got a administration page where the administration user must be able to login as all the users

[PHP] Re: Problem with regular expressions

2002-06-25 Thread George Whiffen
Drew wrote: When I run the following script it returns String Okay! when it should say Invalid Characters Found. I've tried the script substituting $ for other characters, such as j, and it works just fine. What do I need to do? ?php $input = johnon@company.$com; if (ereg([$], $input))

Re: [PHP] rounding a number

2002-06-24 Thread George Whiffen
Jason Wong wrote: On Monday 24 June 2002 11:34, Phil Schwarzmann wrote: I want to round a number to the nearest decimal place... if the number is 4.623, I want it to display 4.6 if the number is 2.36, I want it to display 2.7 You don't really mean 2.36 -- 2.7 ?? Is there a function

[PHP] Re: rounding a number

2002-06-24 Thread George Whiffen
Phil Schwarzmann wrote: I want to round a number to the nearest decimal place... if the number is 4.623, I want it to display 4.6 if the number is 2.36, I want it to display 2.7 Is there a function that does this? round(), ceil(), floor() don't do this and I've checked through all the

[PHP] Re: getting the value of a javascript variable

2002-06-24 Thread George Whiffen
Otteneder Hermann wrote: hi everybody, i have a short problem: i have two drop down menues in a form. the content of the second dropdown is dependent from the selection in the first dropdown menue. now i want write a short javascript which runs on the onSelect - event of the first

Re: [PHP] Limiting text inputs by character count?

2002-06-24 Thread George Whiffen
John Holmes wrote: The best way to do this is server side with strlen(). You can use javascript or maxlength, but if a user wants to get around it, they can. ---John Holmes... John, The best way to do this is with both. maxlength/Javascript as a courtesy, strlen for security. As you

[PHP] Re: Using $PHP_SELF in a form

2002-06-24 Thread George Whiffen
Frank Miller wrote: I'm working on a project here at our university and need a little. We installed a wireless network and bought 5 ipaq's to use and experiment with. I wrote a work order system that we are still using. Basically the tech guys want to be able to check WO from the

[PHP] Re: Rounding....

2002-06-21 Thread George Whiffen
Matthew Clark wrote: Seeing as the mathematically correct way to round numbers is to round down to n for n-1=m=n.5 and up to n+1 for n.5mn+1, I wonder why the PHP round() function couldn't include a little 'fuzz' to handle the rounding problems we encounter due to floating point

[PHP] Re: Rounding....Message repeated

2002-06-21 Thread George Whiffen
Repeat of previous message in thread without the extra ugly wrapping, (sorry!!!) Matthew Clark wrote: Seeing as the mathematically correct way to round numbers is to round down to n for n-1=m=n.5 and up to n+1 for n.5mn+1, I wonder why the PHP round() function couldn't include a

Re: [PHP] Which costs more: connecting to a DB or accessing the file system?

2002-06-21 Thread George Whiffen
Mike wrote: Erik, thaks for the reply. I conducted a simple/rough benchmark to which is more expensive. I tested on a Intel PIII (450MHz 384MB ram) box running Win Xp, Apache 1.3.26 and PHP 4.2.1, and mysql 3.23.49 and freeBSD of similar stats (1000MHz, 1G ram). I used the adodb

Re: [PHP] Advanced User Authentication

2002-06-18 Thread George Whiffen
César aracena wrote: I like very much the idea of using a short way. Actually, I did and here's how: // After I queried the DB for a username password match: if (mysql_num_rows($result) 0) { $row = mysql_fetch_array($result); if

[PHP] HTTPS spoofing and $_SERVER

2002-05-15 Thread George Whiffen
Hi, I want to know if the user is connected on a secure socket and have two problems: 1. My Apache (Stronghold), variables are not turning up in $_SERVER or $HTTP_SERVER_VARS although they are in $GLOBALS e.g. I have $GLOBALS[SERVER_PORT] but not $_SERVER[SERVER_PORT]. This is with track vars

Re: [PHP] Cool PHP Tricks/Features ?

2002-05-15 Thread George Whiffen
Ummm, This output compression sounded cool to me when I came across it, but I wasn't sure it really helped or was appropriate for us to use: 1. My biggest concern is the slowest user i.e. at the end of a modem on the other side of the planet. I thought they would almost certainly have modem

Re: [PHP] HTTPS spoofing and $_SERVER

2002-05-15 Thread George Whiffen
behind, and they really don't like upgrading unless Debian have rubber stamped it). Kind regards, George - Original Message - From: George Whiffen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, May 15, 2002 7:35 AM Subject: [PHP] HTTPS spoofing and $_SERVER Hi, I want

[PHP] Re: Right way to do the MySQL thing

2002-03-08 Thread George Whiffen
The simplest way to do the connection thing is, as is often the case in php, to do nothing i.e. forget it. If you don't specify a connect id MySQL happily uses the last one opened, so the only thing you need do with the return from mysql_connect is check it for errors i.e. if

Re: [PHP] A good PHP Shop

2002-03-08 Thread George Whiffen
Here's a mini-checklist on tricky bits, some of which are as much about payment as much as cart: 1. Delivery Packing especially pricing on composite loads, destination, different speeds. 2. Sales taxes. 3. Quantity discounts, discount vouchers, reusable vouchers, loyalty cards. 4. Affiliate

[PHP] Re: uploading images

2002-03-08 Thread George Whiffen
Filippo Veneri wrote: When uploading image files to my powerpc linux box (derived from redhat 7.1) running apache + php4.0.4pl1 something wierd happen. Images get corrupted by (IMHO) php itself. It adds the following 2 lines at the top of the file: Content-Type: image/jpeg^M ^M

[PHP] Re: User accounts

2002-03-08 Thread George Whiffen
David Johansen wrote: I'm new to this php thing and I would like to set up a web page were the users can login and edit their preferences and all that stuff. I have the basic login stuff worked out and I was passing the username and password as a hidden input in the form, but then the

[PHP] Re: Help needed with speading up a function.

2002-03-08 Thread George Whiffen
William, You need a mathematician not a computer programmer. This is classic number theory which must have been very well explored. I have a very vague recollection that there may be partial proofs that there are no primes between x and y or no more than n primes between w and z for low ranges

[PHP] Re: time limit ?

2002-03-04 Thread George Whiffen
ÁC¬P wrote: How can I set a time limit for a form made by PHP (i.e.the value will auto transfer after a certain time) -- Ác¬P¤u§@«Ç http://fansing.hk.st/ ACG¤¬°Ê°Ï°ì(¤j®a¦h¨Ç¨Ó¶K¹Ï§a!) http://acgzone.hk.st/ HTML forms execute in the client's browser, which does not care at all whether

[PHP] Re: Multiple browser instances - is it possible to determine which browser?

2002-03-04 Thread George Whiffen
Neil Kimber wrote: We have an application framework that tidies up application session variables as you traverse from page to page It works really nicely - until a user opens up 2 instances of a browser Our code cannot distinguish between different browser instances, so browser instance 2

Re: [PHP] MySQL Query

2002-03-04 Thread George Whiffen
Erik Price wrote: I haven't seen yet a tutorial that teaches coding from the perspective of using register_globals off, which I think is pretty important (personal opinion) It's not that hard to pick up, though, once you've gotten started Still, I think it makes alot more sense to do so

Re: [PHP] how to: variable = php parsed file include

2002-03-04 Thread George Whiffen
Terry Kearns wrote: I'm not sure I understand you 100% but it sounds like you want to get the static HTML results of your dynamic PHP script and and do something with it. Happily, PHP is one of the few languages that can do this with ease :-) The feature you want is output buffering.

Re: [PHP] pages will not refresh publically

2002-03-04 Thread George Whiffen
I had this kind of old/new page problem because of proxy cacheing. The failsafe is to send out the full set of don't cache headers e.g. header(Expires: Mon, 26 Jul 1997 05:00:00 GMT); header(Last-Modified: . gmdate(D, d M Y H:i:s) . GMT); header(Cache-Control: no-cache,must-revalidate);

[PHP] Re: PATH INFO urls - replacing GET syntax

2002-02-25 Thread George Whiffen
rid of the trailing GET string. I know that's a bad way of doing it, but it was a temporary thing until I could find a way around it. I would really appreciate your help on this one. Thanks... Navid -Original Message- From: George Whiffen [mailto:[EMAIL PROTECTED]] Sent: Monday

Re: [PHP] zend studio 2.0

2002-02-25 Thread George Whiffen
Zeev, If you find that GUI tools are not overwhelmingly better for C++, Java product development, that does weaken the case for php studios even more. Why so? 1. Conciseness of php php is a high level application development tool so the code is, or at least, should mostly consist of highly

[PHP] Re: uploading files | how to avoid submitting twice?

2002-02-25 Thread George Whiffen
Jim Winstead wrote: Andy [EMAIL PROTECTED] wrote: Is there a way to redirect imediatelly to a waiting page? I tryed to redirect, but somehow the server is first uploading the file before something else happens. unfortunately, no. one thing you can do is use javascript to pop up a small

Re: [PHP] form submission error trapping

2002-02-25 Thread George Whiffen
Navid, $SCRIPT_NAME is sometimes a safer alternative than $PHP_SELF. The difference is that $PHP_SELF includes $PATH_INFO while $SCRIPT_NAME is just the name of the actual script running. http://www.php.net/manual/en/language.variables.predefined.php This becomes particularly important if you

[PHP] Re: PHP-JavaScript

2002-02-25 Thread George Whiffen
Mëòv î‰çîÎ òsyïn wrote: Is it posible to get values from javascript to PHP? Without having to post the variables.. Thanks //Mårten _ Chatta med vänner online, prova MSN Messenger: http://messenger.msn.se I'm not quite sure

[PHP] Re: form submission error trapping

2002-02-25 Thread George Whiffen
Jason, You didn't mention Javascript checks. Personally I really dislike having to wati for a page to reload before finding out that I've just failed to fill in a field. The Javascript to do basic on-page checks is all pretty simple stuff. Of course this doesn't mean we can skip checking the

[PHP] Re: Has anyone created or called a Web Service from PHP? (SOAP)

2002-02-25 Thread George Whiffen
Yeah, From php, I've called paybox (http://www.paybox.de), which is a mobile phone based payment service. You exchange transactions with them via xml. They have their own cartridge for php, but it's just a perl rewrite and not very wonderful, so I rewrote most of it. The basic approach is

[PHP] Apache keeping php waiting on output flush

2001-12-13 Thread George Whiffen
Hi, Apologies if this is more of an Apache question than a php one, but as it's about the relationship between them, I thought it was safe to bring it up here ;) While investigating a possible performance issue, I discovered that (according to microtime()), my script runs 5 times faster for a

[PHP] Is php safe for e-commerce applications?

2001-12-05 Thread George Whiffen
What a scary day, and it just gets worse 1. A user finds their account balance is displayed incorrectly on one of my live e-commerce sites. 2. I discover that floor() intermittently gives the wrong answer i.e. print floor(10*(8.20 - 0.20)); Answer : 79 print floor(10*(8.10 - 0.10));

[PHP] Re: Need advide on partnership agreement for a php application...

2001-11-27 Thread George Whiffen
Py wrote: Hello, I have an application wich I maintained on my servers (PHP, Apache, MySQL). I have a client that is already using the application trought a secure link directly from his web site. But he would like to have my application update a database directly on his server (Oracle)

Re: [PHP] How do I convert from perl to php? - Reality Check Taxation

2001-11-22 Thread George Whiffen
. in the required fields array - Original Message - From: George Whiffen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, November 21, 2001 7:28 AM Subject: Re: [PHP] How do I convert from perl to php? - Reality Check Taxation So I would have to write a seperate if condition for each

[PHP] Re: possible problems working with sessions

2001-11-22 Thread George Whiffen
Sorry if I'm off-topic, but I've always wondered what people use sessions for. I seem to be either dealing with logged-in users who I pick up via http-authentication and maintain any details I need in a user data structure, or casual users, for whom the odd hidden input field or occasional

[PHP] Different syntax = different performance (concatenating assignment)

2001-11-21 Thread George Whiffen
Dear All, I had always thought of concatenating assignment and concatenation + assignment to the same variable as really just syntatical variations i.e. I thought that $data = $data . some strings; and $data .= some strings; were just alternate syntaxes for the same operation. I've always

Re: [PHP] How do I convert from perl to php? - Reality Check Taxation

2001-11-21 Thread George Whiffen
So I would have to write a seperate if condition for each form input field i wanted to require? that doesn't make for a very dynamic script... if(!(isset($name) isset($address) isset($phone)) { echo You left one empty.; } Reality Check: We write code to solve real world

Re: [PHP] Process bar

2001-11-21 Thread George Whiffen
Arvydas V. wrote: Hello, I have to solve one problem - my script searches simply text document, so - if this document is big enought - i have to replace timeout of my script, besides - i have to make, that then this proceeds some kind of process bar must scroll until script finishes his

[PHP] Re: Authenticating Users with their Windows Login

2001-11-21 Thread George Whiffen
Feroze Md. Arif wrote: Hi, First of all, my apologies if this question has been asked earlier. I am in a hurry and I haven't checked the archives (Actually, I am in the process of doing it but am trying to cover all the bases). I know that PHP has functions which will allow Users to

[PHP] Re: Date Problem

2001-11-21 Thread George Whiffen
Mindhunter wrote: Hi, I am reading a date from an input in format 'DD-MM-' ex. 10-11-2001. Now I want to add 3 months to the date. I have tested mktime and strftime etc and no matter what I do I get the year as 1970. (Systemdate works fine). How would I go about adding 3 months to

[PHP] Re: Problem with Header!

2001-11-16 Thread George Whiffen
Yeah, It seems to be a black art to get the browsers to behave properly. I don't know if it's relevant but I use Content-disposition and Content-type rather than Content-Disposition and Content-Type and it seems to work for me for inline;. I haven't tried inside;. If you really can't get it

[PHP] Re: How to save a dynamic search result for later use as a static page?

2001-11-16 Thread George Whiffen
Look at the output buffer handling functions: ob_handler etc. These let you take the final (or intermediate) output of the script and do whatever you want with it e.g. save it, or in your case save it and empty it. In that case your user could have a simple SAVE button which ran the entire

[PHP] Re: strpos

2001-11-16 Thread George Whiffen
I always get strpos wrong. So typically in this case I would do something like: list($file,$ext) = explode('.',$yourimage); if ($ext != 'jpg' or $ext != 'jpeg') { error... } (More properly we should make sure jpg or jpeg are at the very end of the filename i.e. you probably don't like

[PHP] Re: JPG Images from database to filename.jpg

2001-11-16 Thread George Whiffen
I'm confused. Is your problem serving up the images in your database to the web or writing them out to files on the server? If it's serving images, I would expect you to have: select myimage from db Header(Content-type: image/jpeg); echo $myrow[myimage]; exit(); etc. If it's writing from

[PHP] Re: HTTP_POST_VARS and eval?

2001-11-16 Thread George Whiffen
Henrik, I think your problem is jsimply that you are not getting variable substitution of $HTTP_GET_VARS[whatever] inside double quotes. print whatever is $HTTP_GET_VARS[whatever]; is not safe. You need print whatever is {$HTTP_GET_VARS[whatever]}; or, (IMHO better), print 'whatever

[PHP] Re: Image Upload, renaming question

2001-11-16 Thread George Whiffen
Joe, One approach that works for me is to have a separate IMAGE table with an automatically generated primary key image_id (auto_increment with MySQL). I don't use this store the image, but just to give me the unique name for the image file. I also use the IMAGE table to store away the

[PHP] Re: Example code for multiple uploads? (Using PHP 4.0.6)

2001-11-16 Thread George Whiffen
Nate Carlson wrote: I'm trying to create a form that supports multiple uploads (of up to 4 files), but does not require each of them. I've tried all the code examples in the PHP documentation, and they don't appear to work with PHP 4.0.6. Basically, I get the file names returned in the

[PHP] Re: apache+php overloading when user clicks many times on the same link

2001-11-16 Thread George Whiffen
Peter Frlicka wrote: Hello. What does apache + php do if the user refreshes a page 10 times in a while before the scripts finishes? do all 10 .php scripts finish or do the first 9 get aborted? how can i solve the problem that when someone clicks a lot on a link (always the same link) the

[PHP] Re: PHP versus all other languages

2001-11-16 Thread George Whiffen
Pat Hanna wrote: I'm doing my senior exit project on database languages online. I'm asking for help from anyone who can provide any information on the comparison between the different languages. I'm comparing languages such as PHP, ASP, ColdFussion, perl and any others that I might not know

Re: [PHP] Session

2001-11-15 Thread George Whiffen
For the record: You can control the order of precedence of variable reading through a php.ini setting, variable_order, (replaces gpc_order). I believe the default is EGPCS i.e. environment, get, post, cookie, session. The last in the list takes precedence, i.e. session variables normally have

[PHP] Re: FTP Clients

2001-11-15 Thread George Whiffen
I kind of like Leech FTP, http://stud.fh-heilbronn.de/~jdebis/leechftp/downloads.html George Rudi Ahlers wrote: Sorry for the totally OT question, but can anyone recommend a good, FREE, FTP client for windows? I now have to pay for AceFTP aswell, which used to be free. Thank you Rudi

[PHP] Re: Including declare statements that contain variables

2001-11-15 Thread George Whiffen
Well you have an interestingly different approach! Personally I kind of like either having the SQL statements in-line with the rest of the code or functions that retrieve data for that particular query e.g. function get_students($class) { Anyway based on your approach: 1. You could still

Re: [PHP] keeping my code! Why?

2001-11-14 Thread George Whiffen
Zend encoder is probably your best option. But why do you want to hide your php code from your Server Admin? 1. If you can't trust your Server Administrator you've got big problems. Change your hosting! 2. Are you sure your code is so valuable? Developers always seem to greatly overestimate

[PHP] Re: Time out for file()? - Use fsockopen

2001-11-14 Thread George Whiffen
Jean-Arthur, Your set_time_limit/shutdown function solution looks like a clever trick. If you can come up with that you might just as well do the proper job with an fsockopen and socket_set_timeout. The manual pages on fsockopen, socket_set_timeout plus the user comments have plenty of useful

Re: [PHP] Help! How do i mail a value from a mysql databse?

2001-11-14 Thread George Whiffen
There's also a potential problem with: Her har du ditt passord: $myrow[id] \n God appetitt! Hilsen Subway You are using double quotes for the array index,(id) within a double quoted string. I'm amazed php accepts this, you might expect it to parse that as Her har du ditt passord: $myrow[ and

[PHP] Re: silly question

2001-11-14 Thread George Whiffen
Rodrigo, I don't quite understand your problem, it might help to see some of the php or form html. It might also help if I explain how I usually handle updates. I have a single php page with the form on it which is also the target of the form. Typically users get to the form via a link which

[PHP] Basic handling of pre 1901 dates

2001-11-13 Thread George Whiffen
I'm feeling dumb! The Basic Problem = Basically all I want to do is to output each day in turn from 1900 i.e. 01-Jan-1900 02-Jan-1900 03-Jan-1900 etc. But date() won't accept dates pre 13-Dec-1901 and mktime doesn't like anything pre 01-Jan-1970. I know I can get mysql to do

[PHP] Re: Validate CSV file With Table in Database!!

2001-09-13 Thread George Whiffen
Coenraad, Here are some links to relevant sections of the php manual. What you want to do is not too hard at all. I'm assuming that you want to upload the csv file via a web page. This is much less trouble for the user than fooling around with ftp. They get to browse their computer for the

[PHP] Re: newbie looking to sync access with MySQL

2001-09-07 Thread George Whiffen
Tom, Every man and his dog seems to have an Access database they want to view on the web. What I usually do for them is : a) Tell them to save the data from Access as a text file, comma separated. (It's a standard Access option). b) Give them a web page where they can upload it, (INPUT

Re: [PHP] php includes === Dreamweaver library items

2001-09-07 Thread George Whiffen
are going to be uglier but I guess it at least means that php gets some credit on the sites! Anyway, it's been very interesting to hear your ideas, and don't be surprised if I give up and switch to FastTemplate! George Robert V. Zwink wrote: George Whiffen, a) Nested Loops One problem

[PHP] ereg_replace - How do I stop it being greedy?

2001-09-07 Thread George Whiffen
Hi, I've got a problem with regular expression syntax with ereg_replace: ereg_replace(':start:(.*):end:','this is \\1',':start: first :end: middle :start: last :end:'); returns - this is first :end: middle :start: last but I want - this is first middle this is last The problem seems

Re: [PHP] ereg_replace - How do I stop it being greedy?

2001-09-07 Thread George Whiffen
modifier...it makes a dot match a newline as well, where normally it wouldn't jack -Original Message- From: George Whiffen [mailto:[EMAIL PROTECTED]] Sent: Friday, September 07, 2001 1:09 PM To: [EMAIL PROTECTED] Subject: [PHP] ereg_replace - How do I stop it being greedy

[PHP] Re: clear contents?

2001-09-07 Thread George Whiffen
Jeremy, I don't think it's possible to do what you want, and I have tried finding a way. With your header you are requestion an http authentication which means the browser has to store the username and password and send them with EVERY page. Those are the rules. The only way to tell the

[PHP] Re: clear contents? - Ignore previous response

2001-09-07 Thread George Whiffen
cookie(reprompt); header( 'WWW-Authenticate: Basic realm=Private' ); header( 'HTTP/1.0 401 Unauthorized' ); echo 'Authorization Required.'; exit; } else // Mark them ready to be reprompted next time cookie(reprompt,Yes); session_start(); } Sorry, George George

Re: [PHP] php includes === Dreamweaver library items

2001-09-06 Thread George Whiffen
/daid.php -Original Message- From: George Whiffen [mailto:[EMAIL PROTECTED]] Sent: Wednesday, September 05, 2001 2:34 PM To: [EMAIL PROTECTED]; Robert V. Zwink Subject: Re: [PHP] php includes === Dreamweaver library items Robert, Thanks for the suggestions, but... a) I do want to do

Re: [PHP] password sanity checker

2001-09-06 Thread George Whiffen
A cheap and cheerful rule is to insist on at least one numeric. Then you don't have to bother with a dictionary check! The php to force only alphas and numerics (upper or lower case) and at least one numeric is something like : - if (!ereg(^[a-zA-Z0-9]*[0-9][a-zA-Z0-9]*$,$password)) {

[PHP] php includes === Dreamweaver library items

2001-09-05 Thread George Whiffen
Hi, Has anyone experience of using Dreamweaver library item files (.lbi)s as php includes? We've got a standard header and footer to go across all pages on a site with the navigation etc. We want both the designers, (using Dreamweaver), and the php programmers to have access to these

[PHP] Re: Download function for php

2001-07-09 Thread George Whiffen
Mark Lo wrote: Hi, Is there any php download function for php. I am asking is the one like downloading the file from the server when people click the link. Like downloading php sources tar file. Thank you Mark No download function that I know of, but it isn't hard to

[PHP] Re: Help with a variable

2001-07-09 Thread George Whiffen
James Bartlett wrote: Hi, Is there some way that I can check to see if a variable is present? e.g. if (variable is not present) { set variable to 0; } else { some code that uses variable; } Thanks for any advice. James isset function variable is already 0 if !isset --

[PHP] Re: checking if checkbox is checked

2001-07-06 Thread George Whiffen
To check if a type checkbox variable has been set use isset() i.e. if ( isset($interest) or isset($interest2) or isset($interest3) or isset($interest4) or isset($interest1) ) { // Everthing is ok } else { $error = . ) This should do exactly what you want, and

[PHP] Re: javascript var on a php var...

2001-07-06 Thread George Whiffen
Romeo Manzur wrote: hi, I want to know how could I save a javascript variable on a php variable??? Thanks... It depends how the user will get to the php page: 1. Form If the user is about to submit a form and you want some Javascript variable from your page to end up as a php variable

[PHP] Re: Batch job in UNIX.

2001-07-06 Thread George Whiffen
mysql client will read from standard input, so you can just pipe in the sql e.g. echo insert into . ; | mysql -p -u root test or from a shell script you can use here is syntax e.g. mysql -p -u root test endmysql insert into endmysql Johan Vikerskog (ECS) wrote: If i want to

Re: [PHP] General Coding Question

2001-06-22 Thread George Whiffen
of the styles and then stick to it. What do you think? George Whiffen Chris Lee wrote: im here to start a flamewar. dont use then. why not use ' ? echo input type=\text\ name=\name\ value=\$name\ echo input type='text' name='name' value='$name' I like

Re: [PHP] How to connect to remote database server through PHP?

2001-06-22 Thread George Whiffen
Manisha, For the Sybase network connections, you are probably best off contacting Sybase specialists. php via the sybase_connect function is likely to look like any other Sybase client on a remote box, so the question is mostly about how do you get any Sybase client on your web server to

Re: [PHP] session question

2001-06-22 Thread George Whiffen
Derick, If you're seriously looking at thousands of concurent users (let alone millions) and the kind of budget on hardware and comms that implies, then I'd suggest you seriously look at your own session solution with MySQL or whatever. You can perfectly easily just use your own