Re: [PHP] if then else statement not working

2005-05-05 Thread Gabriel Guzman
Anasta wrote: What am i doing wrong here, the output is always 'empty' ?php $result = mysql_query(SELECT username FROM users WHERE seatnum='seat1') or die(mysql_error()); if (seatnum == seat1) { echo username; } else { echo 'empty'; } ? mysql_query() returns a resource, not the results

Re: [PHP] php/osx and firebird

2005-05-05 Thread Gabriel Guzman
James wrote: I've attempted to access a firebird database living on an osx/apache/php machine. snip How do I enable those functions? I've looked at the php documentation (http://uk2.php.net/manual/en/ref.ibase.php ) To enable InterBase support configure PHP --with-interbase[=DIR], where DIR

Re: [PHP] Code Review PLEASE !!!

2004-04-05 Thread Gabriel Guzman
On Monday 05 April 2004 04:00 pm, Matthew Oatham wrote: Yes I agree I need some validation, dunno whether to do server or client side validation. *both* :) you should always do server side validation on any data, especially if you are going to be putting it into your database. Client

Re: [PHP] Code Review PLEASE !!!

2004-04-05 Thread Gabriel Guzman
On Monday 05 April 2004 04:00 pm, Matthew Oatham wrote: I don't think the fleet_id example will be a problem though as this is retrieved from the database where the field is an int. google for SQL injection and you will see why what you currently have may cause you some problems. -- PHP

Re: [PHP] simple image manager app?

2004-04-01 Thread Gabriel Guzman
On Thursday 01 April 2004 09:41 am, Jeff D. Hamann wrote: I often travel and would like to be able to upload digital photos to my server (either using a simple multiple file upload (one that I can select multiple file using the windows file dialog, or some other method that's idiot proof) and

Re: [PHP] simple image manager app?

2004-04-01 Thread Gabriel Guzman
On Thursday 01 April 2004 09:41 am, Jeff D. Hamann wrote: I often travel and would like to be able to upload digital photos to my server (either using a simple multiple file upload (one that I can select multiple file using the windows file dialog, or some other method that's idiot proof) and

Re: [PHP] Slightly OT! PHP / HTML Editor for Linux

2004-02-04 Thread Gabriel Guzman
On Wednesday 04 February 2004 08:21 am, Burhan Khalid wrote: Shaun wrote: Hi, I've just switched from Windows to Linux and don't want to change back! However I used to use Dreamweaver MX for all my PHP / HTML editing, can anyone recommend a good alternative? Many thanks You

Re: [PHP] The PHP Problem

2004-01-30 Thread Gabriel Guzman
On Friday 30 January 2004 10:51 am, Ash wrote: How can I just write php in a text editor, save it as a .php, and view it in internet explorer, offline? you have to install php. http://www.php.net/manual/en/installation.php gabe. -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Add Reply-To to this list(s)

2003-11-25 Thread Gabriel Guzman
On Tuesday 25 November 2003 09:51 am, Dave G wrote: snip Telling people that they need to use proper email software and go about things in the way they don't expect which they are you refering to? i expect my reply button to reply to the person who sent the initial message... not everyone

Re: [PHP] looking for some software (helpdesk, intranet)

2003-11-21 Thread Gabriel Guzman
On Friday 21 November 2003 04:01 pm, Richard Baskett wrote: on 11/21/03 15:49, Chris W. Parker at [EMAIL PROTECTED] wrote: I'm looking for some helpdesk software and some intranet software with a MySQL backend. RT... http://bestpractical.com/ gabe. -- PHP General Mailing List

Re: [PHP] dir size

2003-10-03 Thread Gabriel Guzman
On Friday 03 October 2003 11:48 am, Robert Cummings wrote: On Fri, 2003-10-03 at 14:45, Jay Blanchard wrote: [snip] is it possible to count a size of a dir and all sub dirs in php ? and if, how? [/snip] $foo = exec(du -h); Hmmm this solution would appear to include the file sizes

Re: [PHP] How to comment out chunk of html/php mixed code?

2003-09-15 Thread Gabriel Guzman
On Monday 15 September 2003 12:59 pm, Wei Wang wrote: hi, This may sound very newbie. But since html comment uses !-- -- which doesn't comment out the php code. And the php comment /**/ // apparently doesn't work on html. So how do I comment out a chunk of html/php mixed code? probably the

Re: [PHP] divide

2003-09-09 Thread Gabriel Guzman
On Tuesday 09 September 2003 05:04 pm, phpu wrote: yes but if the result is a number like this 34056983 i wanna display this number like this 34,056,983 Please help me with this one that's exactly what number_format() does... from the example on www.php.net/number_format : ?php $number =

Re: [PHP] PHP Interview questions

2003-08-27 Thread Gabriel Guzman
On Tue, 2003-08-26 at 11:35, Curt Zirzow wrote: * Thus wrote Richard Baskett ([EMAIL PROTECTED]): on 8/26/03 9:57 AM, Robert Cummings at [EMAIL PROTECTED] wrote: This smells like a trick question... Are the switches connected to the same light bulb? You've only mentioned one light

Re: [PHP] PHP Interview questions

2003-08-26 Thread Gabriel Guzman
On Tue, 2003-08-26 at 10:36, Ray Hunter wrote: Everyone has given some great information. I have some ideas i would like to throw into the mix too. Here are some topics: 1. Questions regarding HTTP protocols. (SSL) One that was we like to use is: Describe an HTTP header. Most people

Re: [PHP] PHP Interview questions

2003-08-26 Thread Gabriel Guzman
On Tue, 2003-08-26 at 10:00, CPT John W. Holmes wrote: PHP is server side, so it obviously cannot control light bulbs. Use javascript. maybe the lightbulbs are connected to the server :) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] timestamp

2003-08-22 Thread Gabriel Guzman
On Thu, 2003-08-21 at 22:23, John Taylor-Johnston wrote: Not teasing, I know I could do this with some ready made script, but I want to make my own. I'm making a counter. CREATE TABLE `counter` ( `IPAddress` VARCHAR NOT NULL , `RemoteHost` VARCHAR NOT NULL , `TimeStamp` TIMESTAMP

Re: [PHP] timestamp

2003-08-22 Thread Gabriel Guzman
On Fri, 2003-08-22 at 11:50, John Taylor-Johnston wrote: I'm creating a counter. I want a timestamp where I can calculate if a time stamp is older than one hour, if so do X, if not do Y. so, you have the timestamp already correct? in your mysql db. all you should need to do is get the

Re: [PHP] '' Sign in _GET Parameter

2003-08-22 Thread Gabriel Guzman
On Fri, 2003-08-22 at 12:05, Pushpinder Singh Garcha wrote: Hello All, I am using an application where I retrieve user profile from a MySQL DB using the Company Name . I pass the name of the company to the PHP script as a '$_GET' parameter. e.g. when the name of the company is 'IBM'.

RE: [PHP] Stop neurotic posting

2003-08-14 Thread Gabriel Guzman
On Wed, 2003-08-06 at 11:44, Chris W. Parker wrote: A bad answer would be: RTFM http://php.net/preg_match; A good answer would be: That can be done with a regular expression. The function you're looking for is called preg_match. http://php.net/preg_match; I fail to see the difference.

Re: [PHP] open source content management systems?

2003-07-29 Thread Gabriel Guzman
this will probably get me into trouble on this list, but... I'm a big fan of zope. It's not written in php, but I have found it to be very robust and easy to work with. Opensource. www.zope.org Make sure you also check out the Content Management Framework for Zope. (cmf.zope.org - i think)

Re: [PHP] looking for some kind of CMS breakthough (slightly OT)

2003-07-29 Thread Gabriel Guzman
On Mon, 2003-07-28 at 19:04, Justin French wrote: Hi all, But, it still requires the writer to know a little mark-up (p,b,h1,h2,i,a,img,etc) in order to create an article with multiple paragraphs, sections, headings, images, etc, with well structured, valid mark-up. I'd be really

Re: Fw: [PHP] debuging and getting mor information about failures

2003-07-29 Thread Gabriel Guzman
A tip on avoiding errors cause by not enough }'s is to close any bracket immediately after you open it, so if I were writing a block of code: function foo(){ } I would write the above first, and then fill in between the {}'s. This way, when I get to the end of my script, I know I'm at least

Re: [PHP] unique id

2003-07-28 Thread Gabriel Guzman
On Sat, 2003-07-26 at 07:11, Curt Zirzow wrote: * Thus wrote jan ([EMAIL PROTECTED]): Hi there! What's the best way to create uids (unique ids) even when runnig at exactly same time (microseconds)? is this enough ??? $r = mt_rand(); $uid = uniqid(getmypid() . $r); If

RE: [PHP] I'm really getting annoyed with PHP

2003-07-23 Thread Gabriel Guzman
On Thu, 2003-07-24 at 15:12, Beauford.2005 wrote: FYI. I did this login page for another website last month and I used the code from it to do this one. The other one works perfectly. I checked that code again today and there is ABSOLUTELY no differnce. I even used the same variables and

RE: [PHP] can't restart session

2003-07-21 Thread Gabriel Guzman
p.s. I'm new to this list as you may have noticed and so far this is the only list that I've been on that doesn't use the list's address as the return address. Do I have to manually put it in the To box each time? not at all, just use the reply-all feature of your mail client. gabe. --