Questions tagged [php4]

For issues relating to development using PHP, version 4.

PHP is a widely-used, general-purpose scripting language designed specifically for web development, though it has since been extended to other applications too. PHP is the most popular language for web development, powering over 20 million websites.

Useful Third-party Code and Tools

In addition to the vast functionality provided in the PHP Core and through PEAR and PECL, there are a number of noteworthy 3rd party contributions to the PHP world, some of which are listed below.

Related tags

323 questions
1
vote
1 answer

Does setting $this = &$otherObject change anything?

The comments indicate that I have to clarify my point: I'm a developer and consultant working on foreign code here. My current assignment is to help migrating an existing (very large) system from PHP4 to Java. While reviewing the code I stumbled…
Christoph Grimmer
  • 4,210
  • 4
  • 40
  • 64
1
vote
3 answers

PHP copying of remote image fails with timeout

there are many questions on this topic, but I couldn't find an answer to my scenario. The client project I am working on is hosted on a server running PHP 4.3.9 and I am trying to copy a remote image to the server. This always fails with a…
kontur
  • 4,934
  • 2
  • 36
  • 62
1
vote
1 answer

PHP: What is wrong with my future date validator?

I have a date validator code segment, its supposed to validate any future date. For debugging purposes I want it to expire by Tomorrow, or in about 3 hours. As of writing this Tomorrow is Dec 18. Its 10:40PM GMT-5 Dec 17 It flags it as the past.…
jason dancks
  • 1,152
  • 3
  • 9
  • 29
1
vote
3 answers

php4: wrong parameter count for mysql_query?

Not sure how much context I can provide. I just tried to do overdue homework and I get the error: Its supposed to be a simple login page, login check and loginsuccess and failure. on check.php: Warning: Wrong parameter count for mysql_query() in…
jason dancks
  • 1,152
  • 3
  • 9
  • 29
1
vote
3 answers

PHP: $_GET variable is not being properly read

I have 2 php pages: editpost.php simply generates a form to edit a user review. addcomment.php, in this case is supposed to update the mysql for that post. It simply tests to see if $_GET['edit'] and the proper variables are set. For some reason it…
jason dancks
  • 1,152
  • 3
  • 9
  • 29
1
vote
1 answer

Set-Cookie not working in IE

I am using the Set-Cookie function ..it works fine in chrome and firefox. It sets the cookie and I can see it in firebug. But for some reason it is not setting the cookie in I.E Can anyone verify if my syntax is correct or if I am doing something…
Micheal
  • 2,272
  • 10
  • 49
  • 93
1
vote
2 answers

PHP 4: Can not understand the OOP behaviour

While practicing for certification, I came across one MCQ the question. It was as below. Q: Consider the following script. What will it output?
Rajan Rawal
  • 6,171
  • 6
  • 40
  • 62
1
vote
3 answers

moving from php 4 to php 5

I got this project developed with PHP5. The project was given to me with full details (php version to use, mysql version to use, etc). My client said to develop the project using PHP5, I am glad about this cause i could practice my OOP. After the…
Jayson O.
  • 485
  • 1
  • 6
  • 20
1
vote
3 answers

SimpleXMLElement PHP4

I know SimpleXMLElement doesn't work in PHP4, but is there a something similar I can replace it with to make the script work with PHP 4?
Chris
  • 33
  • 2
  • 5
1
vote
1 answer

Unable to execute shell script in exec dir

We have a server running PHP 4.3.9 with safe_mode ON and safe_mode_exec_dir setted to /usr/local/bin/php/ So, as it is written on php.net, we can't execute any script which is not in safe_mode_exec_dir. I want to call unzip system command (don't…
clement.michelet
  • 238
  • 2
  • 16
1
vote
0 answers

Any way to debug php4.3 or php4.4 using Apache2 on windows?

I believe I've tried every possible approach to setting up a debugging envronment in windows using apache2 and php4 but failed with all of them. I have a couple of apache instances both for php4.3 and php4.4. I got xdebug installed on the 4.4…
CodeFan
  • 89
  • 1
  • 10
0
votes
1 answer

Dollar sign in text when passing variable

I got stricky/old php code, I just try to clean it , fix some bugs, and so on. Also the server uses php 4 too. The problem is the following: I get some data back from the database, I work with those data and show them. If the result contains a…
tildy
  • 979
  • 10
  • 20
0
votes
1 answer

php4 time calculating time error

i'm having issue with calculating time in php. It's a simple script: when a time is given (datenow), a function ordertime evaluates: if it is < 10AM --> it displays today at 12:30 if it is < 14PM --> it displays we can't take the order and if it's…
chenci
  • 113
  • 1
  • 10
0
votes
4 answers

PHP: Get array of text from perticular XML node type?

I am not totally new to PHP or XML but I am 100% new to paring XML with PHP. I have an XML string that has several nodes but the only ones I am insterested in are the < keyword > nodes which there are an uncertain number of each containing a phrase…
JD Isaacks
  • 56,088
  • 93
  • 276
  • 422