Trying to upgrade from CakPHP 1.1

Hi,

I am pretty novice when it comes to PHP so this is a daunting task pushed my way. The guy who made the site to begin with don't seem to want to do the upgrade, so I, who am a webdesigner, have to get into the code and make it work.

So my question is this:

Must these things be fixed line by line, or is there any global code that produces these errors?

I get the following messages:

Notice (8): Undefined variable: error [APP/views/pages/index.ctp, line 10]

<?php if($error){ ?>

include - APP/views/pages/index.ctp, line 10

View::_render() - CORE/cake/libs/view/view.php, line 666

View::render() - CORE/cake/libs/view/view.php, line 376

Controller::render() - CORE/cake/libs/controller/controller.php, line 806

PagesController::display() - CORE/cake/libs/controller/pages_controller.php, line 82

Object::dispatchMethod() - CORE/cake/libs/object.php, line 118

Dispatcher::_invoke() - CORE/cake/dispatcher.php, line 227

Dispatcher::dispatch() - CORE/cake/dispatcher.php, line 194

[main] - APP/webroot/index.php, line 82

Asked by mrfusion, on 11/3/10

1 Answer

firstly 1.1 is very old, and the upgrade to 1.2 is not simple. cake wa basicaly rewriten from 1.1 to 1.2, and if you are going to be up grading i would recomend going direct to 1.3

but the error you have there is simple, $error is not set

just make that line


<?php if(isset($error) && $error){ ?>

Answered by dogmatic69on 11/3/10

I see. thanks a lot for the fast answer and the recommendation. Yes it is an ancient version indeed.

mrfusion - on 11/3/10

<< comments | comments >>
<< previous next >>

Your Answer

You can use Creole Wiki Syntax to format your text.

Rating

0

Viewed

173 times

Last Activity

on 11/3/10