Re: [PHP] PHP & Excel

2002-05-20 Thread 1LT John W. Holmes
Can you just write out the formula to a cell? i.e. write the value "=SUM(C1:C5)" to a cell and see if it's evaluated? Just throwing things out... I would think that you wouldn't need formulas. Isn't that the idea of using PHP to create the Excel document? Have PHP compute the values of the "formu

Re: [PHP] refresh (part of) a page?

2002-05-20 Thread 1LT John W. Holmes
You can't have any output before you call header. Something in main.php on line 41 is causing some output that breaks the header() call. Be sure you don't have any whitespace at the end of included files. ---John Holmes... - Original Message - From: "savaidis" <[EMAIL PROTECTED]> To: <[E

Re: [PHP] I'm doing something wrong....

2002-05-15 Thread 1LT John W. Holmes
There is no [0]...only ['one'] and ['two']... Look through the array functions, there may be a way to reassign the keys... ---John Holmes... - Original Message - From: "Robert Rothe" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, May 15, 2002 4:35 PM Subject: [PHP] I'm doi

Re: [PHP] PHP Tag question

2002-05-15 Thread 1LT John W. Holmes
I believe he was talking about vs. not To: "Matthew Walker" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Wednesday, May 15, 2002 4:49 PM Subject: Re: [PHP] PHP Tag question > You can tell that from the php.ini file look for: > > ; Allow the tags are > recognized. > short_open_tag = On

Re: [PHP] php and servlets (fwd)

2002-05-15 Thread 1LT John W. Holmes
are you trying to do? ---John Holmes... - Original Message - From: "Maciej Przybycien" <[EMAIL PROTECTED]> To: "1LT John W. Holmes" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Wednesday, May 15, 2002 3:25 PM Subject: Re: [PHP] php and servlet

Re: [PHP] php and servlets (fwd)

2002-05-15 Thread 1LT John W. Holmes
eems to come because I generate html and include > from Java servlets. > > If my ' is included in html file and I load that html the image appears on the > screen with no problem. > > Do I need any special php compilation or support for Java servlets? > > Thanks

Re: [PHP] How program automatic 'filler forms' robots?

2002-05-15 Thread 1LT John W. Holmes
Well, the robots we have in the Army are controlled by wireless neural networks run by tiny chips implanted into our brains while at basic training. This controls the army of robots hidden under the mountains of Colorado that actually do all of our typing for us... anyway... You need to get a li

Re: [PHP] newbie: dynamically building associative arrays

2002-05-15 Thread 1LT John W. Holmes
Heh...you have to learn some SQL!! Try this query: SELECT term, count(*) AS cnt FROM table GROUP BY term; ---John Holmes... - Original Message - From: "ROBERT MCPEAK" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, May 15, 2002 2:16 PM Subject: [PHP] newbie: dynamically b

Re: [PHP] tag img and php

2002-05-15 Thread 1LT John W. Holmes
Yes, that does work, but the big question is if try_param.php is outputting an image? How are you doing it? Are you setting the appropriate headers()? ---John Holmes... - Original Message - From: "Maciej Przybycien" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, May 15, 200

Re: [PHP] Using Sessions under Win98/Apache

2002-05-15 Thread 1LT John W. Holmes
You probably want to get 4.2, or 4.2.1 if it's out. How are you registering variables for the session? Is register_globals on or off in your php.ini. If it's off, you register a variables just by using $_SESSION["var"] = "value"; instead of using session_register("var"); $var = "value"; If regi

Re: [PHP] counting max word length fails on line brake

2002-05-15 Thread 1LT John W. Holmes
You might want to look into wordwrap(), too www.php.net/wordwrap ---John Holmes... - Original Message - From: "Analysis & Solutions" <[EMAIL PROTECTED]> To: "PHP List" <[EMAIL PROTECTED]> Sent: Wednesday, May 15, 2002 10:42 AM Subject: Re: [PHP] counting max word length fails on line br

Re: [PHP] IF Statements

2002-05-15 Thread 1LT John W. Holmes
When in doubt, add in some carriage returns to space everything out to see if your braces match up. if ( ($this->checkReferralCB($this->benefitRef, $this->benefitNo, $this->childDOB)) && (!$this->checkLocation($this->post, "W")) && (!empty($this->child

Re: [PHP] shell command

2002-05-15 Thread 1LT John W. Holmes
Read the manual. www.php.net/exec among others... ---John Holmes... - Original Message - From: "Roman Duriancik" <[EMAIL PROTECTED]> To: "PHP-General" <[EMAIL PROTECTED]> Sent: Wednesday, May 15, 2002 9:30 AM Subject: [PHP] shell command > How to execute dos\winnt command in php sc

Re: [PHP] HTTPS spoofing and $_SERVER

2002-05-15 Thread 1LT John W. Holmes
Well, if you fix #1, that will fix #2 because you can use $_SERVER["HTTPS"], which can't be spoofed by the user. What versions of PHP and Apache are you using, on what OS? ---John Holmes... - Original Message - From: "George Whiffen" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wedn

Re: [PHP] Session destroy/close

2002-05-15 Thread 1LT John W. Holmes
Look at the session manual page and maybe set a shorter time limit for the session cookie. If the user isn't going to click on the Logout link, then there's really nothing you can do until they close the browser (which will stop the session / delete cookie automatically). Maybe you can check for

Re: [PHP] Direction to file-upload ?

2002-05-14 Thread 1LT John W. Holmes
You can't do that. You have to provide a seperate box for each file. ---John Holmes... - Original Message - From: <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, May 14, 2002 4:20 PM Subject: [PHP] Direction to file-upload ? Hi Folks, after studying and searching manual/arch

Re: [PHP] Genus who came up with "Self Destruct Code" & "Copy Pro tection"

2002-05-14 Thread 1LT John W. Holmes
- Original Message - From: "Miguel Cruz" <[EMAIL PROTECTED]> > On Tue, 14 May 2002, Collins, Robert wrote: > > $core_functions = > > "http://www.domain.com/path/to/file/core_functions.php";; > > require_once($core_functions); > > 1) You'd have to eval() it rather than requi

Re: [PHP] Genus who came up with "Self Destruct Code" & "Copy Pro tection"

2002-05-14 Thread 1LT John W. Holmes
[snip] > That's exactly what you need :) Have some core functions that are remotely > accessed. > > for example: > > $result = file("http://www.myserver.com/functions/square_root.php?input=4";); > > Then at www.myserver.com the square_root.php file would contain: >echo sqrt($input); > ?> > > D

Re: [PHP] Getting all files in a directory

2002-05-14 Thread 1LT John W. Holmes
Yes. ---John Holmes... - Original Message - From: "notoriousvic_ca" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, May 14, 2002 12:04 PM Subject: [PHP] Getting all files in a directory > Is there anyway I can get all the file and directories in a specific > directory? > >

Re: [PHP] Genus who came up with "Self Destruct Code" & "Copy Pro tection"

2002-05-14 Thread 1LT John W. Holmes
From: "Stuart Dallas" <[EMAIL PROTECTED]> > Collins, Robert <[EMAIL PROTECTED]> wrote: > > Put something like this in the top of each of the pages that have > > common functions > > > > if(file_exists("/path/to/file/core_functions.php")){ > > $core_functions = "/path/to/fi

Re: [PHP] switch and register_globals.

2002-05-14 Thread 1LT John W. Holmes
You can use $_REQUEST['foo'] which looks at all Cookie, Post, and Get data. switch($_REQUEST['foo']) You may have to still wrap the whole thing around an isset(). if(isset($_REQUEST['foo'])) { switch($_REQUEST['foo']) ... ---John Holmes... - Original Message - From: "Gerard Samuel

Re: [PHP] Combine 2 Db Columns with an Array?

2002-05-13 Thread 1LT John W. Holmes
So you are taking your results and putting it in an array, right? And you basically want to create two rows in your result array, for each row in the table? $result = mysql_query("SELECT Title, Alt_Title, Size, Price, More, Comment FROM table"); while($row = mysql_fetch_array($result)) { $Title

Re: [PHP] session problems...

2002-05-13 Thread 1LT John W. Holmes
In addition to what Kevin said: $_SESSION and $_session are not the same variables. Use quotes in your session_register(), too: session_register("u_name"), although you don't need session_register() at all, if you are using $_SESSION['u_name'] = "value"; syntax. ---John Holmes... > > Ok I thin

Re: [PHP] header-sending misbehaving

2002-05-13 Thread 1LT John W. Holmes
> On Monday 13 May 2002 23:47, erich wrote: > > suppose i want to login to a privileged area sending header info to > > browser, however, i get header warning as follows when i go to a db system > > named eskuel: > > Warning: Cannot add header information - headers already sent by (output > > star

Re: [PHP] How *not* to assume MySQL will return data?

2002-05-13 Thread 1LT John W. Holmes
$result = mysql_query("..."); if($row = mysql_fetch_array($result)) { do { //loop through results }while($row = mysql_fetch_array($result)); } else { echo "No rows returned"; } You could also just check mysql_num_rows() to see if any were returned and base your if off of that. ---John Ho

Re: [PHP] Import/Export with MS outlook/Outllok Express

2002-05-13 Thread 1LT John W. Holmes
The manual is your friend...go ahead...give it a try... http://www.php.net/manual/en/function.fgetcsv.php - Original Message - From: "Amit Singh" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, May 10, 2002 6:04 AM Subject: [PHP] Import/Export with MS outlook/Outllok Express

Re: [PHP] Genus who came up with "Self Destruct Code" & "Copy Pro tection"

2002-05-13 Thread 1LT John W. Holmes
> Sure there is no 100% secure copy protection. I think the question is: "how > can I make it most difficult to break?" The term I use is "keeping honest people out" Also, if you're on active duty military, don't write anything for them. From the few responses I've seen to a question I asked, th

Re: [PHP] Alternating Table Rows, Part Deux..

2002-05-10 Thread 1LT John W. Holmes
- Original Message - From: "Robert Cummings" <[EMAIL PROTECTED]> > Glenn Sieb wrote: > > $cname = (strcmp($previous,$line[0]) > > ? $line[0] : " "); > > print (" > BGCOLOR=#$color>\n\t$line[2]\n\t$cname\n\t$line[3]

Re: [PHP] Re: Debugger

2002-05-10 Thread 1LT John W. Holmes
> > php -l will let you know where your syntax errors are. > > What? > He said "php -l will let you know where your syntax errors are." Helping out where I can, ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] File Type not working in Uploaded File

2002-05-10 Thread 1LT John W. Holmes
Well, first thing I notice is that in your form you name your file input as "file", yet nowhere in your code do I see you getting any values from _FILES or $file (depending on your version of PHP). So...how do you expect it to do anything with your file if you don't tell it to?? Maybe you left out

Re: [PHP] header problem

2002-05-10 Thread 1LT John W. Holmes
Read the manual page on mail(), also. Even if you switch the two like Dan said, your headers are not in the appropriate format. www.php.net/mail ---John Holmes... - Original Message - From: "Analysis & Solutions" <[EMAIL PROTECTED]> To: "PHP List" <[EMAIL PROTECTED]> Sent: Friday, May 1

Re: [PHP] register_globals in php4

2002-05-09 Thread 1LT John W. Holmes
- Original Message - From: "Patrick Hsieh" <[EMAIL PROTECTED]> > Hello list, > > php4.1 recommends to set register_globals=off in php.ini to make php > more strict. My question is, if I turn off register_globals, what will > happen if any malicious user just try to modify the variable val

Re: [PHP] escaping quotes in forms and redisplaying variables in form fields

2002-05-06 Thread 1LT John W. Holmes
Yeah, you have to convert the single and double quotes to html entities so they are not mistaken for the end of the string. If you look at your source code, you'll see why it's happening. value = 'O'Bryan' value = "Joe "Bruiser" Smith" You can see how the 'O' is taken as the string, and the res

Re: [PHP] Sorting, sort of

2002-05-06 Thread 1LT John W. Holmes
Yeah, just dump it, edit it, and import it back into a table. 50 records shouldn't take you to long. You'll thank yourself later.. :) ---John Holmes... - Original Message - From: "Jason Soza" <[EMAIL PROTECTED]> To: "1LT John W. Holmes" <[EMAIL P

Re: [PHP] Sorting, sort of

2002-05-06 Thread 1LT John W. Holmes
You _definetly_ want to do this in your database, not with PHP and arrays. Databases are made to do this kind of sorting for you. I would modify your table first, adding in another column for first_name, then modify your form so that all data going in from now on is correct. The hard part will be

Re: [PHP] Grabbing ALL $_POST var at once.

2002-05-06 Thread 1LT John W. Holmes
f you need something more than that, let us know. With that many elements, maybe it's time to rethink your layout or naming conventions. ---John Holmes... - Original Message - From: "David J Jackson" <[EMAIL PROTECTED]> To: "1LT John W. Holmes" <[EMAIL PROTECTED

Re: [PHP] Grabbing ALL $_POST var at once.

2002-05-06 Thread 1LT John W. Holmes
> $From = $_POST['from']; > $Two = $_POST['two']; > $Subject = $_POST['sub_ject']; > $Comments = $_POST['comments']; > echo "$From";print "\n"; > echo $Two;print "\n"; > echo $Subject;print"\n"; > echo $Comments;print "\n"; > ?> > Why do you waste time assigning a variable to a variable...Is it

Re: [PHP] pass. vars. betn. javascript and php

2002-05-06 Thread 1LT John W. Holmes
> Is it possible to pass variables from a php page to a page using > javascript, and vice versa, > I've the variable - an array passed in the url of the page. You can use PHP to write HTML or Javascript. You can submit data to PHP through GET, POST, COOKIE, values. Those are your options. So, if

Re: [PHP] Formatting Information in header? Gridlines in Excel

2002-05-06 Thread 1LT John W. Holmes
Both...If you send an HTML file with Excel headers, Excel will open up and "translate" the HTML tables into the grid of the Excel spreadsheet. ---John Holmes... - Original Message - From: "Steve Bradwell" <[EMAIL PROTECTED]> To: "'Jay Blanchard'" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>

Re: [PHP] Redirect after submit

2002-05-06 Thread 1LT John W. Holmes
Where exactly do you see PHP fitting into this. It looks like it's all Javascript, and that's client-side nonsense... ---John Holmes... - Original Message - From: "Daniel Negron/KBE" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, May 06, 2002 9:27 AM Subject: [PHP] Redirect af

Re: [PHP] Formatting Information in header? Gridlines in Excel

2002-05-06 Thread 1LT John W. Holmes
> coming onlet me try adding a border="1" to the table tagthat works! Yeah, I was going to say that. How ever you format the HTML is how it's going to show up in Excel. Excel is just going to translate the HTML tables into it's own. Same goes for colors, bold, underline, center, etc. ---

Re: [PHP] Formatting Information in header? Gridlines in Excel

2002-05-06 Thread 1LT John W. Holmes
Are you actually sending an excell file, or just data that you expect excell to format? If your sending a file, then you have to create the grid lines there. These are HTTP headers that you are talking about, they wouldn't have any control over excell data. ---John Holmes... - Original Messa

Re: [PHP] Defining PHP varibles from URL

2002-05-06 Thread 1LT John W. Holmes
I would advise against doing that unless you really know what your doing. Doing it that way will allow anyone to type in any file on your server that PHP has access to and load it, or possibly load a file off of another server. That said, if you have a url like page.php?file=foo.inc Then that

Re: [PHP] phpMyAdmin Question

2002-05-06 Thread 1LT John W. Holmes
http://www.mysql.com/documentation/mysql/bychapter/manual_Reference.html#Sil ent_column_changes ---John Holmes... - Original Message - From: "Scott Reismanis" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, May 06, 2002 4:58 AM Subject: [PHP] phpMyAdmin Question > Hey all, >

Re: [PHP] phpMyAdmin

2002-05-03 Thread 1LT John W. Holmes
$result = mysql_query("INSERT INTO table (email, login, password) VALUES ('$email','$login','$password')"); ---John Holmes... - Original Message - From: "Rodrigo" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, May 03, 2002 12:58 PM Subject: [PHP] phpMyAdmin > Hi guys, I need

Re: [PHP] mssql_prev_result()???

2002-05-03 Thread 1LT John W. Holmes
MSSQL doesn't support LIMIT. You can use TOP, like SELECT TOP 10, * FROM users. I think that's the syntax. I don't know if there is a way to say "return rows from 10 - 20" in MSSQL. ---John Holmes... - Original Message - From: "Kevin Stone" <[EMAIL PROTECTED]> To: "PHP-general" <[EMAIL

Re: [PHP] Multiple mails to be sent from checkbox selection

2002-05-02 Thread 1LT John W. Holmes
Checkboxes are an easy way to do it. The value of a checkbox will only be sent if it's checked. If it's not checked, then that variable isn't even created. So the easiest way to do it is to use the email address as the value, and name the checkboxes all the same name with an [] to make it an arr

Re: [PHP] PRIMARY KEY vs. INDEX

2002-05-02 Thread 1LT John W. Holmes
> I guess I got a very easy question for the pros here... > I've been searching the documentaion of mySQL, but didn't > find the answer (even though I'm sure it's out there > somewhere :))... > > Is a primary key in mySQL automatically indexed? And is a > unique field indexed automatically ?(I don

Re: [PHP] Upload File

2002-05-02 Thread 1LT John W. Holmes
> Hi all, > i want ask something : How to upload files from local to server via php > ? > and i want use it with browser. > Please gimme the code. Please give me a break. Read the manual, there is a whole chapter telling you how to do this! http://www.php.net/manual/en Assuming you understand e

Re: [PHP] Email-attachment not working

2002-05-02 Thread 1LT John W. Holmes
> Do we have to upload the file first, which is to be attached? No. When you press the submit button, just speak slowly and clearly where the file is and PHP will understand you. What kind of video card do you have? ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubs

Re: [PHP] Opinions Wanted

2002-05-02 Thread 1LT John W. Holmes
You could use output buffering to write a static page of the results. You basically turn on output buffering at the beginning of the script, process as normal, and at the end, grab everything in the buffer, write it to disk, then use header() to direct the person to that page. Make a cron script

Re: [PHP] PHP and Log Analyzers

2002-05-01 Thread 1LT John W. Holmes
programming, it's easy enough to figure > things out in PHP. Unfortunately not having any web > programming experience, it's really easy to do create > things that can get you into a lot of trouble. I'm > always grateful for any security warnings and > informa

Re: [PHP] file upload / no tmp name or size?

2002-05-01 Thread 1LT John W. Holmes
Say it with me... "Show me the code!" No, louder! Yeah...that's good... What's my name? ---John Holmes... - Original Message - From: "Nick Wilson" <[EMAIL PROTECTED]> To: "php-general" <[EMAIL PROTECTED]> Sent: Wednesday, May 01, 2002 3:24 PM Subject: [PHP] file upload / no tmp name or

Re: [PHP] PHP Editors

2002-05-01 Thread 1LT John W. Holmes
> I would love to hear other people's experiences with these editors though. Second that. Has anyone used this new Dreamweaver? What's it like? I guess I'll have to download it tonite. Dreamweaver used to be my favorite, but it sucks for PHP so now I'm hooked on TextPad. Let us know if you have

Re: [PHP] php/.htaccess/.htpasswd

2002-05-01 Thread 1LT John W. Holmes
Yes, it's certainly possible. There are classes out there that manage .htaccess permissions for you and provide a web interface to do it. The scripts will write the appropriate .htaccess files based on what you choose to do. Search hotscripts.com or phpclasses.org for one of them. The passwords

Re: [PHP] PHP and Log Analyzers

2002-05-01 Thread 1LT John W. Holmes
If you know what is good for you, you will stop this method that your using and come up with a better one. You are open to so many attacks, it's unbelievable. I really, really, hope you have a solid validation routine for the files your including. How about using method='post' for your forms. The

Re: [PHP] Checkbox Initial Value based on record in db

2002-05-01 Thread 1LT John W. Holmes
It will only be checked if you put CHECKED in your HTML. if($myrow['abb'] == 1) { echo " checked "; } Add that into your input element. ---John Holmes... - Original Message - From: "Daniel Negron/KBE" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, May 01, 2002 1:04 PM Sub

Re: [PHP] File uploading fails

2002-05-01 Thread 1LT John W. Holmes
$HTTP_POST_FILES/$_FILES is provided to contain the uploaded file information. The contents of $HTTP_POST_FILES are as follows. Note that this assumes the use of the file upload name 'userfile', as used in the example script above: $HTTP_POST_FILES['userfile']['name'] The original name of t

[PHP] Cannot add header information

2002-05-01 Thread 1LT John W. Holmes
You CANNOT send anything to the browser before you set a cookie or start a session. You are displaying most of an HTML file, headers, javascript, HTML, etc, and then trying to include() a file that sets a cookie. Not going to work. ---John Holmes... >Warning: Cannot add header information -

Re: [PHP] PHP --help

2002-05-01 Thread 1LT John W. Holmes
Use $_GET["fn"] and $_GET["ln"], or $_POST[], depending on your action. Does anybody read the release notes for a product before you download and install it? I'm just going to save a standard message that covers this because I see questions like this continuing until everybody upgrades. ---John

Re: [PHP] apps that need register globals 'on' and others require

2002-05-01 Thread 1LT John W. Holmes
I remember a problem like this with 4.1.1, is it still present in 4.2? Register_global = Off ==> Use session_register("var"); Register_globals = On ==> Use $_SESSION["var"] = "value"; Is that still the case for 4.2, or can you do it either way? ---John Holmes... - Original Message - Fr

Re: [PHP] String check

2002-04-30 Thread 1LT John W. Holmes
I wouldn't recommend ereg() unless you have some complex pattern matching to do. If you're always looking for the same string, in the same spot,then just use substr(). Now...if you want to match _any_ 3 numbers, etc, then that's when ereg() comes into play. ---John Holmes... - Original Messa

Re: [PHP] String check

2002-04-30 Thread 1LT John W. Holmes
if(substr($string,0,3) == "123") { //do some stuff } ---John Holmes... - Original Message - From: "David Orn Johannsson" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, April 30, 2002 8:03 AM Subject: [PHP] String check Is ther any function that I could use to check if a str

Re: [PHP] PHP 4.2.0 on win2k, can't use mysql_fetch_* functions

2002-04-29 Thread 1LT John W. Holmes
out to be something dumb like a variable was empty that you though wasn't... Show us the code. ---John Holmes... - Original Message - From: "Austin Marshall" <[EMAIL PROTECTED]> To: "1LT John W. Holmes" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> S

Re: [PHP] $_POST[] - last character cut away!!

2002-04-29 Thread 1LT John W. Holmes
example code? - Original Message - From: "Herbert Mraz" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, April 29, 2002 4:00 PM Subject: [PHP] $_POST[] - last character cut away!! > Strange problem here (win2k - iis 5.0 - php 4.2.0): > > whenever I send formdata by POST-meth

Re: [PHP] PHP 4.2.0 on win2k, can't use mysql_fetch_* functions

2002-04-29 Thread 1LT John W. Holmes
Did you turn on Display_errors in php.ini? ---John Holmes... - Original Message - From: "Austin W. Marshall" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, April 29, 2002 3:52 PM Subject: [PHP] PHP 4.2.0 on win2k, can't use mysql_fetch_* functions > Is there something about

Re: [PHP] PHP "ignoring" dotfiles, permissions

2002-04-29 Thread 1LT John W. Holmes
what if you do this? require './.mydotfile.php'; ---John Holmes... - Original Message - From: "Frank" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, April 29, 2002 1:59 PM Subject: Re: [PHP] PHP "ignoring" dotfiles, permissions > > > >You know that "dot" files are hidden fil

Re: [PHP] Pixel Length of text message

2002-04-29 Thread 1LT John W. Holmes
Just my $0.02, but it's generally a bad idea to use fixed pixel size fonts. Some people need to be able to enlarge and decrease the font size within the browser, and this will not allow them to do it. Maybe if you explain what you're trying to accomplish, somone here can help you out a little mor

Re: [PHP] PHP "ignoring" dotfiles

2002-04-29 Thread 1LT John W. Holmes
Works fine on WinXP, PHP 4.1.1, IIS 5.1 ---John Holmes... - Original Message - From: "Frank" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, April 29, 2002 12:19 PM Subject: [PHP] PHP "ignoring" dotfiles > > Hello list, > > My PHP acts unexpected when requiring files with

Re: [PHP] parse errors not displayed (2nd time I ask!)

2002-04-29 Thread 1LT John W. Holmes
Just fix your parse errors. Who cares what error handler it goes to. Are you going to release code with parse errors in it and do you really want to get an email each time someone gets one? ---John Holmes... - Original Message - From: "Pedro Garre" <[EMAIL PROTECTED]> To: "php-general"

Re: [PHP] javascript and PHP

2002-04-29 Thread 1LT John W. Holmes
All you can do is use PHP to print out Javascript code. var something; something = ''; etc...It's no different than using PHP to print out HTML code. Now, if you want to get that Javascript variable "something" sent back to PHP, you have to assign it to a form element or tack it on

Re: [PHP] _SERVER variable insd prnt sttmnt

2002-04-29 Thread 1LT John W. Holmes
> > //print "" . This is the problem with not breaking out of a string to display a variable. Ideally, you would do it this way: print ""; But some people just have a problem with doing it that way, so you can use braces. print ""; If you don't use the braces, how is PHP supposed to know what

Re: [PHP] $this->

2002-04-29 Thread 1LT John W. Holmes
It's used in object oriented programming (OOP) with classes. $this refers to the current object. So $this->setup() in PHPLib is referring to the setup() function within the object. You can get a better explanation and examples by reading the manual page on OOP. http://www.php.net/manual/en/lang

Re: [PHP] return multiple value from function

2002-04-29 Thread 1LT John W. Holmes
Best you can do is return an array and call it like this: function myfunction($a,$b) { $r[0] = $a + 1; $r[1] = $b + 1; return $r; } list($c,$d) = myfunction(10,20); Adapt to your needs. ---John Holmes... - Original Message - From: "sanjay" <[EMAIL PROTECTED]> To: <[EMAIL P

Re: [PHP] operating system type

2002-04-25 Thread 1LT John W. Holmes
Look at a phpinfo() page...seems like there should be something that says this. Looked for you...$HTTP_ENV_VARS["OSTYPE"] or $_ENV["OSTYPE"] should work for you. ---John Holmes... - Original Message - From: "Steve Buehler" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, Apri

Re: [PHP] Parse Error - Help? (AGAIN)

2002-04-25 Thread 1LT John W. Holmes
> > To stop receiving the messages from undefined variables add this at top > > of your files: > > > > error_reporting(55); > > Or better yet, keep as you're doing and develop with E_ALL > and fix those E_NOTICE errors correctly! ;) Well said...don't hide and ignore the warnings...fix them. -

Re: [PHP] Parse Error - Help? (AGAIN)

2002-04-25 Thread 1LT John W. Holmes
$id has been assigned anything, if > it's empty it gets assigned 0. Correct? Then I can use if($id) > statements later on without having PHP return "Undefined Variable" > errors. Right? > > Thanks for your help, I'll work on my PHP listetiquette. > > Jason Soza

Re: [PHP] Parse Error - Help? (AGAIN)

2002-04-25 Thread 1LT John W. Holmes
I don't have your original code (which, btw, you shoudn't ever post that much code without explicitly saying what the error was, what line it was one, highlighting that line, and saying what you've done so far), but these errors are caused by not giving a default value to a variable, basically. I

Re: [PHP] Newbie Book & Database Question

2002-04-25 Thread 1LT John W. Holmes
I recommend The Manual. www.php.net/manual/en/ Honestly it's the best book you can read in the beginning. There are tons of examples and comments and you'll know exactly what's going on. No, you don't have to read every function, but at least read the first page for each category, that'll give y

Re: [PHP] Passing Variables with register_globals Off?

2002-04-24 Thread 1LT John W. Holmes
It still works, the value is in $_GET["db"] ---John Holmes... - Original Message - From: "Smileyq" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, April 24, 2002 6:09 AM Subject: [PHP] Passing Variables with register_globals Off? > I've noticed with the release of PHP 4.2

<    1   2   3   4   5   6