[PHP] return the amount of records in a mysql databace

2002-09-22 Thread Philip J. Newman
Can someone point me in the right direction to find out how i can return the amount of records in a mysql databace ? --- Philip J. Newman. PhilipNZ.com New Zealand http://www.philipnz.com/ [EMAIL PROTECTED] Mob: +64 (25) 6144012. Tele: +64 (9) 5769491. Family Site: Philip J. Newman Internet

Re: [PHP] Running a PHP script automatically?

2002-09-22 Thread Tom Rogers
Hi, Sunday, September 22, 2002, 2:44:54 PM, you wrote: JS Folks, I have a PHP script that needs to be executed automatically every 15 minutes. I have the option of doing this on a RedHat linux box, or on Windows 2000 Server. JS How would I do this (on either platform) and which would be

[PHP] counting guest users

2002-09-22 Thread Andy
Hi there, I am wondering how some pages count guest users. An example is phpbb. They always know how many guest users are browsing the site. Are they using cookies or db for this, or both? Maybe there is a code snipped out for this already? Thank you for any hint on that. Andy -- PHP

Re: [PHP] Running a PHP script automatically?

2002-09-22 Thread David McInnis
This is what your are looking for. It works great. I think this article assumes Linux which is what I use anyway. I guess that if you were to use windows you could schedule the task but you would need to call it using c:\pathTOphp\php.exe c:\pathTOscript\script.php Use Linux! David -

Re: [PHP]Running a PHP script automatically? FORGOT the link

2002-09-22 Thread David McInnis
Sorry, I forgot the link. http://phpbuilder.com/columns/darrell2319.php3 David - Original Message - From: David McInnis [EMAIL PROTECTED] To: Tom Rogers [EMAIL PROTECTED]; Joseph Szobody [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Sunday, September 22, 2002 12:16 AM Subject: Re:

[PHP] Re: Java?

2002-09-22 Thread Alexander Kleshchevnikov
On 04 ??? 2000, you wrote in php.general: I note that the documentation for PHP 4.0 says that Java is supported; I haven't been able to find any documentation on how it is supported. Can someone point me to something? Hugh -- Hugh Caley, Lumeria, Inc. Lead Systems Engineer [EMAIL

[PHP] Elliptic curve cryptology

2002-09-22 Thread EjdeR
i cant find any example about Elliptic curve cryptology.. do you have any example? i cant understand without an example :) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] A weired browser-session problem

2002-09-22 Thread Monil Chheda
Hello friends, I have a weired problem with sessions. I am using session_start(); session_register(Sessionname); The following is my problem. 1) User with valid username and password is given an Administration Menu. 2) Various options are there. He selects a particular option. 3) The selected

Re: [PHP] Elliptic curve cryptology

2002-09-22 Thread Danny Shepherd
http://www.amazon.com/exec/obidos/ASIN/1884777694/102-5129419-0804910 - Original Message - From: EjdeR [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, September 22, 2002 11:12 AM Subject: [PHP] Elliptic curve cryptology i cant find any example about Elliptic curve cryptology..

RE: [PHP] return the amount of records in a mysql databace

2002-09-22 Thread Mark Charette
select count(*) as n from ... where ... -Original Message- From: Philip J. Newman [mailto:[EMAIL PROTECTED]] Can someone point me in the right direction to find out how i can return the amount of records in a mysql databace ? -- PHP General Mailing List (http://www.php.net/) To

php-general Digest 22 Sep 2002 13:29:47 -0000 Issue 1600

2002-09-22 Thread php-general-digest-help
php-general Digest 22 Sep 2002 13:29:47 - Issue 1600 Topics (messages 117126 through 117161): Re: checking if an array is empty 117126 by: Michael Sims 117128 by: electroteque 117132 by: Michael Sims 117133 by: electroteque Re: Editor 117127 by:

[PHP] mysql password function

2002-09-22 Thread Murat Ö.
hi, i want to encode a string that users enter with mysql password function. but sometimes this code works sometimes don't. mysql warns me: Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in the code is: $result=mysql_query(select

Re: [PHP] Elliptic curve cryptology

2002-09-22 Thread EjdeR
i know searching.. and buy books. i asked for an little example.. Danny Shepherd [EMAIL PROTECTED] wrote in message 001201c2622d$4d52d640$0200a8c0@DANNYS">news:001201c2622d$4d52d640$0200a8c0@DANNYS... http://www.amazon.com/exec/obidos/ASIN/1884777694/102-5129419-0804910 - Original Message

Re: [PHP] A weired browser-session problem

2002-09-22 Thread Chris Shiflett
Monil, First, from the perspective of the Web server, there is only one browser. Also, there is no way to know when a user closes a browser. So, your problem just sounds like PHP is *maintaining* the session, which is exactly what it is supposed to do. :-) It is your job to maintain the data

[PHP] cookies?

2002-09-22 Thread :B nerdy
i wish to POST submit to a login form on another server and then after that POST some more information on the resulting page. the thing is, after the first login, the website sends me a cookie. it probably holds the session id and or authentication information. how will can i relay this back to

Re: [PHP] Re: LDAP (NDS) authentication example...

2002-09-22 Thread Stig Venaas
On Thu, Sep 12, 2002 at 09:37:22AM +1000, joshua wrote: i'm not sure if i follow you. i have never used ldap to write authentication scripts as i've only used the .htaccess method. to retrieve data you need to bind using a username/password combination that is valid. i guess you could

Re: [PHP] Elliptic curve cryptology

2002-09-22 Thread pan
i cant find any example about Elliptic curve cryptology.. do you have any example? i cant understand without an example :) Ten seconds of googling produced these URLs. http://www.certicom.com/resources/w_papers/w_papers.html

[PHP] closing browser's window

2002-09-22 Thread Murat Ö.
hi, is it possible to close client's browser's window from php script? thanks... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Create Thumbnails from image

2002-09-22 Thread Kjell Hansen
Hi, I'm using a Win2k with php4.1 and I'd like to make some thumbnails from pictures on my disk. I've gotten the impression that it's possible, but I havent' found out just how. I've stumbled across the ImageCopyResized function but it requires a imagehandle(?) to the file copied from. How do I

[PHP] Designing N-tier applications in PHP (long)

2002-09-22 Thread Michael Sims
I have a few application design questions that I was hoping someone might have some thoughts on. I'll warn you in advance that this post is kinda long winded. I'll try my best not to use two many trendy buzzwords, but I may not be able to avoid it. :-) I work for a real-estate company and one

[PHP] Web site analysys

2002-09-22 Thread Rosen
Hi, Can someone tell me where I can find a PHP script for tracking visitors on WEB site ( IP, Refferer, e.t.c ) (Like http://extremetracking.com ) Thanks, Rosen -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Elliptic curve cryptology

2002-09-22 Thread EjdeR
thnx Pan [EMAIL PROTECTED] wrote in message 004501c26249$89786a60$0901a8c0@plexus">news:004501c26249$89786a60$0901a8c0@plexus... i cant find any example about Elliptic curve cryptology.. do you have any example? i cant understand without an example :) Ten seconds of googling produced

Re: [PHP] return the amount of records in a mysql databace

2002-09-22 Thread Jeff Bluemel
this is only going to return records in a table, and not in a database select count(*) as n from ... where ... -Original Message- From: Philip J. Newman [mailto:[EMAIL PROTECTED]] Can someone point me in the right direction to find out how i can return the amount of records in a

[PHP] Re: closing browser's window

2002-09-22 Thread EjdeR
with javascript. yes ? echo input name=\Close\ onClick=\self.close();return false\ type=\button\ value=\Close\; ? Murat Ö. [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... hi, is it possible to close client's browser's window from php script? thanks...

[PHP] i got a method but how in php now?

2002-09-22 Thread :B nerdy
i can do what i need on a command line with curl. but how would i do it in php curl? this is my curl commands curl -D hc -d login=xxpassword=xxTYPE=login http://someserver.com/script/ curl -b hc -d sendmsg=1min=message=test http://someserver.com/msgscript/ so really want i need

Re: [PHP] closing browser's window

2002-09-22 Thread Chris Hewitt
Murat . wrote: is it possible to close client's browser's window from php script? From a php script yes, but not by PHP, because PHP runs on the server, not the browser. If you use JavaScript you can close it with window.close() HTH Chris -- PHP General Mailing List (http://www.php.net/)

Re: [PHP] algorythm question

2002-09-22 Thread Barýþ
oh my god. here is an example. $userLevels = array( 1 = 'Member', 2 = 'Admin', 4 = 'Writer', 8 = 'Expert'); $cat = 15; for ($mask=1; $mask = 64; $mask *= 2) { if ( $mask $cat ) { print Yes $mask is

[PHP] $_GLOBAL[var] or $_GLOBAL['var'] or $_GLOBAL[var]; ???

2002-09-22 Thread Victor
$_GLOBAL[var] or $_GLOBAL['var'] or $_GLOBAL[var] - I noticed that in a mysql statement you can only use: $_GLOBAL[var]. I would like to get the advice of more experienced php programmers out there about this. Which one of the above it the most best way to write? - Victor www.argilent.com

Re: [PHP] return the amount of records in a mysql databace

2002-09-22 Thread Chris Shiflett
Look through the MySQL functions. I seem to recall that there is a function for just about anything, and all you really want to do is find how many rows are in all the tables in a particular database. Thus, a couple of loops is all you need, with the outer one looping through each table

[PHP] RE: [PHP-DB] password function

2002-09-22 Thread Stephen Craton
Not sure if this has been answered yet but since the new version of PHP, I found that it doesn't like you entering the SQL statements in the query tag directly. Here's what you should do. $sql = select password(.$_POST['password'].) $conn = **YOUR DATABASE CONNECTION** $result =

RE: [PHP] counting guest users

2002-09-22 Thread Stephen Craton
I'm pretty sure they use cookies and see if the user is logged in or not. I'm not sure how exactly to make the script though.. Thanks, Stephen http://www.melchior.us http://php.melchior.us :: -Original Message- :: From: Andy [mailto:[EMAIL PROTECTED]] :: Sent: Saturday, September 21,

Re: [PHP] Designing N-tier applications in PHP (long)

2002-09-22 Thread Chris Shiflett
Michael Sims wrote: Recently we added a new application to what we provide that allows customers to sign up to receive new listing notifications based on a certain set of search criteria. I was charged with the responsibility of creating this application. I decided (for various reasons) to

[PHP] Re: [PHP-WIN] Create Thumbnails from image

2002-09-22 Thread Olivier Hubert
Hi, Read up on the image manipulation functions of PHP at http://www.php.net/manual/en/ref.image.php You will need to install the GD library if it's not already installed and once you do you will have access to all the functions described, including the ImageCopyResized function. To read the

[PHP] unlink() and IIS

2002-09-22 Thread Gerard Samuel
Im running a dev box with IIS 5/Apache/php 4.1.2 I just noticed that part of a script that is supposed to delete a file isn't working under IIS but is under Apache. Under IIS, php is installed as isapi. Paths are correct, and the file in question is created by the script and according to the

Re: [PHP] $_GLOBAL[var] or $_GLOBAL['var'] or $_GLOBAL[var]; ???

2002-09-22 Thread Peter J. Schoenster
On 22 Sep 2002 at 12:10, Victor wrote: $_GLOBAL[var] or $_GLOBAL['var'] or $_GLOBAL[var] - I noticed that in a mysql statement you can only use: $_GLOBAL[var]. I would like to get the advice of more experienced php programmers out there about this. Which one of the above it the most best

Re: [PHP] Designing N-tier applications in PHP (long)

2002-09-22 Thread Peter J. Schoenster
On 22 Sep 2002 at 10:23, Michael Sims wrote: of creating this application. I decided (for various reasons) to implement this application in Perl. I began programming in Perl back in 1995. Took up mod_perl (the only way to seriously use Perl btw on web apps) but as I work primarily on

[PHP] Update undefined List Values in DB

2002-09-22 Thread Sascha Braun
Hi, I am creating a kind of Shopsystem right now. One of the Funktions is going to be the possibiliy that the page admin can set an customer status to 1 or 0 via an listing of all customers. My Problem is, that I have to change more than one value at a time due to the Listing, where all

[PHP] Cannot Redeclare?

2002-09-22 Thread Stephen Craton
Hello, I was just wondering...again...why the heck I keep getting this error. I'm trying to make a function called login() and sometimes it works, other times it hates me and gives me this error: Fatal error: Cannot redeclare login() in c:\apache\htdocs\wiredphp\member\funcs.php on line 5

Re: [PHP] return the amount of records in a mysql databace

2002-09-22 Thread Philip J. Newman
?php $sql = SELECT count(*) FROM stompers WHERE 1; $sql_result = mysql_query($sql, $connection) or die (Could not get Query); $row = mysql_fetch_array($sql_result); $sUsers=$row[count(*)]; echo brWe have b$sUsers/b registered users.; ? This would be the best way (suggestions would be cool);

[PHP] What does this error mean

2002-09-22 Thread Randy Johnson
What does this error mean? Warning: Wrong parameter count for mysql_query() Thanks Randy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] What does this error mean

2002-09-22 Thread Daniel Kushner
Hi Randy, It means that you are calling the function without the right amount of parameters. The function mysql_query expects at least 1 (one) paramter: the query String. http://www.php.net/manual/en/function.mysql-query.php Regards, Daniel Kushner Need

Re: [PHP] Designing N-tier applications in PHP (long)

2002-09-22 Thread Michael Sims
On Sun, 22 Sep 2002 11:31:17 -0500, you wrote: Basically, it's really easy to create multiple interfaces to the same business logic. Don't try to make things more complicated than necessary, and since there is no need to use multiple languages in your implementation, that is a complexity

Re: [PHP] What does this error mean

2002-09-22 Thread Randy Johnson
I found out what it was: I mispelled a column in the insert statement. it actually had nothing to do with the parameters passed to the function i passed $query and $link and once i spelled the column right it went through just fine. why would it not just tell me that the column did not

Re: [PHP] Designing N-tier applications in PHP (long)

2002-09-22 Thread Michael Sims
On Sun, 22 Sep 2002 13:07:05 -0500, you wrote: Oh yeah, avoid that at all costs. Sounds like something like SOAP etc. could have been an answer, but then it depends on how you write your apps. Well, that is basically my question. I considered both SOAP and XML-RPC (which you mention later)

[PHP] Calling class functions using string variables?

2002-09-22 Thread Nick Richardson
Hi, Anyone know if it's possible to call a class function using 2 string variables WITHOUT instantiating the class? i.e.: $clName = myClass; $fuName = myFunc; $clName::$fuName(); I have tried several different combinations of eval and {} and just about everything else I can think of… and

RE: [PHP] Calling class functions using string variables?

2002-09-22 Thread Nick Richardson
Nevermind, I have finally figured it out... I was missing a ; in the eval statement. For anyone who wanted to know, there's 2 ways... 1) the long way $clName = myClass; $fuName = myFunc; $t = new $clName; $t-$fuName(); unset($t); 2) the short way $cl = myClass; $fu = myFunc;

Re: [PHP] Designing N-tier applications in PHP (long)

2002-09-22 Thread Peter J. Schoenster
On 22 Sep 2002 at 13:52, Michael Sims wrote: Well, that is basically my question. I considered both SOAP and XML-RPC (which you mention later) but I wasn't sure what the impact on performance would be. I am basically looking for anecdotal evidence from people who have implemented this sort

Re: [PHP] Designing N-tier applications in PHP (long)

2002-09-22 Thread Manuel Lemos
Hello, On 09/22/2002 03:38 PM, Michael Sims wrote: Basically, it's really easy to create multiple interfaces to the same business logic. Don't try to make things more complicated than necessary, and since there is no need to use multiple languages in your implementation, that is a complexity

[PHP] session_start() -- no more output

2002-09-22 Thread Hans Wilmer
Hi, the following PHP script causes me trouble: ?php session_register(bunt); phpinfo(); ? This is just a simple example. The problem is that the script produces no output at all when called with the browser. I could use ?php session_start(); echo test; ? instead, but I won't get any

[PHP] JAVASCRIPT INCLUDES

2002-09-22 Thread Georgie Casey
In HTML, you can do this: script language=JavaScript src=http://localhost/top_stuff.php?affiliate=1;/script But the script isn't executed before being used by the browser, it's returned with PHP tags and all, which obviously gives JS errors. Is there any setting you can change in Apache that

Re: [PHP] session_start() -- no more output

2002-09-22 Thread Michael Sims
On Mon, 23 Sep 2002 00:54:07 +0200, you wrote: ?php session_register(bunt); phpinfo(); ? This is just a simple example. The problem is that the script produces no output at all when called with the browser. Is it possible that display_errors is set to Off in your php.ini? If this were the

Re: [PHP] JAVASCRIPT INCLUDES

2002-09-22 Thread Chris Shiflett
Georgie, I'm not sure what you're wanting to do here, but it looks like you just want to use PHP to write some javascript. There's no need to make the browser request an additional page for this. Just do something like this in your PHP script: script language=javascript ? PHP stuff here

[PHP] solved

2002-09-22 Thread :B nerdy
its cool. ive solved it.. there is an option in php curl to save the headers. i just feed that back out. and it implements the cookies cheers :B Nerdy [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... i can do what i need on a command line with curl. but how

Re: [PHP] JAVASCRIPT INCLUDES

2002-09-22 Thread Georgie Casey
The Javascript has to be called from other servers, some who might not even support PHP. And yeah, when you actually visit the URL, it displays perfect JavaScript Thanks anyway Chris Shiflett [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Georgie, I'm not sure

[PHP] error with php and pdflib

2002-09-22 Thread Thoenen, Peter Mr. EPS
Hello everybody, Getting the following error when trying to generate a pdf file. Fatal error: PDFlib error: function 'PDF_set_info' must not be called in 'object' scope in E:\php\pdf.php on line 6 From what I can tell (google and php manual online) this error is caused when your webserver (IIS

Re: [PHP] Designing N-tier applications in PHP (long)

2002-09-22 Thread Michael Sims
On Sun, 22 Sep 2002 18:45:37 -0300, you wrote: Hello, Hi Manuel... Good idea, bad project. It is good that you diversify your knowlegde if that helps your career but I think it is not a good idea to make technology shift in a project that is already written and working well in a certain

Re: [PHP] JAVASCRIPT INCLUDES

2002-09-22 Thread Chris Shiflett
Georgie, Then what you're doing should work perfectly fine. Can you give more details about the error received? The reason I ask is because a Web browser will submit the exact same request for that URL that you do when you type it in yourself. Thus, if you don't see any PHP code, neither

[PHP] Re: JAVASCRIPT INCLUDES

2002-09-22 Thread Georgie Casey
Solved the problem. In case anyones wondering, I had the PHP script starting with a script and ending with /script when I already had that done in the HTML page. Simple Georgie Casey [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... In HTML, you can do this:

Re: [PHP] closing browser's window

2002-09-22 Thread Justin French
I can't imagine how anyone could thing this is a good idea! What's next? Change my browser preferences without asking me? Move some files around on my hard drive? FWIW, PHP is a SERVER SIDE language. It doesn't interact with the browser... by the time your browser recieves a page, it's just

Re: [PHP] Designing N-tier applications in PHP (long)

2002-09-22 Thread Michael Sims
On Sun, 22 Sep 2002 16:40:06 -0500, you wrote: I was just looking at my software architect book ... not half-way through yet. Good book. CORBA is what is mentioned know, a bit different than SOAP but I don't know enough of either yet to say for sure. Something like CORBA looks good to me,

Re: [PHP] Re: JAVASCRIPT INCLUDES

2002-09-22 Thread David Rice
Georgie: So just for clarity, this PHP script (http://localhost/top_stuff.php?affiliate=1;) was actually a file containing javascript? and no PHP? And out of curiosity, if that is so, why append the file name with .php -David On Sunday, September 22, 2002, at 07:20 PM, Georgie Casey wrote:

[PHP] Redirection

2002-09-22 Thread Sascha Braun
Hi, I want to post a form and after parsing i want to redirect the user to the home page. header() doesn't work in this circumstance, what can I do else? Greetings Sascha

Re: [PHP] Redirection

2002-09-22 Thread Todd Pasley
I use meta http-equiv=refresh content=DELAY;url=http://place.to.redirect.to Todd. - Original Message - From: Sascha Braun [EMAIL PROTECTED] To: PHP Mailingliste [EMAIL PROTECTED] Sent: Monday, September 23, 2002 9:42 AM Subject: [PHP] Redirection Hi, I want to post a form and

Re: [PHP] Redirection

2002-09-22 Thread Justin French
Validate the input BEFORE outputting anything to the browser... this way you have control over such problems. ? // validate // code // here if($valid) { header(...); exit; } ? HTML ? if(!$valid) { echo error on form; } ? /HTML The code below exit; will only be

Re: [PHP] Redirection

2002-09-22 Thread Chris Shiflett
Sascha Braun wrote: I want to post a form and after parsing i want to redirect the user to the home page. header() doesn't work in this circumstance, what can I do else? header() does work in this circumstance. In what way do you think it doesn't? header(Location: http://www.google.com/;);

[PHP] Re: more stress on server...

2002-09-22 Thread Jason Morehouse
You'd be hard pressed to find any difference in how the server reacts to either. You'll generally have better luck in some search engines if you use example 2. But onless you've got some strange reason hording all of your code in one file, I can't imagine any reason why example 1 would be of

Re: [PHP] Re: more stress on server...

2002-09-22 Thread Bill Leonard
On 9/22/02 9:08 PM, Jason Morehouse [EMAIL PROTECTED] wrote: Example 1 -index.php with these links: a href=index.phpHome/a a href=index.php?view=aboutHome/a a href=index.php?view=servicesHome/a all of your code in one file, I can't imagine any reason why example 1 would be of any use /

RE: [PHP] return the amount of records in a mysql databace

2002-09-22 Thread John Holmes
Then do a SHOW DATABASES query before that and loop through the results, counting the rows in each table. If you have to do this, though, I think you have some normalization issues with your database... ---John Holmes... -Original Message- From: Jeff Bluemel [mailto:[EMAIL

[PHP] Replace linefeed/newline from text inputs with br tag?

2002-09-22 Thread Patrick Lebon
If i have a textarea form input for users and they enter in return spaces, how can i replace the ascci chars with html tags? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] Date Time

2002-09-22 Thread Don Read
On 21-Sep-2002 Patrick wrote: Hi,, my server is located in the US and i live in Sweden, so when i try to run the following command i get a 8hour diffrence,, anyone got any idea of how to solve this? date(Y-m-j) putenv('TZ=Europe/Stockholm'); mktime(0,0,0,1,1,1970); echo

php-general Digest 23 Sep 2002 01:40:35 -0000 Issue 1601

2002-09-22 Thread php-general-digest-help
php-general Digest 23 Sep 2002 01:40:35 - Issue 1601 Topics (messages 117162 through 117220): mysql password function 117162 by: Murat Ö. Re: Elliptic curve cryptology 117163 by: EjdeR 117168 by: pan 117172 by: EjdeR Re: A weired browser-session problem

[PHP] Specify authentication for SMTP mailserver?

2002-09-22 Thread Joseph Szobody
I'm trying to send mail on a Windows machine using PHP. I have made the necessary corrections in the php.ini file for the SMTP server address, and the sendmail_from, my problem is that my SMTP server require authentication. How do I tell PHP to provide this? Thanks! Joseph -- PHP General

RE: [PHP] mysql password function

2002-09-22 Thread John Holmes
Use this: $result = mysql_query(SELECT PASSWORD( . $_POST['password'] . )); $password = mysql_result($result,0); or just use mysql_fetch_row() or AS in your query so you don't have to recreate that complex column name. ---John Holmes... -Original Message- From: Murat Ö.

Re: [PHP] return the amount of records in a mysql databace

2002-09-22 Thread Philip J. Newman
select count(*) as n from ... where ... This worked well for me. - Original Message - From: John Holmes [EMAIL PROTECTED] To: 'Jeff Bluemel' [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Monday, September 23, 2002 1:28 PM Subject: RE: [PHP] return the amount of records in a mysql databace

Re: [PHP] Redirection

2002-09-22 Thread Sascha Cunz
And also avoid including scripts that contain a linebreak or a space after any '?'. When I did this first time, it took me ages to find out what was wrong... :-) Sascha Am Montag, 23. September 2002 02:07 schrieb Justin French: Validate the input BEFORE outputting anything to the browser...

RE: [PHP] Replace linefeed/newline from text inputs with br tag?

2002-09-22 Thread John Holmes
If i have a textarea form input for users and they enter in return spaces, how can i replace the ascci chars with html tags? It'd be great if they had a function for this...they could call it nl2br() or something... www.php.net/nl2br ---John Holmes... -- PHP General Mailing List

Re: [PHP] Running a PHP script automatically?

2002-09-22 Thread Sascha Cunz
On the Linux box compile PHP as CGI (i.e. don't configure it as an apache mod). Then you can just run your script from the the command-line. This is called CLI (Command Line Interface), not CGI (Common Gateway Interface). The CGI is called from an WebServer; CLI get's called from a

[PHP] FW: Cannot Redeclare?

2002-09-22 Thread Stephen Craton
Hello, I was just wondering...again...why the heck I keep getting this error. I'm trying to make a function called login() and sometimes it works, other times it hates me and gives me this error: Fatal error: Cannot redeclare login() in c:\apache\htdocs\wiredphp\member\funcs.php on line 5

RE: [PHP] FW: Cannot Redeclare?

2002-09-22 Thread John Holmes
Funcs.php is probably being included twice at some point in your code. ---John Holmes... -Original Message- From: Stephen Craton [mailto:[EMAIL PROTECTED]] Sent: Sunday, September 22, 2002 10:56 PM To: [EMAIL PROTECTED] Subject: [PHP] FW: Cannot Redeclare? Hello, I was just

RE: [PHP] FW: Cannot Redeclare?

2002-09-22 Thread Daniel Kushner
When including the file funcs.php use include_one(). Regards, Daniel Kushner Need hosting? http://thehostingcompany.us -Original Message- From: Stephen Craton [mailto:[EMAIL PROTECTED]] Sent: Sunday, September 22, 2002 10:56 PM To: [EMAIL

RE: [PHP] FW: Cannot Redeclare?

2002-09-22 Thread Daniel Kushner
Typo: include_one() === include_once() -Original Message- From: Daniel Kushner [mailto:[EMAIL PROTECTED]] Sent: Sunday, September 22, 2002 11:06 PM To: [EMAIL PROTECTED] Subject: RE: [PHP] FW: Cannot Redeclare? When including the file funcs.php use include_one(). Regards, Daniel

[PHP] Help with mail...

2002-09-22 Thread Chuck \PUP\ Payne
Hi, Well after read php.net and my copy php 4 bible. I am lost with mail. I can get it to work if I do this... Mail ('[EMAIL PROTECTED]', 'Data Added', $fname, $lname .); But I can't get this to work...I know someone going to call me stupid but I am really having people with mail(), Is

RE: [PHP] Help with mail...

2002-09-22 Thread John Holmes
Variables are not evaluated within single quotes. You are trying to send an email to $address, literally. If you just have a single variable, lose the quotes entirely. Mail($address,$subject,$body); ---John Holmes... -Original Message- From: Chuck PUP Payne [mailto:[EMAIL PROTECTED]]

Re: [PHP] Help with mail...

2002-09-22 Thread Chuck PUP Payne
Ok, that work. Why does the ' (quote) not make it work is it because it's an array? Any thanks John that got it work. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Help with mail...

2002-09-22 Thread Justin French
strings in double quotes are evaluated looking for $vars and {$vars} to substitute. strings with in single quotes are not evaluated for vars. $var = my favourite color is {$col}; // works $var = my favourite color is $col;// works $var = 'my favourite color is $col';// doesn't work

Re: [PHP] Designing N-tier applications in PHP (long)

2002-09-22 Thread Garth Dahlstrom
If you need to bridge Perl and PHP, as suggested previously you could implement a web-service (SOAP or XML-RPC). Alternatively, you could write something Java bean and use PHP's Java support. Either of those will be costly from a performance point of view CORBA will be the same (from what I

[PHP] Comparing Alphanumeric values in a range

2002-09-22 Thread Samantha Savvakis
Hi, I have a task to generate a new document number for a given range. This document number is alphanumeric. Here is the problem: $lowrange1 = 90; $highrange1 = HZ; $currentno = 90CZZZ; I expect that the next number in the series is: $nextnum = 90D000; Before using this next number

[PHP] Re: Comparing Alphanumeric values in a range

2002-09-22 Thread Samantha Savvakis
Just quickly, forgot to mention: I've tested this on 2 platforms: Windows PHP 4.2.1 SCO Openserver 4.2.1 These two both don't work. I just tested on SCO OpenUnix 4.2.1 - this one works!! Problem is, I need this to work on SCO Openserver. Thanks, Sam Samantha Savvakis [EMAIL PROTECTED] wrote

[PHP] Re: Comparing Alphanumeric values in a range

2002-09-22 Thread Samantha Savvakis
Er..no, isn't working on OpenUnix. 90DZZZ - this should be 90E000 after the increment. This isn't working on any platform using PHP 4.2.1 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] mysql_num_rows error

2002-09-22 Thread Nick Varner
I am new to php and that the folowing error: Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/tbonestu/public_html/smallimages.php i dont know what i am doing wrong here is the code: $db = mysql_pconnect(connect info); mysql_select_db(images);

[PHP] Wrap content with a layout file

2002-09-22 Thread Patrick Lebon
Is there a way to create a layout file that can wrap around other pages with data in them. I am currently using two includes (one at the start of the page and one at the end) but was wondering if there is a better way to do this. Thanks -- PHP General Mailing List (http://www.php.net/) To

[PHP] Re: Specify authentication for SMTP mailserver?

2002-09-22 Thread Manuel Lemos
Hello, On 09/22/2002 10:45 PM, Joseph Szobody wrote: I'm trying to send mail on a Windows machine using PHP. I have made the necessary corrections in the php.ini file for the SMTP server address, and the sendmail_from, my problem is that my SMTP server require authentication. How do I

RE: [PHP] Re: Specify authentication for SMTP mailserver?

2002-09-22 Thread Pablo Oliva
You can run your own SMTP server, if it helps... http://www.postcastserver.com/ Extremely easy to set up. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] mysql_num_rows error

2002-09-22 Thread Tom Rogers
Hi, Sunday, September 23, 2001, 3:25:02 PM, you wrote: NV I am new to php and that the folowing error: Warning: mysql_num_rows(): NV supplied argument is not a valid MySQL result resource in NV /home/tbonestu/public_html/smallimages.php NV i dont know what i am doing wrong here is the code: NV