Transcript

1.
All About
ExpressionEngine 2
What’s new, whether to upgrade, and
how to migrate from EE 1.x to EE 2.x
Prepared by Ruthie BenDor for
the BostonEErs June 2010 Meetup

2.
Ch-ch-ch-changes
What’s new in EE2?
Prepared by Ruthie BenDor for
the BostonEErs June 2010 Meetup

3.
Hey, Back-end Developers!
✓ ExpressionEngine 2 is built atop CodeIgniter.
✓ Building EE2 add-ons is a whole different ball game.
✓ New type of add-on called Accessories.
✓ EE2 runs fully and only on UTF-8.
✓ EE2-generated URLs do not use a trailing slash.

7.
Consider upgrading now if:
✓ You have a business case for upgrading to EE2;
✓ All the add-ons your site needs are available for EE2;
✓ You are comfortable with using beta (albeit well-tested)
software to power your website; and
✓ You have time to spend on upgrading right now.
Otherwise, stick with EE1.x for now, and
re-evaluate every month.

8.
Movin’ On Up
How to migrate an EE 1.x site to EE 2.x
... in 12 kinda easy steps

9.
1. You’re running EE 1.6.9, right?
✓ If you’re running anything less than EE 1.6.9, follow the
upgrade instructions to bring your install up to EE
1.6.9: http://expressionengine.com/docs/installation/
update.html
✓ This isn’t, strictly speaking, necessary - but it does
eliminate one potential point of failure from the
upgrade process.

10.
2. Template tedium.
✓ The upgrade process claims to handle templates saved
as ﬂat ﬁles, but best to eliminate this potential point of
failure. (Besides, serving templates from the database is
more performant than serving them as ﬂat ﬁles.)
✓ Open your code editor & your web browser. Log in to
your Control Panel & browse to the Template Manager.
✓ For each template: Manually copy & paste the contents
of each ﬂat ﬁle into the associated template. Uncheck
the ‘Save Template as File’ option. Click Update and
Finished. (Yes, this sucks. A checklist helps. So does beer.)

11.
3. Download party!
✓ Download and unzip the latest build of EE 2 from
https://secure.expressionengine.com/download.php
✓ Rename EE2’s system folder to be whatever you’ve
renamed it in your current installation.
✓ Download all of the add-ons your site will use from
http://www.devot-ee.com/ or directly from the add-on
author(s). Put them aside for now; you’ll be installing them
once you’re done with EE2.

12.
4. Take your site down.
✓ On your web server, copy system/
expressionengine/utilities/offline.html
to your main directory, where EE’s index.php ﬁle is.
✓ Rename the copied offline.html
to be index.html.
✓ Open your website in a browser
and verify that it’s showing
the “ofﬂine” page.

14.
6. Back up your files & folders.
✓ Download all ﬁles and folders from your web server
onto your local machine.
✓ Once the download completes, poke around and make
sure that everything downloaded properly.
✓ Make note of system/config.php, as you’ll need
some of the information in it during the upgrade.
✓ This might take a while. We’ll wait.

15.
7. Back up your database!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
✓ Download a full dump -- schema AND data -- of your
database, in SQL format. On shared hosting? Use
phpMyAdmin. On dedicated hosting? Use your database
management tool of choice, you lucky bastard.
✓ Test your backup: run the SQL you just generated
against a local test database, and make sure it worked.
✓ This might take a while. We’ll wait.
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Seriously, back it up.

16.
8. Upload & renaming party!
✓ On your web server, rename the system folder to be
system_ee1. Then upload your new system folder.
✓ On your web server, rename the themes folder to be
themes_ee1. Then upload your new themes folder.
✓ On your web server, rename the index.php ﬁle to be
index_ee1.php. Then upload your new index.php ﬁle, open
this ﬁle, and update the system path to reﬂect your renamed
system folder.
✓ Upload your backed-up system/config.php into system/
expressionengine/config/.

20.
10. Update Wizard time.
✓ On Page 1, click the “click here to begin” link.
✓ On Page 2, it’ll show you what version of EE you’re currently
running. Click the “update EE to 2.0” link.

21.
10. Update Wizard time.
✓ On Page 1, click the “click here to begin” link.
✓ On Page 2, it’ll show you what version of EE you’re currently running.
Click the “update EE to 2.0” link.
✓ On Page 3, magic happens. The page will refresh itself a bunch of
times. Don’t close the browser. Let it ﬁnish. It’ll take you to...

22.
10. Update Wizard time.
✓ On Page 1, click the “click here to begin” link.
✓ On Page 2, it’ll show you what version of EE you’re currently running.
Click the “update EE to 2.0” link.
✓ On Page 3, stuff happens. The page will refresh itself a bunch of
times. Don’t close the browser. Let it ﬁnish. It’ll take you to...
✓ Page 4, which says that you’re now running the latest version
of EE, and to ﬁnd and delete the installer folder located
at /system/expressionengine/installer/. Do so.

23.
11. Add-on install party, and, done.
✓ Log in to the Control Panel. Poke around. Everything look good?
✓ Each of your EE2-ready add-ons should come with detailed installation
instructions. Install them per the instructions.
✓ The update wizard will have disabled all system extensions; you will
need to check to make sure the ones you need are enabled.
✓ You may also need to tweak template code to account for syntax
differences between EE 1.x plugins and EE 2.x plugins.
✓ Once all of your add-ons are in place, rename the index.html in
your main directory to be offline.html, load your website in a
browser, and cross your ﬁngers.

24.
12. Cleanup - or, Disaster Recovery.
✓ All well? Delete the old system_ee1 and themes_ee1
directories and the old index_ee1.php from your web server.
✓ Did something go wrong? Start by disabling all the third-party add-
ons you just installed. If that ﬁxed it, re-enable the third-party add-
ons one by one until you’ve isolated the problem.
✓ Did something go seriously wrong, and you just don’t have time to
deal with it right now? Roll back:
✓ Rename system to be system_ee2, and system_ee1 to be system.
✓ Rename themes to be themes_ee2, and themes_ee1 to be themes.
✓ Rename index.php to be index_ee2.php, and index_ee1.php to be index.php.
✓ Run your backup SQL script against your production database.