[PHP] Why this doesn't work ?

2005-10-24 Thread Mário Gamito

Hi,

Why this doesn't work ?

---
$query = SELECT COUNT (login) FROM WHERE login = '$login';
$result = mysql_query($query);
mysql_fetch_row($result);
---

It gives me
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL 
result resource in /var/www/html/registar_action.php on line 22


Any help would be apreciated.

Warm Regards,
Mário Gamito

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why this doesn't work ?

2005-10-24 Thread Colin Shreffler
It looks to me like you forgot to specify the table in your query:

SELECT COUNT (login) FROM TABLENAME GOES HERE WHERE login = '$login'

 Hi,

 Why this doesn't work ?

 ---
 $query = SELECT COUNT (login) FROM WHERE login = '$login';
 $result = mysql_query($query);
 mysql_fetch_row($result);
 ---

 It gives me
 Warning: mysql_fetch_row(): supplied argument is not a valid MySQL
 result resource in /var/www/html/registar_action.php on line 22

 Any help would be apreciated.

 Warm Regards,
 Mário Gamito

 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php





Thank you,
Colin Shreffler
Principal
303.349.9010 - cell
928.396.1099 - fax
[EMAIL PROTECTED]

Warp 9 Software, LLC.
6791 Halifax Avenue
Castle Rock, CO 80104

Confidentiality Notice: The information in this e-mail may be confidential
and/or privileged. This e-mail is intended to be reviewed by only the
individual or organization named in the e-mail address. If you are not the
intended recipient, you are hereby notified that any review, dissemination
or copying of this e-mail and attachments, if any, or the information
contained herein, is strictly prohibited.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why this doesn't work ?

2005-10-24 Thread Mário Gamito

Hi,

Sorry, i do have the table name.
It just passed me while transcripting.

The code is:

---
$query = SELECT COUNT (login) FROM formacao WHERE login = '$login';
$result = mysql_query($query);
mysql_fetch_row($result);
---

It works perfectly on MySQL prompt.

Regards,
Mário Gamito

Colin Shreffler wrote:

It looks to me like you forgot to specify the table in your query:

SELECT COUNT (login) FROM TABLENAME GOES HERE WHERE login = '$login'



Hi,

Why this doesn't work ?

---
$query = SELECT COUNT (login) FROM WHERE login = '$login';
$result = mysql_query($query);
mysql_fetch_row($result);
---

It gives me
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL
result resource in /var/www/html/registar_action.php on line 22

Any help would be apreciated.

Warm Regards,
Mário Gamito

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php







Thank you,
Colin Shreffler
Principal
303.349.9010 - cell
928.396.1099 - fax
[EMAIL PROTECTED]

Warp 9 Software, LLC.
6791 Halifax Avenue
Castle Rock, CO 80104

Confidentiality Notice: The information in this e-mail may be confidential
and/or privileged. This e-mail is intended to be reviewed by only the
individual or organization named in the e-mail address. If you are not the
intended recipient, you are hereby notified that any review, dissemination
or copying of this e-mail and attachments, if any, or the information
contained herein, is strictly prohibited.



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Why this doesn't work ?

2005-10-24 Thread Jay Blanchard
[snip]
---
$query = SELECT COUNT (login) FROM formacao WHERE login = '$login';
$result = mysql_query($query);
mysql_fetch_row($result);
---
[/snip]

mysql_query() requires a connections resource

$result = mysql_query($query, $myConnection);

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Why this doesn't work ?

2005-10-24 Thread Jim Moseby
 
 [snip]
 ---
 $query = SELECT COUNT (login) FROM formacao WHERE login = '$login';
 $result = mysql_query($query);
 mysql_fetch_row($result);
 ---
 [/snip]
 
 mysql_query() requires a connections resource
 
 $result = mysql_query($query, $myConnection);

The connection resource is optional.  It will use the most recent connection
if not specified.

JM

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Why this doesn't work ?

2005-10-24 Thread Scott Noyes
 $query = SELECT COUNT (login) FROM formacao WHERE login = '$login';
 $result = mysql_query($query);

Make this line instead
$result = mysql_query($query) or die(mysql_error() .  with the query $query;
and you'll likely see the error.

--
Scott Noyes
[EMAIL PROTECTED]

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Why this doesn't work ?

2005-10-24 Thread Jay Blanchard
[snip]
 $query = SELECT COUNT (login) FROM formacao WHERE login = '$login';
 $result = mysql_query($query);
 mysql_fetch_row($result);

The connection resource is optional.  It will use the most recent connection
if not specified.
[/snip]

Then try this

$query = SELECT COUNT (login) FROM formacao WHERE login = '.$login.';

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why this doesn't work ?

2005-10-24 Thread Mário Gamito

Hi,


Make this line instead
$result = mysql_query($query) or die(mysql_error() .  with the query $query;
and you'll likely see the error.


Here it goes:

You have an error in your SQL syntax; check the manual that corresponds 
to your MySQL server version for the right syntax to use near '(login) 
FROM formacao WHERE login = 'a'' at line 1


Regards,
Mário Gamito

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why this doesn't work ?

2005-10-24 Thread Jordan Miller
why don't you just echo your $query to see if it is coming out  
correctly, before even trying to mess with mysql_query()? I think you  
should be able to see the problem from there.


Jordan



On Oct 24, 2005, at 12:44 PM, Mário Gamito wrote:



Hi,




Make this line instead
$result = mysql_query($query) or die(mysql_error() .  with the  
query $query;

and you'll likely see the error.




Here it goes:

You have an error in your SQL syntax; check the manual that  
corresponds to your MySQL server version for the right syntax to  
use near '(login) FROM formacao WHERE login = 'a'' at line 1


Regards,
Mário Gamito

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php







--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Why this doesn't work ?

2005-10-24 Thread Jim Moseby
 
 Hi,
 
  Make this line instead
  $result = mysql_query($query) or die(mysql_error() .  with 
 the query $query;
  and you'll likely see the error.
 
 Here it goes:
 
 You have an error in your SQL syntax; check the manual that 
 corresponds 
 to your MySQL server version for the right syntax to use near 
 '(login) 
 FROM formacao WHERE login = 'a'' at line 1
 

Apparently, $login does not contain the text you think it does.  Either echo
$login to see, or echo $query to see what is actually being passed to mysql.

JM

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why this doesn't work ?

2005-10-24 Thread Phillip Oertel
ah!

remove the whitespace between the COUNT and () : COUNT(login) instead of
COUNT () ...


 Hi,
 
 Make this line instead
 $result = mysql_query($query) or die(mysql_error() .  with the query
 $query;
 and you'll likely see the error.
 
 
 Here it goes:
 
 You have an error in your SQL syntax; check the manual that corresponds
 to your MySQL server version for the right syntax to use near '(login)
 FROM formacao WHERE login = 'a'' at line 1
 
 Regards,
 Mário Gamito

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why this doesn't work ?

2005-10-24 Thread Richard Lynch
On Mon, October 24, 2005 12:25 pm, Mário Gamito wrote:
 ---
 $query = SELECT COUNT (login) FROM WHERE login = '$login';
 $result = mysql_query($query);
 mysql_fetch_row($result);
 ---

 It gives me
 Warning: mysql_fetch_row(): supplied argument is not a valid MySQL
 result resource in /var/www/html/registar_action.php on line 22

First, I'm going to give you a fish:
... FROM WHERE ...
Which MySQL database TABLE is it that you think you are looking in?
You have to tell it which table to look in.

Now I'm gonna teach you to catch fish:
Change your middle line to:
$result = mysql_query($query) or die(br /$querybr / .
mysql_error());

That will get PHP and MySQL to TELL YOU what's wrong, instead of just
saying Something's wrong

-- 
Like Music?
http://l-i-e.com/artists.htm

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Why this doesn't work ?

2005-05-24 Thread Mário Gamito
Hi,

Hi have this bit of code:

-
echo
 script language=\JavaScript\
  window.location=\valid_cv_insert.php?email=$email\
 /script;
-

but when passing to file valid_cv_insert.php, $email value doesn't go along.
The page that has this code knows tha value of $email variable.

How can i turn this around ?

Thanking you in advance.

Warm regards,
Mário Gamito

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why this doesn't work ?

2005-05-24 Thread John Nichel

Mário Gamito wrote:

Hi,

Hi have this bit of code:

-
echo
 script language=\JavaScript\
  window.location=\valid_cv_insert.php?email=$email\
 /script;
-

but when passing to file valid_cv_insert.php, $email value doesn't go along.
The page that has this code knows tha value of $email variable.


Echo out $email to see if what you think is there actually is.

--
John C. Nichel
ÜberGeek
KegWorks.com
716.856.9675
[EMAIL PROTECTED]

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why this doesn't work ?

2005-05-24 Thread Rahul S. Johari

Ave,

I tried:

forminput type=text name=emailINPUT type=submit value=SUbmit
name=Submit/form

?php
if($Submit) {
echo
 script language=\JavaScript\
  window.location=\delete.php?email=$email\
 /script;
}
?

In a simple page. It worked absolutely fine... The value of $email was
passed along to delete.php
I don't think there's something wrong with your code below.. There might be
some other reason affecting the transfer of the $email variable value.

Rahul S. Johari
Coordinator, Internet  Administration
Informed Marketing Services Inc.
251 River Street
Troy, NY 12180

Tel: (518) 266-0909 x154
Fax: (518) 266-0909
Email: [EMAIL PROTECTED]
http://www.informed-sources.com


On 5/24/05 8:24 AM, Mário Gamito [EMAIL PROTECTED] wrote:

 Hi,
 
 Hi have this bit of code:
 
 -
 echo
  script language=\JavaScript\
   window.location=\valid_cv_insert.php?email=$email\
  /script;
 -
 
 but when passing to file valid_cv_insert.php, $email value doesn't go along.
 The page that has this code knows tha value of $email variable.
 
 How can i turn this around ?
 
 Thanking you in advance.
 
 Warm regards,
 Mário Gamito

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why this doesn't work ?

2005-05-24 Thread Jochem Maas

Mário Gamito wrote:

Hi,


hi,

the subject line of your post is not so good - make the subject relevant
to your question, asking 'why doesn't this work' is like asking 'why are we 
here'.

its liable to get you either:

a, no answers.
b, answers like this one.
c, really useful answer like '42'

ok on with the show



Hi have this bit of code:

-
echo
 script language=\JavaScript\
  window.location=\valid_cv_insert.php?email=$email\
 /script;
-

but when passing to file valid_cv_insert.php, $email value doesn't go along.


inside valid_cv_insert.php $email will only be set by the GET query
if the ini setting register_globals is on.

try doing this inside valid_cv_insert.php:

? var_dump( $_GET, $GET['email'] ); ?

(depending on your version of php $_GET may or not exist in any case
check this out (read it carefully!):

http://php.net/en/language.variables.predefined



as a sidenote, make sure you're doing some dumb like:

? $email = 'x'; echo $emial; ?

... its the kind fo thing I have wasted literally days on in the past.


The page that has this code knows tha value of $email variable.


how does it know it? possibly because you do something like?:

? $email = [EMAIL PROTECTED]; ?



How can i turn this around ?


you won't find much useful info on the back of your monitor ;-)
it wasn't too clear exactly what you were looking for but the gist seems
to be that you need to read up a bit on what register_globals is, the
fact that the default has gone from 'On' to 'Off' somewhere in the not so 
distance
past and what the consequences are for your code.

still stuck? go read the manual a bit... then come back and ask some more. :-)

good luck.



Thanking you in advance.

Warm regards,
Mário Gamito



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] why this doesn't work as an external file but does inte rnally?

2004-10-06 Thread Vail, Warren
Perhaps you fixed things but they all appeared to work for me (at least
mostly).

https://celestica.tristarpromotions.com/NEW/index3.php

This last one, seemed to not do the mouseout on the contact button, but
all three seemed to work.

Good job,

Warren Vail


-Original Message-
From: John Nichel [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, October 05, 2004 8:20 PM
To: 'PHP Mailing Lists'
Subject: Re: [PHP] why this doesn't work as an external file but does
internally?


Aaron Wolski wrote:
 Ok.. here are 3 links:
 
 https://celestica.tristarpromotions.com/NEW/index2.php
 
 This link... you'll see that the rollover effects on the top menu 
 work. The external JS file (called: jsstuffnew.php) has code that 
 looks like:
 
 img1on = new Image();   img1on.src = ?php echo $base_url;
 ?Graphics/home_on.gif;
 
 https://celestica.tristarpromotions.com/NEW/index.php
 
 This link... you'll see that the rollover effects on the top menu DO 
 NOT work. The external JS file (called: jsstuff.php) has code that 
 looks
 like:
 
 img1on = new Image();   img1on.src = ?php echo $base_url;
 ?Graphics/?php echo $img_home_on; ?;
 
 As you can see, the difference between the two is the fact that the 
 image FILE NAME is hard coded into the file as opposed to calling.
 
 
 https://celestica.tristarpromotions.com/NEW/index3.php
 
 This link... you'll see that the rollover effects work as well. 
 Instead of having an external file I have embedded the JS code 
 directly into the page.
 
 Additionally, I have use code that looks like:
 
 img1on = new Image();   img1on.src = ?php echo $base_url;
 ?Graphics/?php echo $img_home_on; ?;
 
 
 Having visuals... does that help communicate what the problem is?

Yes, the output of your JavaScript in the second example is missing 
$img_home_on (it's outputting nothing).  Where does this variable get 
set?  How about posting the php code for 
https://celestica.tristarpromotions.com/NEW/jsstuff.php


-- 
By-Tor.com
It's all about the Rush
http://www.by-tor.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread Aaron Wolski
Hi guys,

I have this code Javascript code:

if (document.images) {

img1on = new Image();   img1on.src = ?php echo $base_url;
?Graphics/?php echo $img_home_on; ?; 
img2on = new Image();   img2on.src = ?php echo $base_url;
?Graphics/?php echo $img_programdetails_on; ?;  
img3on = new Image();   img3on.src = ?php echo $base_url;
?Graphics/?php echo $img_products_on; ?;
img4on = new Image();   img4on.src = ?php echo $base_url;
?Graphics/?php echo $img_featuredproducts_on; ?; 
img5on = new Image();   img5on.src = ?php echo $base_url;
?Graphics/?php echo $img_faq_on; ?;  
img6on = new Image();   img6on.src = ?php echo $base_url;
?Graphics/?php echo $img_contact_on; ?;


img1off = new Image();   img1off.src = ?php echo $base_url;
?Graphics/?php echo $img_home_off; ?; 
img2off = new Image();   img2off.src = ?php echo $base_url;
?Graphics/?php echo $img_programdetails_off; ?;  
img3off = new Image();   img3off.src = ?php echo $base_url;
?Graphics/?php echo $img_products_off; ?;
img4off = new Image();   img4off.src = ?php echo $base_url;
?Graphics/?php echo $img_featuredproducts_off; ?; 
img5off = new Image();   img5off.src = ?php echo $base_url;
?Graphics/?php echo $img_faq_off; ?;  
img6off = new Image();   img6off.src = ?php echo
{$base_url}Graphics/{$img_contact_off}; ?;

}

When I include it in the main page it works without any problems. When I
link it as an external file it doesn't work.

As a side note, the following code example works in an external JS file:

img1off = new Image();   img1off.src = ?php echo $base_url;
?Graphics/home_off.gif; 

Anyone know why the external file with two variables is not working but
it does work with one variable?

Thanks! I appreciate the help!

Regards,

Aaron

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread John Nichel
Aaron Wolski wrote:
Hi guys,
I have this code Javascript code:
snip
When I include it in the main page it works without any problems. When I
link it as an external file it doesn't work.
As a side note, the following code example works in an external JS file:
img1off = new Image();   img1off.src = ?php echo $base_url;
?Graphics/home_off.gif; 

Anyone know why the external file with two variables is not working but
it does work with one variable?
What is doesn't work?  Does it not output the second variable?  Does 
it output php code?

--
John C. Nichel
ÜberGeek
KegWorks.com
716.856.9675
[EMAIL PROTECTED]
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


RE: [PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread Jay Blanchard
[snip]
I have this code Javascript code:
[/snip]

And the web has these JavaScript lists! Quaint, no?

Anyhow, to make this work you will need to generate your JavaScript code
with PHP. 

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread Aaron Wolski


 -Original Message-
 From: Jay Blanchard [mailto:[EMAIL PROTECTED]
 Sent: October 5, 2004 3:52 PM
 To: [EMAIL PROTECTED]
 Subject: RE: [PHP] why this doesn't work as an external file but does
 internally?
 
[snip] 
 And the web has these JavaScript lists! Quaint, no?
[/snip]

If you look closely, it's tied in with PHP. But thanks your help!

[snip]
 Anyhow, to make this work you will need to generate your JavaScript
code
 with PHP.
[/snip]

If that was true then why does this work:

img1off = new Image();   img1off.src = ?php echo $base_url;
?Graphics/home_off.gif;

I certainly didn't generate it with PHP and it was included as an
external file.

Thanks!

A

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread Jay Blanchard
[snip]
If that was true then why does this work:

img1off = new Image();   img1off.src = ?php echo $base_url;
?Graphics/home_off.gif;

I certainly didn't generate it with PHP and it was included as an
external file.
[/snip]

If this is true then your problem is solved. if not

echo img1off = new Image();   img1off.src = . $base_url .
Graphics/home_off.gif;

I think I have the syntax correct

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread John Nichel
Please reply to the list, and not just an individual person.
Aaron Wolski wrote:
-Original Message-
From: John Nichel [mailto:[EMAIL PROTECTED]
Sent: October 5, 2004 3:51 PM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] why this doesn't work as an external file but does
internally?
 

What is doesn't work?  Does it not output the second variable?  Does
it output php code?

When I say it doesn't work, the images don't appear. It's a simply
mouseover effect: image on and image off type of thing.
When the page loads... the main image (the off image) is visible but
when I move the mouse over an image it just shows blank (an X).
Does that make it more clear? Sorry.
No.  I turn my radio on, but it doesn't work, what's the problem?  See 
what I mean?  The question doesn't supply enough information to make an 
educated guess as to what the problem may be.

What error messages are produced?
What does the remotely included file output?
Does the second variable have value?
Can you provide a link to where we can see the issue at play?
So on, and so forth.
Look at the source of your page that doesn't work, where the JS is 
supposed to be, and chances are, you'll see the problem.

--
John C. Nichel
ÜberGeek
KegWorks.com
716.856.9675
[EMAIL PROTECTED]
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread Matthew Sims
 Hi guys,

 I have this code Javascript code:

   if (document.images) {

 img1on = new Image();   img1on.src = ?php echo $base_url;
 ?Graphics/?php echo $img_home_on; ?;
 img2on = new Image();   img2on.src = ?php echo $base_url;
 ?Graphics/?php echo $img_programdetails_on; ?;

snip


 Regards,

 Aaron


When you mix PHP and javascript together in an external file, the file
needs to be PHP and you should include it with PHP. I just recently went
through this. I had an external javascript file with some PHP in it. It
was originally called into the index.php page as:

script type=text/javascript src=includes/links.js

But none of the PHP in the links.js worked.

So I renamed the file to links.php and called it in index.php like so:

?php include 'includes/links.php'; ?

And everything worked perfectly.

-- 
--Matthew Sims
--http://killermookie.org

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] why this doesn't work as an external file but does inte rnally?

2004-10-05 Thread Vail, Warren
Right on, a .js file is probably not processed by the PHP engine, but while
it's imbedded in a .php file, it is.  Apples and Oranges, no?

Warren Vail


-Original Message-
From: Aaron Wolski [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, October 05, 2004 1:01 PM
To: 'Jay Blanchard'; [EMAIL PROTECTED]
Subject: RE: [PHP] why this doesn't work as an external file but does
internally?




 -Original Message-
 From: Jay Blanchard [mailto:[EMAIL PROTECTED]
 Sent: October 5, 2004 3:52 PM
 To: [EMAIL PROTECTED]
 Subject: RE: [PHP] why this doesn't work as an external file but does 
 internally?
 
[snip] 
 And the web has these JavaScript lists! Quaint, no?
[/snip]

If you look closely, it's tied in with PHP. But thanks your help!

[snip]
 Anyhow, to make this work you will need to generate your JavaScript
code
 with PHP.
[/snip]

If that was true then why does this work:

img1off = new Image();   img1off.src = ?php echo $base_url;
?Graphics/home_off.gif;

I certainly didn't generate it with PHP and it was included as an external
file.

Thanks!

A

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread Aaron Wolski
File with the JS code is called: jsstuff.php

Aaron

 -Original Message-
 From: Vail, Warren [mailto:[EMAIL PROTECTED]
 Sent: October 5, 2004 4:12 PM
 To: 'Aaron Wolski'; 'Jay Blanchard'; [EMAIL PROTECTED]
 Subject: RE: [PHP] why this doesn't work as an external file but does
 internally?
 
 Right on, a .js file is probably not processed by the PHP engine, but
 while
 it's imbedded in a .php file, it is.  Apples and Oranges, no?
 
 Warren Vail
 
 
 -Original Message-
 From: Aaron Wolski [mailto:[EMAIL PROTECTED]
 Sent: Tuesday, October 05, 2004 1:01 PM
 To: 'Jay Blanchard'; [EMAIL PROTECTED]
 Subject: RE: [PHP] why this doesn't work as an external file but does
 internally?
 
 
 
 
  -Original Message-
  From: Jay Blanchard [mailto:[EMAIL PROTECTED]
  Sent: October 5, 2004 3:52 PM
  To: [EMAIL PROTECTED]
  Subject: RE: [PHP] why this doesn't work as an external file but
does
  internally?
 
 [snip]
  And the web has these JavaScript lists! Quaint, no?
 [/snip]
 
 If you look closely, it's tied in with PHP. But thanks your help!
 
 [snip]
  Anyhow, to make this work you will need to generate your JavaScript
 code
  with PHP.
 [/snip]
 
 If that was true then why does this work:
 
 img1off = new Image();   img1off.src = ?php echo $base_url;
 ?Graphics/home_off.gif;
 
 I certainly didn't generate it with PHP and it was included as an
external
 file.
 
 Thanks!
 
 A
 
 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread Aaron Wolski


 -Original Message-
 From: John Nichel [mailto:[EMAIL PROTECTED]
 Sent: October 5, 2004 4:06 PM
 To: PHP Mailing Lists
 Subject: Re: [PHP] why this doesn't work as an external file but does
 internally?
 
 Please reply to the list, and not just an individual person.
 
 No.  I turn my radio on, but it doesn't work, what's the problem?  See
 what I mean?  The question doesn't supply enough information to make
an
 educated guess as to what the problem may be.
 
 What error messages are produced?
 What does the remotely included file output?
 Does the second variable have value?
 Can you provide a link to where we can see the issue at play?
 So on, and so forth.
 
 Look at the source of your page that doesn't work, where the JS is
 supposed to be, and chances are, you'll see the problem.

Ok.. here are 3 links:

https://celestica.tristarpromotions.com/NEW/index2.php

This link... you'll see that the rollover effects on the top menu work.
The external JS file (called: jsstuffnew.php) has code that looks like:

img1on = new Image();   img1on.src = ?php echo $base_url;
?Graphics/home_on.gif;

https://celestica.tristarpromotions.com/NEW/index.php

This link... you'll see that the rollover effects on the top menu DO NOT
work. The external JS file (called: jsstuff.php) has code that looks
like:

img1on = new Image();   img1on.src = ?php echo $base_url;
?Graphics/?php echo $img_home_on; ?;

As you can see, the difference between the two is the fact that the
image FILE NAME is hard coded into the file as opposed to calling.


https://celestica.tristarpromotions.com/NEW/index3.php

This link... you'll see that the rollover effects work as well. Instead
of having an external file I have embedded the JS code directly into the
page.

Additionally, I have use code that looks like:

img1on = new Image();   img1on.src = ?php echo $base_url;
?Graphics/?php echo $img_home_on; ?;


Having visuals... does that help communicate what the problem is?

In terms of what errors I am seeing, etc... I cannot tell you that
because NO errors come up at all, even with the external pages.

Thanks John. Hope I explained it a bit better this time around.

Regards,

Aaron

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread Curt Zirzow
* Thus wrote Aaron Wolski:
 
 
  
  What error messages are produced?
  What does the remotely included file output?
  Does the second variable have value?
  Can you provide a link to where we can see the issue at play?
  So on, and so forth.
  
  Look at the source of your page that doesn't work, where the JS is
  supposed to be, and chances are, you'll see the problem.
 
 Ok.. here are 3 links:
 
 https://celestica.tristarpromotions.com/NEW/index2.php
 
 This link... you'll see that the rollover effects on the top menu work.
 The external JS file (called: jsstuffnew.php) has code that looks like:
 
 img1on = new Image();   img1on.src = ?php echo $base_url;
 ?Graphics/home_on.gif;
 
 https://celestica.tristarpromotions.com/NEW/index.php
 
 This link... you'll see that the rollover effects on the top menu DO NOT
 work. The external JS file (called: jsstuff.php) has code that looks
 like:
 
 img1on = new Image();   img1on.src = ?php echo $base_url;
 ?Graphics/?php echo $img_home_on; ?;

$base_url and $img_home_on have no value in jsstuff.php thus you
have a javascript that results in:

   img1on.src = Graphics/

Also, you should also send a javascript header with the jsstuff.php
file:
  header('Content-Type: application/x-javascript');

Curt
-- 
The above comments may offend you. flame at will.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] why this doesn't work as an external file but does internally?

2004-10-05 Thread John Nichel
Aaron Wolski wrote:
Ok.. here are 3 links:
https://celestica.tristarpromotions.com/NEW/index2.php
This link... you'll see that the rollover effects on the top menu work.
The external JS file (called: jsstuffnew.php) has code that looks like:
img1on = new Image();   img1on.src = ?php echo $base_url;
?Graphics/home_on.gif;
https://celestica.tristarpromotions.com/NEW/index.php
This link... you'll see that the rollover effects on the top menu DO NOT
work. The external JS file (called: jsstuff.php) has code that looks
like:
img1on = new Image();   img1on.src = ?php echo $base_url;
?Graphics/?php echo $img_home_on; ?;
As you can see, the difference between the two is the fact that the
image FILE NAME is hard coded into the file as opposed to calling.
https://celestica.tristarpromotions.com/NEW/index3.php
This link... you'll see that the rollover effects work as well. Instead
of having an external file I have embedded the JS code directly into the
page.
Additionally, I have use code that looks like:
img1on = new Image();   img1on.src = ?php echo $base_url;
?Graphics/?php echo $img_home_on; ?;
Having visuals... does that help communicate what the problem is?
Yes, the output of your JavaScript in the second example is missing 
$img_home_on (it's outputting nothing).  Where does this variable get 
set?  How about posting the php code for 
https://celestica.tristarpromotions.com/NEW/jsstuff.php

--
By-Tor.com
It's all about the Rush
http://www.by-tor.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-23 Thread Tim Thorburn
Just to add a little fuel to the fire, the only way I've seen or been able 
to get PHP and Apache 2 working together is by installing each from my Red 
Hat 8.0 CD's.  When I tried to compile each together, I got many an error.

When I start doing some actually web work on my testing server, I imagine 
I'll uninstall Apache 2, and go with some version of 1.3



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-23 Thread Richard Baskett
Ok I am hearing a bad rumor that Red Hat 8.0 and the Mac xserve both come
with Apache 2.. now is this a rumor or is this true?

If it's true.. why?  And does anybody have any experience in uninstalling
Apache 2 on the xserve and does it break anything?

Cheers!

Rick

Don't walk in front of me, I may not follow, Don't walk behind me, I may not
lead, Just walk beside me, and be my friend. - Unknown

 From: Tim Thorburn [EMAIL PROTECTED]
 Date: Thu, 23 Jan 2003 05:03:00 -0500
 To: [EMAIL PROTECTED]
 Subject: Re: [PHP] Why PHP doesn't work with Apache2?
 
 Just to add a little fuel to the fire, the only way I've seen or been able
 to get PHP and Apache 2 working together is by installing each from my Red
 Hat 8.0 CD's.  When I tried to compile each together, I got many an error.
 
 When I start doing some actually web work on my testing server, I imagine
 I'll uninstall Apache 2, and go with some version of 1.3
 
 
 
 -- 
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 
 
 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-23 Thread Joseph W. Goff
Well, I don't know about trying to uninstall it, but RH8.0 does come with
Apache 2
It works fine and I have not ran into a reason why I should use the older
version for this.
Granted I only use it for testing, my live server is RH7.2 which uses Apache
1
- Original Message -
From: Richard Baskett [EMAIL PROTECTED]
To: PHP General [EMAIL PROTECTED]
Sent: Thursday, January 23, 2003 2:28 PM
Subject: Re: [PHP] Why PHP doesn't work with Apache2?


 Ok I am hearing a bad rumor that Red Hat 8.0 and the Mac xserve both come
 with Apache 2.. now is this a rumor or is this true?

 If it's true.. why?  And does anybody have any experience in uninstalling
 Apache 2 on the xserve and does it break anything?

 Cheers!

 Rick

 Don't walk in front of me, I may not follow, Don't walk behind me, I may
not
 lead, Just walk beside me, and be my friend. - Unknown

  From: Tim Thorburn [EMAIL PROTECTED]
  Date: Thu, 23 Jan 2003 05:03:00 -0500
  To: [EMAIL PROTECTED]
  Subject: Re: [PHP] Why PHP doesn't work with Apache2?
 
  Just to add a little fuel to the fire, the only way I've seen or been
able
  to get PHP and Apache 2 working together is by installing each from my
Red
  Hat 8.0 CD's.  When I tried to compile each together, I got many an
error.
 
  When I start doing some actually web work on my testing server, I
imagine
  I'll uninstall Apache 2, and go with some version of 1.3
 
 
 
  --
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit: http://www.php.net/unsub.php
 
 
 


 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-23 Thread Evan Nemerson
Albert Camus. Your sig has a quote attributed to unknown. It was Albert 
Camus.

Don't walk in front of me, I may not follow, Don't walk behind me, I may not 
lead, Just walk beside me, and be my friend. -Albert Camus



On Thursday 23 January 2003 12:28 pm, Richard Baskett wrote:
 Ok I am hearing a bad rumor that Red Hat 8.0 and the Mac xserve both come
 with Apache 2.. now is this a rumor or is this true?

 If it's true.. why?  And does anybody have any experience in uninstalling
 Apache 2 on the xserve and does it break anything?

 Cheers!

 Rick

 Don't walk in front of me, I may not follow, Don't walk behind me, I may
 not lead, Just walk beside me, and be my friend. - Unknown

  From: Tim Thorburn [EMAIL PROTECTED]
  Date: Thu, 23 Jan 2003 05:03:00 -0500
  To: [EMAIL PROTECTED]
  Subject: Re: [PHP] Why PHP doesn't work with Apache2?
 
  Just to add a little fuel to the fire, the only way I've seen or been
  able to get PHP and Apache 2 working together is by installing each from
  my Red Hat 8.0 CD's.  When I tried to compile each together, I got many
  an error.
 
  When I start doing some actually web work on my testing server, I imagine
  I'll uninstall Apache 2, and go with some version of 1.3
 
 
 
  --
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit: http://www.php.net/unsub.php


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-23 Thread Richard Ellerbrock
On Thu, 23 Jan 2003 12:28:21 -0800, Richard Baskett wrote:

 Ok I am hearing a bad rumor that Red Hat 8.0 and the Mac xserve both come
 with Apache 2.. now is this a rumor or is this true?
 
 If it's true.. why?  And does anybody have any experience in uninstalling
 Apache 2 on the xserve and does it break anything?
 
 Cheers!
 
 Rick
 
 Don't walk in front of me, I may not follow, Don't walk behind me, I may not
 lead, Just walk beside me, and be my friend. - Unknown
 
 From: Tim Thorburn [EMAIL PROTECTED]
 Date: Thu, 23 Jan 2003 05:03:00 -0500
 To: [EMAIL PROTECTED]
 Subject: Re: [PHP] Why PHP doesn't work with Apache2?
 
 Just to add a little fuel to the fire, the only way I've seen or been able
 to get PHP and Apache 2 working together is by installing each from my Red
 Hat 8.0 CD's.  When I tried to compile each together, I got many an error.
 
 When I start doing some actually web work on my testing server, I imagine
 I'll uninstall Apache 2, and go with some version of 1.3

I also uninstalled apache 2 from Redhat 8.0. Just go and grab the latest
apache 1.3 source rpm from 7.3, rebuild the rpm and install that. Works
like a charm. I could also never get php to build against Apache2 on
Redhat 8.0.

http://iptrack.sourceforge.net


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Jean-Christian Imbeault
I don't want to start a flame-war here, just asking for specifics on a 
question I have :)

I know that PHP and Apache 2 (on Linux anyway) have some problems 
working together. I was just wondering, for my own education, why is that?

Is it a problem in Apache 2 or in PHP? (Not that I want to lay blame, 
just wondering).

Can someone point me to some ressource explaining the main points of why 
PHP won't work with Apache 2 just yet?

Thanks.

Jc


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Henry
Apache2 now work with php in aspx (PHP is as a module)

-Original Message-
From: Jean-Christian Imbeault [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, January 22, 2003 6:06 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Why PHP doesn't work with Apache2?


I don't want to start a flame-war here, just asking for specifics on a 
question I have :)

I know that PHP and Apache 2 (on Linux anyway) have some problems 
working together. I was just wondering, for my own education, why is that?

Is it a problem in Apache 2 or in PHP? (Not that I want to lay blame, 
just wondering).

Can someone point me to some ressource explaining the main points of why 
PHP won't work with Apache 2 just yet?

Thanks.

Jc


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Jean-Christian Imbeault
Henry wrote:

Apache2 now work with php in aspx (PHP is as a module)


Really!? I was sure there were still some issues ...

Jc


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Henry
what issues for example?
I do know I can successful install php in module with apache2.0.43 without error 
messages, also execution was successful
can you tell me what issues did you see?

-Original Message-
From: Jean-Christian Imbeault [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, January 22, 2003 7:11 PM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] Why PHP doesn't work with Apache2?


Henry wrote:
 Apache2 now work with php in aspx (PHP is as a module)

Really!? I was sure there were still some issues ...

Jc


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Jean-Christian Imbeault
Henry wrote:

what issues for example?
I do know I can successful install php in module with apache2.0.43 without error messages, also execution was successful
can you tell me what issues did you see?


A successful install means nothing.

My question is basically, does Apache2 work with PHP 100% or is it still 
recommend to use Apache 1.3.27?

If it is still not recommended to use Apache2, why?

If you think Apache2 and PHP work perfectly well together can you point 
me to some info that says so? I can't see anywhere on the PHP web site 
that recommends using Apache2.

Jc


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread yasin inat
it  depends  on  you   your aim  

u  can  consider  your criterias  between  php with apache 1.3X   apache 2

if  u  try  to  use  pragmatism  about  it ...

maybe  u  can  find  the  result  that  php with apache 2  is  better ?
so  don't you need  more argument ?

 one more  .
now  i'm  pleasure  of  apache2's  performancesecurity  on  win32
platform   ( should i use 'even' ?  : )...  )



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Jean-Christian Imbeault
Yasin Inat wrote:


it  depends  on  you   your aim  


Ok, to put it more simply,

Are there cases where something would work in Apache 1.3.27 + PHP that 
would break in Apache2 + PHP??

A simple yes or no will suffice.

If the answer is no, I am curious as to why not ...

Thanks,

Jc


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Rasmus Lerdorf
 Henry wrote:
  what issues for example?
  I do know I can successful install php in module with apache2.0.43 without error 
messages, also execution was successful
  can you tell me what issues did you see?
 
 A successful install means nothing.
 
 My question is basically, does Apache2 work with PHP 100% or is it still 
 recommend to use Apache 1.3.27?
 
 If it is still not recommended to use Apache2, why?

Because the server doesn't work very well yet.  There are issues in the 
filter api and you can't really uses a threaded mpm as many of the 
3rd-party libraries that are commonly linked into PHP are simply not 
threadsafe.  The first issue can be fixed, the second issue is handled by 
only running Apache2 in prefork mode which makes the server look like 
Apache1.  If you have to run Apache2 looking like Apache1 the benefits are 
minor, so the motivation for people to put a whole lot of effort into 
fixing issue #1 is minimal.

-Rasmus


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Jean-Christian Imbeault
Rasmus Lerdorf wrote:


Because the server doesn't work very well yet.  There are issues in the 
filter api and you can't really uses a threaded mpm as many of the 
3rd-party libraries that are commonly linked into PHP are simply not 
threadsafe.

Thank you! That's the kind of answer I was looking for.

If I understand correctly PHP will not work correctly because some parts 
of it are not thread-safe.

Is the PHP team working on getting PHP to be thread-safe? Does it look 
promising? Might version 5 be thread-safe?

Thanks again,

Jc


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Rasmus Lerdorf
On Thu, 23 Jan 2003, Jean-Christian Imbeault wrote:

 Rasmus Lerdorf wrote:
 
  Because the server doesn't work very well yet.  There are issues in the
  filter api and you can't really uses a threaded mpm as many of the
  3rd-party libraries that are commonly linked into PHP are simply not
  threadsafe.

 Thank you! That's the kind of answer I was looking for.

 If I understand correctly PHP will not work correctly because some parts
 of it are not thread-safe.

No, you didn't understand correctly.  I specifically said the thread
safety issues were in 3rd party libraries and not in PHP.  This is not
going to be solved anytime soon since it isn't really something we can
fix.  We can hack around it and add mutexes and stuff to protect ourselves
from broken libraries, but in the end that just brings us closer to the
non-threaded model that we already have with Apache-1.3, so there is very
little motivation to even go through this bit of pain.

Why exactly are you asking?  Is there some feature in Apache2 that you
need that is not available in Apache-1.3?

-Rasmus

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Jean-Christian Imbeault
Rasmus Lerdorf wrote:


No, you didn't understand correctly.  I specifically said the thread
safety issues were in 3rd party libraries and not in PHP.


Sorry, I thought by 3rd party libraries you meant libraries that PHP is 
dependent upon. Do you mean libraries used by PHP or Apache. And if 
these are libraries used by PHP, do you mean library that as in the 
multi-byte library (i.e. libraries that add functionality to PHP), or do 
you mean C libraries used when compiling PHP.

Why exactly are you asking?  Is there some feature in Apache2 that you
need that is not available in Apache-1.3?


I don't want to move from Apache 1-3 to Apache. I just keep hearing that 
PHP is not ready for Apache2 yet and I wanted to educate myself as to 
why. I don't like just being told something and not understanding the 
reason behind the answer.

So this boils down to Apache2 using threads and PHP not being thread-safe?

And the reason that PHP is not thread-safe is that some 3rd party 
libraries PHP used are not thread-safe.

Now the only two questions I have left are : #1 what those libraries are 
used for. I.e. are they part of PHP or libraries that are used to 
compile PHP?

If they are libraries used to compile PHP, I would assume that Apache2 
must have faced similar issues when going from a forking model to a 
threaded model?

#2 Is there progress being made towards having PHP work with Apache2. 
And who is working on this (if not the PHP team).

Thanks again for the clarifications!

Jc


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Why PHP doesn't work with Apache2?

2003-01-22 Thread Rasmus Lerdorf
On Thu, 23 Jan 2003, Jean-Christian Imbeault wrote:

 Rasmus Lerdorf wrote:
 
  No, you didn't understand correctly.  I specifically said the thread
  safety issues were in 3rd party libraries and not in PHP.

 Sorry, I thought by 3rd party libraries you meant libraries that PHP is
 dependent upon. Do you mean libraries used by PHP or Apache. And if
 these are libraries used by PHP, do you mean library that as in the
 multi-byte library (i.e. libraries that add functionality to PHP), or do
 you mean C libraries used when compiling PHP.

Common libraries such as gdbm or c-client, for example.

 So this boils down to Apache2 using threads and PHP not being thread-safe?

No

 And the reason that PHP is not thread-safe is that some 3rd party
 libraries PHP used are not thread-safe.

No

 If they are libraries used to compile PHP, I would assume that Apache2
 must have faced similar issues when going from a forking model to a
 threaded model?

Why?  Apache by itself doesn't need to talk to anywhere near the same
number of 3rd-party things that PHP commonly talks to.

 #2 Is there progress being made towards having PHP work with Apache2.
 And who is working on this (if not the PHP team).

Nobody really is.  And I don't see this changing until there are some
really compelling features in Apache2 to warrant the massive effort it
would take.  And yes, a working perchild mpm may be that compelling
feature, but we don't have one of those.

All of this stuff is available by reading the PHP and Apache dev lists, by
the way.  They are archived and not that hard to find.

-Rasmus

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Why it doesn't work?

2003-01-07 Thread KidA

Hi to all,
I found this error in my code:


   class BaseForm {

  var $_fields;
  var $_method;
  var $_postedData;
  var $_formAction;

  
  

  function init($eMsgFile,$method,$formAction) {
   
...
...

 $this-_method=strtoupper($method);

- Why next line gives me the error variable _POST is undefined ??? --
 $this-_postedData=${_.$this-_method};

 
$this-_formAction=(empty($formAction))?basename($_SERVER['PHP_SELF']):$formAction;

  }

Is it normal

Thank you a lot!

KidA


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Why while doesn't work?

2002-01-24 Thread Anthony Rodriguez

Although the table con_inf in db sbwresearch contains 3 records with 
username as the first column,  the following short script generates a blank 
page:

?php
$connection=mysql_connect(localhost,wagner,xyz) or die (No 
connection!);
$db=mysql_select_db(sbwresearch,$connection) or die (No database!);
$qry_1=select * from con_inf;
$result_1=mysql_query($qry_1,$connection) or die (No query # 1!);
while ($row_1=mysql_fetch_array($result_1,mysql_assoc))
{
   $username=$row_1[username];
   echo $username;
};
mysql_free_result($result_1);
mysql_close($connection);
exit;
?

Why?  I've use the statement in other scripts and it works!

Thanks!


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Why while doesn't work?

2002-01-24 Thread Matt Schroebel

If you only want the associative array, just use mysql_fetch_array($result).  If 
you're using the constant MYSQL_ASSOC, uppercase it, and don't quote it.

Although the table con_inf in db sbwresearch contains 3 records with 
username as the first column,  the following short script generates a blank 
page:

mysql_fetch_array($result_1,mysql_assoc))

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]