Re: [PHP] Include + $Variables Help

2002-06-08 Thread Olexandr Vynnychenko

Hello Steven,

Saturday, June 08, 2002, 5:40:40 PM, you wrote:

S> Here's my problem:

S> I'm trying to make a simple publication of 30+ articles, using PHP but not
S> MySQL.

S> There are basically three components:
S>  - a table of contents (contents.html)
S>  - an article template (article.php)
S>  - and then 30+ text files.

S> The idea I was going for was to make dynamic links in contents.html that
S> would pass a variable to article.php. The article page then uses that
S> variable in an include( ). Does this make sense? I.e.-

S> ## contents.html
S> Text Link

S> ## article.php
S> # The link above would then pass the $auth variable as 'name', right?
S> # Is that enough?
S> 
S> # I then assume this would result in it trying to include 'name.txt',
S> # but instead there is always a nasty error about the .txt part.
S> # I should probably ask, is passing variables inside an include allowed?

S> If I'm wrong, or I'm just missing something that needs to be added, please
S> let me know. I'm sooo new at this that I know I'm doing something wrong and
S> it is probably very simple. Any help would be greatly appreciated!

What a nasty error? And did you try the following

 ?

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]


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




Re[2]: [PHP] please help!!

2002-05-26 Thread Olexandr Vynnychenko

Hello Jolly,

Sunday, May 26, 2002, 10:58:45 AM, you wrote:

JN> Olexandr,

JN>  /* I can get the values from these */
JN>  foreach ($HTTP_POST_VARS as $var => $value) {
JN> echo "$var = $value\n";
JN> }
JN> /**/

JN> /*however empty for this sentence*/
JN>  echo "equals ".($t1+$t2);
JN> /**/

JN>  echo "\n";
JN>  echo "\n";
JN>  echo "\n";
JN> echo "\n";
JN> echo "\n";
?>>

JN> P.S. I have set "register_globals = On", but still not work
JN> The attached files are my config files of php and apache!

I looked through your configuration files and didn't notice any
serious differences between them and my ones. I have PHP 4.2.1/Apache
2.0.36 on WinXP Pro. My register_globals was off. When I made it On
your scipt worked properly. I don't know what the reason. What PHP you
have?

I attached my php.ini. Maybe you can find some important things.
Another one question: does $PHP_SELF give proper value? It must not be
set if register_globals=off. So if $PHP_SELF is set to some value,
then global variables are registered.

And the last question: why do you use global variables? It's much
easier to use superglobal arrays $_POST, $_SERVER, etc. They guarantee
that any values passed to your script won't be mixed.

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]


php.ini.zip
Description: Zip compressed data

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


Re: [PHP] please help!!

2002-05-25 Thread Olexandr Vynnychenko

Hello Jolly,

Saturday, May 25, 2002, 9:13:02 AM, you wrote:

JN> Hi Hi,

JN> php + apache + win2000
JN> or 
JN> php + IIS + win2000
JN> I don't know why my setting do not allow me to POST or GET variable which submit 
in html 
JN> Please help!!!

JN> Jolly

Let us read your html and php code. I've never had such problems.

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]


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




Re[4]: [PHP] Refresh doesn't work

2002-05-20 Thread Olexandr Vynnychenko

Hello Johan,

Tuesday, May 21, 2002, 2:13:07 AM, you wrote:

JE> I'am admining both a IIS5.1 server and a Apache 2.0.35 server, under WinXP.
JE> (say's it all, chaos!)
JE> And I've never got the header to work, but location, does the trick,
JE> sometimes... I don't know how it works

Sometimes? Do you mean Location sometimes doesn't work?

JE> with XML though... let me know if you figure it out...
JE> Good Luck!


-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]


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




Re[2]: [PHP] Refresh doesn't work

2002-05-20 Thread Olexandr Vynnychenko

Hello Thalis,

Monday, May 20, 2002, 10:51:57 PM, you wrote:

TAK> Have you tried creating HTML with the equivalent META header?

TAK> 
TAK> 
TAK> 

TAK> Does it work for you?

TAK> cheers,
TAK> thalis

TAK> On Mon, 20 May 2002, Olexandr Vynnychenko wrote:

>> Hello php-general,
>> 
>>   Has anyone else here the same proplem as I have? I write in my php:
>> 
>> header("Refresh: 3; url=newpage.php");
>> 
>> Netscape 4.79 works fine and goes to page.php after 3 seconds pass.
>> But IE 6 doesn't want to do that. Can anyone explain such a wonderful
>> behavior?

Of course, it works. But I wanted to do it by HTTP headers because I
generate HTML from XML thru XSLT, so I don't want to dig in there.

I just wanted to know if it's usual for IE of any version, or it's
something wrong with my IE6 on WinXP.


-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]


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




[PHP] Refresh doesn't work

2002-05-20 Thread Olexandr Vynnychenko

Hello php-general,

  Has anyone else here the same proplem as I have? I write in my php:

header("Refresh: 3; url=newpage.php");

Netscape 4.79 works fine and goes to page.php after 3 seconds pass.
But IE 6 doesn't want to do that. Can anyone explain such a wonderful
behavior?

-- 
Best regards,
 Olexandr  mailto:[EMAIL PROTECTED]


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




Re: [PHP] Free Hosting /w PHP/MySQL {!?}

2002-05-18 Thread Olexandr Vynnychenko

Hello Liam,

Monday, May 06, 2002, 6:00:07 AM, you wrote:

LM> Free hosting for PHP Developers.

LM> As many MySQL Databases as you need
LM> PHP with all the bits http://scripts.operationenigma.net/phpinfo.php
LM> FTP Access
LM> Subdomain or Your own Domain
LM> Tech Support over MSN if needed
LM> 98% Uptime
LM> 512/512 Connection based in Brisbane, Australia


LM> Only catch is that I can't have downloads on my servers.  
LM> I have a 3 Gig Monthty transfer limit, so no MP3s or 
LM> thereabouts please.

LM> Contact me if you're interested.

I have a problem. I have to place my site (my term work) on some host.
I thought I had it, but I was wrong. They have PHP 4.1.2 without xslt
and domxml extensions. But my site won't work without xslt bacause all
inner data is stored in XML. They said it could take at least a week
to include these modules. But I can't wait for a week. Can you help
me? I saw you have PHP 4.2.1, but there is no xslt and domxml. Is it
possible to include them in some way? I would appreciate deeply, if
you could solve this stupid problem. Thanks in advance.

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]


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




[PHP] php-4.2.1-Win32.zip has been changed

2002-05-15 Thread Olexandr Vynnychenko

  I noticed that php-4.2.1-Win32.zip on www.php.net has been changed
  since I began downloading. So I downloaded it again. But what for?
  And why wasn't we all notified about that? If I completed
  downloading a little bit earlier I had a different release. I think
  people must be notified about such things.

-- 
Best regards,
 Olexandr  mailto:[EMAIL PROTECTED]


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




Re[2]: [PHP] PHP 4.2.1 release announcement

2002-05-15 Thread Olexandr Vynnychenko

Hello Steve,

Tuesday, May 14, 2002, 6:28:06 PM, you wrote:

SB> Sorry, I forgot to move my php4ts.dll to the windows/system32 directory.

SB> Steve
SB> ---snip---
SB> I know that I just saw something like this last week on the list, but can't 
SB> find it now.  Anyway, I have just installed PHP 4.2.1 on my WinXP laptop 
SB> running Apache 1.3.23.  phpinfo() is still showing 4.1.2.  I think I 
SB> remember something about a dll that needs to be deleted or something like 
SB> that.  Can anybody let me know how to fix this?
SB> ---snip---

The best way is not to move any .dll from php directory. Just add all
the directories containing needed dlls in the PATH environment
variable. And it will be ok with upgrading.

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]


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




Re: [PHP] setcookie()

2002-05-12 Thread Olexandr Vynnychenko

Hello jtjohnston,

Saturday, May 11, 2002, 11:42:52 PM, you wrote:

j> This is a bug "Feature/Change Request" I made to:
j> http://bugs.php.net/bug.php?id=17158

j> setcookie() states "cookies must be sent before any other headers
j> are sent (this is a restriction of cookies, not PHP).

j> I argue this is a restriction of PHP, not cookies.

j> Here is my proof:

j> http://www.collegeSherbrooke.qc.ca/languesmodernes/cookie.htm

j> I can do this any time in  :

j> 
j>setCookie("TestCookie","first time",expdate);
j>var DisplayData = getCookie("TestCookie");
j>document.write(DisplayData);
j>setCookie("TestCookie","second time",expdate);
j>var DisplayData = getCookie("TestCookie");
j>document.write(DisplayData);
j>  

j> I want to be able to setcookie() anytime I want, before and after I
j> declare any HTML.
j> This will never get changed, unless we ask for it.

j> I would appreciate your vote of support at:

j> http://bugs.php.net/bug.php?id=17158

j> before the bug people "close" this thread.

Are you kidding?



-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]


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




Re: [PHP] Newbie question to everybody....PHP

2002-05-11 Thread Olexandr Vynnychenko

Hello r,

Sunday, May 12, 2002, 4:25:37 AM, you wrote:

r> Greetings people,
r> Special greetings to all of you who have helped me in the past.

r> As most of you know i am a newbie, I learned a bit of PHP via webmonkey and
r> a few other places, seeing the power of PHP i decided to convert from Java
r> servlets and JSP (JSP coz its expensive to host and not many hosting
r> opportunities) so I baught a book called "The PHP black book".
r> Anyway, now that the background is done heres my questions:

r> 1)How many of you have seriously dug into arrays and has it been important
r> in your programming?
r> 1.1)Do you think you could have done the same thing you did with arrays
r> WITHOUT arrays?
r> (The reason i ask this is theres a whole chapter dedicated to arrays in the
r> book & its pretty frustrating)

Arrays in PHP are very useful and easy to use. I had no problem. And I
have no book about PHP :). I use manual, because it's the best book. I
looked through some books and find that the PHP manual is MUCH better.

r> Last question:
r> Is ther any function to make the program "sleep" for 10 seconds or so? or
r> does anybody have a function that does this?

It's called sleep() :)
Once again, use manual. Espacially if you work on Windows. Then just
download the manual in CHM.It includes index and search capabilities.

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]


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




[PHP] setcookie() in 4.2.0

2002-05-11 Thread Olexandr Vynnychenko

The following code doesn't work properly on PHP 4.1:

Blah, blah";
setcookie("kuku", "abc");
setcookie("lala", "def");
setcookie("zuzu", "ghi");
?>

Because I wrote echo statement before setcookie. But it works on PHP
4.2. Is it due to "output_buffering=4096" directive in php.ini?

-- 
Best regards,
 Olexandr  mailto:[EMAIL PROTECTED]


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




Re: [PHP] PHP builds

2002-05-10 Thread Olexandr Vynnychenko

Hello Liam,

Friday, May 10, 2002, 9:31:45 AM, you wrote:

LM> Hi all,

LM> I need some opinions, what are some good modules to build into PHP?
LM> I'm starting a hosting service (properly) 

Incule XSLT module. If I were your client I really needed it.


-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]


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




[PHP] What about XSLT in PHP 4.2?

2002-05-04 Thread Olexandr Vynnychenko

Some months ago I used Sablotron in PHP 4.0.6. What should I do now
with PHP 4.2.0? There is no Sablotron. php_xslt.dll is placed into
'experimental' directory. Manual says:

  This extension is different than the sablotron extension distributed
  with versions of PHP prior to PHP 4.1, currently only the new XSLT
  extension in PHP 4.1 is supported.

How should I use it and what is the difference between old and new
XSLT extensions?

Thanks in advance.

-- 
Best regards,
 Olexandr  mailto:[EMAIL PROTECTED]


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




Re: [PHP] HOT!!! PHP4.1.x - Step by Step Installation manual

2002-01-27 Thread Olexandr Vynnychenko

Hello Andre,

Friday, January 25, 2002, 3:16:38 AM, you wrote:

AA> Hi all. Here is my first attempt to make easy Step by Step installation
AA> manual for PHP4.1.x on Windows 2000 based systems running IIS5 using CGI or
AA> ISAPI. Here is the link that will ake a lot of people happy. :)
AA> http://www.experttek.com/php/installation.txt

AA> Fell free to contact me. Contacts are in the manual.

HTTP 404 - File not found

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]



-- 
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] PHP versus all other languages

2001-11-13 Thread Olexandr Vynnychenko

Hello Pat,

Tuesday, November 13, 2001, 4:10:31 AM, you wrote:

PH> I'm doing my senior exit project on database languages online. I'm asking
PH> for help from anyone who can provide any information on the comparison
PH> between the different languages. I'm comparing languages such as PHP, ASP,
PH> ColdFussion, perl and any others that I might not know about that you guys
PH> might know. Thank you to anyone who helps me out in the least.

Will we be able to see the result when it's ready?

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]



-- 
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[2]: [PHP] Help me to win the battle with browser's cache

2001-11-12 Thread Olexandr Vynnychenko

Hello Girish,

Monday, November 12, 2001, 4:29:55 PM, you wrote:

GN> Hi

GN> I've found some code which i put it into this function. I've never got the
GN> meta tag technique to work but this seems to do the trick.

GN> Call noCache() before outputting anything to the page.

GN> function noCache() {
GN> header ("Expires: Mon, 26 Jul 1997 05:00:00 GMT");// Date in the past
GN> header ("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); // always
GN> modified
GN> header ("Cache-Control: no-cache, must-revalidate");  file://HTTP/1.1
GN> header ("Pragma: no-cache");  // HTTP/1.0
GN> }

Thanks! That's what I've been looking for. But there is something
wrong with this headers. I pasted the code above, and peges really
stopped loading from cache. But... I tested it with IE 5.5 SP2 and
Netscape 4.77 (I don't use Netscape 6.x because it's just useless
cputime eater). The page works fine with Navigator, but IE shows blank
page each time I click a link. It shows the page properly only after
clicking Refresh. I remember I have the same problem 1/2 year ago when
I was unsuccesfully tried to win the battle with the browser cache :).
Now I commented the 3rd header (with "cache-control"), and now IE
works perfect too. I don't know why it works on your pages :). The
problem is not in my personal IE because the same problem was (as I
said) whan I used IE 5.0.
So, if there are some people who have the same problem, I would
suggest to put these 3 lines on the top of the page:

header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT");
header("Pragma: no-cache");

Thanks to Girish and others who tried to help me!

P.S. There can be another problem: client's clock. If it's 20 Jan 1985
on client's machine, than ... Do you think I can put in the first
header some very old date like 1 Jan 1970? I just want it to work in
any case.

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]



-- 
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] apache + ftp!

2001-11-12 Thread Olexandr Vynnychenko

Hello Benjamin,

Monday, November 12, 2001, 12:00:22 PM, you wrote:

B> hey group!

B> i have apache installed on an win2000 machine and now i need an good and
B> stable ftp server! which one does i take!

B> thank you, ben

And what about W2k's built-in FTP server? Has someone used it? Is it
so bad?

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]



-- 
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]




[PHP] Help me to win the battle with browser's cache

2001-11-12 Thread Olexandr Vynnychenko

Hello php-general,

  I have index.php, which has Log out.
  When I click it, I am logged out the site. But I type "index.php" in
  browser's address bar, press Enter and ... it shows "non-logouted"
  page. What should I write in php code to tell browser something like
  "forget about old page, don't display it, get the newest version"?
  Some time ago I tried to do that in several ways and nothing gived
  100% result. And other thing I saw was that Netscape and Explorer
  behave in different ways in such cases. Could someone help me? Maybe
  this topic was discussed before, but still... I appreciate greatly
  any suggestion.

-- 
 Olexandr Vynnychenko  mailto:[EMAIL PROTECTED]



-- 
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] Session handling with cookies??

2001-10-29 Thread Olexandr Vynnychenko

Hello Andy,

Monday, October 29, 2001, 3:39:51 PM, you wrote:

A> So... does anybody know how...

A> 1) I get the system to delete the cookie as soon as I leave the site, or
A> close it

Use logout with setcookie("name", 0, ...)

A> 2) How to work on the same time.

Pass information about date/time via GET or better POST variable(s).



-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]



-- 
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] Attaching a file to a form!

2001-10-28 Thread Olexandr Vynnychenko

Hello Ben,

Sunday, October 28, 2001, 10:04:21 PM, you wrote:

BC> I am trying to let a person attach a file to my form.  Can anyone help?


Just read http://www.php.net/manual/en/features.file-upload.php.
That's quite simple.

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]



-- 
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[2]: [PHP] free php web hosting

2001-10-26 Thread Olexandr Vynnychenko

Hello Frewuill,

Friday, October 26, 2001, 6:51:00 PM, you wrote:

FR> www.f2s.com sometimes it's a little slow but u have php+mysql

FR> - Original Message -
FR> From: "Kamran H. Hassan" <[EMAIL PROTECTED]>
FR> To: <[EMAIL PROTECTED]>
FR> Sent: Friday, October 26, 2001 11:20 AM
FR> Subject: [PHP] free php web hosting


FR> Hi,

FR> can any body know about free php & mysql free web hosting service provder
FR> ?

FR> i will be greatful if u let me know

FR> Kamran H. Hassan

That's what it told me:

Welcome to the Freedom2surf signup page!
Sorry - Our free webservers are currently full 

:(  What to do now?.. It was a good host.

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]



-- 
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[4]: [PHP] function names

2001-10-26 Thread Olexandr Vynnychenko


MM> Check your code again. Without the this-> I get the same error that you got. 
With this->> I don't.

I don't know what php you're using... Or maybe you haven't understood
something. Try this code:



And php will tell you "Parse error:  parse error, expecting `T_STRING'
in Newprint.php on line 4" because (as I guess) print() is not a
function, it's a language construction. So php simply doesn't let you
have function named like language constructions like "and", "or",
"array", "+", "$" and so on. In this case it would be similar as if
you wrote:



In all these cases php writes "Parse error: ..."

-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]



-- 
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[2]: [PHP] function names

2001-10-26 Thread Olexandr Vynnychenko

Hello Steve,

Thursday, October 25, 2001, 10:30:16 PM, you wrote:


SC> On Thursday, October 25, 2001, at 02:08  PM, Martín Marqués wrote:

>> On Jue 25 Oct 2001 15:36, you wrote:
>>> Hello php-general,
>>>
>>>   I have such code:
>>>
>>>   class A
>>>   {
>>> var $xxx;
>>>
>>> function print()
>>> {
>>>  echo $xxx;
>>
>> $xxx is internal to the print function. Instead you need $this->xxx 
>> which
>> will give you the value of the $xxx of the A class.
>>
>>> }
>>>   }
>>>
>>>   And that's what I get:
>>> "Parse error: parse error, expecting `T_STRING' in xxx.php on line 
>>> nn"
>>>
>>>   Php doesn't let any function or class member have a name which is
>>>   already "used" by another function (or only function from library),
>>>   am I right? Or maybe "print" has special status. Maybe that's
>>>   because print() is actually not a function? Can anyone tell me
>>>   something about that, please?
>>
>> Th print function of PHP has nothing to do with this, just because 
>> print is
>> internal to the A class, and has nothing with the PHPs internal print
>> function.

SC> Hmm. I think you're wrong here. I made this test script:
SC>  class test {
SC>  var $a;

SC>  function test() {
SC>  $this->a = "hello";
SC>  }

SC>  function print() { // this is line 10
SC>  echo $this->a;
SC>  }
SC> }

SC> $obj = new test;
$obj->>print();

?>>
SC> Which gives this:

SC> Parse error: parse error, expecting `T_STRING' in 
SC> /home/httpd/html/ucdamage/test.php on line 10

SC> If I change the name of the print() method it works okay.

SC> -Steve


I told you! :) I'm sure I was right when I said that was because
print() is not actually a function, it's a language constructuin...


-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]



-- 
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] Re: function names

2001-10-26 Thread Olexandr Vynnychenko

Hello Mike,

Thursday, October 25, 2001, 10:09:18 PM, you wrote:

MF> Actually your problem is with the function itself.  In order for it to work
MF> you need to use the "this" keyword:

MF> class A {
MF> var $xxx;

MF> function print() {
MF> echo $this->xxx;
MF> }
MF> }

MF> You may also run into problems with calling the function print(), I don't
MF> know for sure.  But the problem is that you were telling PHP to print a
MF> variable that was, technically, not even initialized.

MF> Mike Frazer

Yes, of course there was echo $this->xxx, but it doesn't matter, seek
deeper... Error occured on line where function print() is declared.


MF> "Olexandr Vynnychenko" <[EMAIL PROTECTED]> wrote in message
MF> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>> Hello php-general,
>>
>>   I have such code:
>>
>>   class A
>>   {
>> var $xxx;
>>
>> function print()
>> {
>>  echo $xxx;
>> }
>>   }
>>
>>   And that's what I get:
>> "Parse error: parse error, expecting `T_STRING' in xxx.php on line nn"
>>
>>   Php doesn't let any function or class member have a name which is
>>   already "used" by another function (or only function from library),
>>   am I right? Or maybe "print" has special status. Maybe that's
>>   because print() is actually not a function? Can anyone tell me
>>   something about that, please?
>>
>> --
>> Best regards,
>>  Olexandr Vynnychenko  mailto:[EMAIL PROTECTED]
>>
>>






-- 
Best regards,
 Olexandrmailto:[EMAIL PROTECTED]



-- 
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]




[PHP] function names

2001-10-25 Thread Olexandr Vynnychenko

Hello php-general,

  I have such code:

  class A
  {
var $xxx;

function print()
{
 echo $xxx;
}
  }

  And that's what I get:
"Parse error: parse error, expecting `T_STRING' in xxx.php on line nn"

  Php doesn't let any function or class member have a name which is
  already "used" by another function (or only function from library),
  am I right? Or maybe "print" has special status. Maybe that's
  because print() is actually not a function? Can anyone tell me
  something about that, please?

-- 
Best regards,
 Olexandr Vynnychenko  mailto:[EMAIL PROTECTED]



-- 
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]




[PHP] parse_str and parse_url

2001-10-19 Thread Olexandr Vynnychenko

Hello php-general,

  I need a function which is opposite to parse_str or parse_url, i.e.
  it makes string containing URL with passed variablenames and
  variablevalues. Did someone see such function? I can't find it in th
  manual. Thank's.

-- 
Best regards,
 Olexandr Vynnychenko  mailto:[EMAIL PROTECTED]



-- 
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]




[PHP] urlencode() and rawurlencode()

2001-10-18 Thread Olexandr Vynnychenko

Hello php-general,

  People, tell me please what's the difference between subj, except
  that the 1st translates space into +.

-- 
Best regards,
 Olexandr Vynnychenko  mailto:[EMAIL PROTECTED]



-- 
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]