473,399 Members | 2,478 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

Upgrade to PHP5 (beta)

Hallo!

I was wondering if my PHP4-Scripts will run under PHP5 (Haeven't tried the
beta yet).
Does anybody know?

Thank you,
-Christoph
Jul 16 '05 #1
7 3664
> "Will PHP 5 break backwards compatibility?"
"No, the main functionality will stay the same, but since PHP 5
adds many more object-oriented features and tools,
it will cause some of the older scripts using PHP 4.x to break."
For more information look at "http://www.zend.com/php/ask_experts.php"


Peter

"MeerKat" <li****************@blueyonder.co.uk> schrieb im Newsbeitrag
news:UM***************@news-binary.blueyonder.co.uk...
I was wondering if my PHP4-Scripts will run under PHP5
> (Haeven't tried the beta yet).


Yes. PHP is always very good at backward compatibility and there
*should* be no reason why they wouldn't work.

MK.

--
MeerKat

Jul 16 '05 #2


Agelmar wrote:
MeerKat wrote:
I was wondering if my PHP4-Scripts will run under PHP5
> (Haeven't tried the beta yet).


Yes. PHP is always very good at backward compatibility and there
*should* be no reason why they wouldn't work.

MK.

I don't know that I'd quite go that far.... PHP is *usually* good at
backwards compatability. I can't even guess how much money I made fixing
scripts for companies when their IT-guys rolled out PHP 4.2.0, and that
wasn't even such a big thing.

Anyone remember anymore the change in if..endif syntax from PHP 2 to PHP 3?
that broke a lot...

PHP3 also used a new method to determine the type of a result... that caused
odd quirks...

And going from PHP3 to PHP4, man, I can't even remember how long it took me
to track down errors caused by empty("0") == true... same with $var = "",
isset($var) == true...

So while I would say that php is usually good about backwards compatability,
I would certainly not say always. Download PHP5, test it out (I checked out
a build from CVS back in April, and have been testing since then...), and
test out ALL your scripts THOROUGHLY. Make sure you have tested everything
with php5 for a while before moving into production with php5 when it comes
out. Personally, I will probably wait until 5.0.2 to roll out on my
production server.


Testing is mandatory...

(As for things that will break PHP5 - I'm trying to think... the MySQL libs
are no longer included, this might cause problems for people who dont read
readmes :-) Other than that, I'll sit back on the sidelines and watch for a
while before jumping on the production bandwagon ^-^
MySQL problem should be solved by then, and the mysqli lib is worth the
move.

// Ian Fette
// Proponent comp.lang.php


The only thing that will really break the scripts is if your script
required the implicit object copy. It's quite easy to fix using
__clone() tought.

Other than the way objects are handled, there are not that many
differences between PHP4 and 5, even if that change makes an entire new
language.

Jul 16 '05 #3
Louis-Philippe Huberdeau wrote:
MySQL problem should be solved by then, and the mysqli lib is worth
the
move.


mysqli is interesting, but requires MySQL >= 4.1.x. Most servers that I've
worked on lately are running 3.23.57 - I think the jump to 4 is a big change
for many sysadmins, and I don't forsee mysql4 taking over on most
development systems until at least 2004. Of those systems that I have worked
on that *are* running MySQL 4.x, they have been almost exclusively MySQL
4.0.x, usually 4.0.11. Currently, the production release is 4.0.13, an 4.1.0
is listed as alpha. I have yet to see a production server that I've been
hired to develop for run 4.1.x. So while I am a bit intrigued by mysqli, I
do not hold out a hope that it will solve the problems of removing the
bundled mysql lib. Hopefully they work something out, but I don't think
mysqli is the answer.

As for SQLite - this is an interesting development, however given that it's
currently primarily PHP 5.0.0 only, I don't forsee implementing it in my
work any time soon, especially given that it does not support ALTER TABLE. I
use ALTER TABLE frequently - for example, I just did a program for a client
that, among other things, tracked objectives and whether a certain item met
certain objectives. I have one table that contains the itemID and then a
field for each objective - when I the client adds objectives, this table is
ALTERed. So unless SQLite implements ALTER TABLE, I think I would only use
it in a very limited fashion.
// Ian Fette
// Proponent comp.lang.php


The only thing that will really break the scripts is if your script
required the implicit object copy. It's quite easy to fix using
__clone() tought.

Other than the way objects are handled, there are not that many
differences between PHP4 and 5, even if that change makes an entire
new language.


I seem to recall that they were proposing eliminating indexing into a string
via $somestring[$index], going for instead $somestring{$index} or something
of that nature. Do you recall if that was implemented?

// Ian
Jul 16 '05 #4
"Keith Maika" <sl***@aoeex.com> wrote in message
news:vh************@corp.supernews.com...
Agelmar wrote:
Louis-Philippe Huberdeau wrote:

...

I seem to recall that they were proposing eliminating indexing into a string via $somestring[$index], going for instead $somestring{$index} or something of that nature. Do you recall if that was implemented?

// Ian


That has been done for a long time. Maybe they are finally going to
remove support for $something[$index] but it's been in the manual for
quite some time that they do not want you do use that syntax, and rather
$something{$index} should be used.


Hmm... personally, I much prefer $something[$index] as it's closer to C, and
just feels more natural :-) No idea why they changed it $string{$index}
just feels like a concatenation of $string and $index... I mean come on,
you're indexing into the string, why drop the array subscripting? gah...

Jul 16 '05 #5
Honestly, I never heard of that modification and have been following the
development for quite a while... and my square brackets still work just
fine.

Don't worry about that, chances they modify that part are very low. They
don't want to remove case insensitivity because it would cause
incompatibility issues, I can't even think of the disaster it would make
if they would change the array element symbol. It's about the most used
syntax of the entire language... except maybe the PHP tags.

Agelmar wrote:
"Keith Maika" <sl***@aoeex.com> wrote in message
news:vh************@corp.supernews.com...
Agelmar wrote:
Louis-Philippe Huberdeau wrote:


...
I seem to recall that they were proposing eliminating indexing into a
string
via $somestring[$index], going for instead $somestring{$index} or
something
of that nature. Do you recall if that was implemented?

// Ian


That has been done for a long time. Maybe they are finally going to
remove support for $something[$index] but it's been in the manual for
quite some time that they do not want you do use that syntax, and rather
$something{$index} should be used.

Hmm... personally, I much prefer $something[$index] as it's closer to C, and
just feels more natural :-) No idea why they changed it $string{$index}
just feels like a concatenation of $string and $index... I mean come on,
you're indexing into the string, why drop the array subscripting? gah...


Jul 16 '05 #6
Louis-Philippe Huberdeau wrote:
Honestly, I never heard of that modification and have been following
the development for quite a while... and my square brackets still
work just
fine.

Don't worry about that, chances they modify that part are very low.
They don't want to remove case insensitivity because it would cause
incompatibility issues, I can't even think of the disaster it would
make
if they would change the array element symbol. It's about the most
used syntax of the entire language... except maybe the PHP tags.


Not for indexing into arrays, only when indexing into a string as an array
to grab the ith character. [] remains the array index operator, but {} is
supposed to be used for strings.

wierd :(
Jul 16 '05 #7
Louis-Philippe Huberdeau wrote:
MySQL4.1 is still in development, and so is PHP5. Moving from MySQL3.x
to 4.x will not be that much of a major change since everything that
used to work still work. I run a dev version of php5 (pre-beta, didn't
have time to upgrade) and mysql4.1 alpha on my test server and the
standard mysql lib connects just fine with the MySQL server. Scripts
won't suffer from that change.

SQLLite will sure be a major part of PHP from now on. PHP developpers
wanted to seperate PHP and MySQL for a while since PHP can do a lot
more
and most seemed to forget it. MySQL is powerful but it's not the only
solution. PHP/MySQL is NOT a platform.

As for your alter table problem, you might want to review your basic
data architecture and use a relational table instead. You shouldn't
need
to modify a table structure that way all the time.


The tables are altered only when a new objective is added, which is very
rare. I would estimate it would happen perhaps once every three months at
the most. There are a list of objectives which are already defined from the
getgo, and these are quite comprehensive. The ability to modify this list is
provided simply for completeness, I doubt that it would be used very often.
relational tables seemed like overkill...
Jul 16 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Spidah | last post by:
Looking at the list of changes made in PHP5 one of them is "Removed the bundled MySQL client library" Does anyone know exactly what this means? I assume we will still be able to code for...
2
by: Rob Ristroph | last post by:
Has anyone built the PHP5 beta 4 as an apache module ? I am using apache 2. Is there some trick, or missing instructions, or known bug ? Perhaps you have to use some version of apache earlier...
8
by: Rob Ristroph | last post by:
I have tried out PHP 5 for the first time (with assistance from this group -- thanks!). The people I was working with have a site that uses lots of php objects. They are having problems with...
0
by: Ira Baxter | last post by:
Semantic Designs is completing PHP5 source code formatters and obfuscators. We are interested in finding Beta customers to test these out. Requirements: You must be using PHP5! Contact...
2
by: Zurab Davitiani | last post by:
Hello group(s), I just released the new beta version of ActiveLink PHP XML Package that works in both PHP4 and PHP5. The package is not dependent on any other XML extensions or libraries and is...
12
by: Sarah Tanembaum | last post by:
Though I installed MySQL5 and PHP5, how come my phpinfo() shows as follow: MySQL Support enabled Active Persistent Links 0 Active Links 0 Client API version 3.23.57 <<<<<<<<<<<<<<< ...
5
by: Aziz | last post by:
Hi, I've recently contacted technical service of a web hosting company and asked them wheter or not they're gonna upgrade to PHP5 and MySQL5. Here's a quote from their response which confused me...
0
by: hristozov | last post by:
Hello group! The configuration: Windows, PHP 4.4.3, MySQL 5.0.24 I'm trying to upgrade PHP 4.4.3 to 5.1.6. I've installed and configured everything but there is a problem with my db...
13
by: John | last post by:
Our technical guy says that our linux server is running PHP 4. I thought we were running 5 already. He says he wants to charge us £500 a year to install and support it because it is a lot of...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.