We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Updating a module in EE 1.X

Development and Programming

Carter Digital's avatar
Carter Digital
18 posts
15 years ago
Carter Digital's avatar Carter Digital

Hello

I’ve written a module for 1.X and now need to update it, changing some of the database structure without loosing information in the tables that were created as the module installed.

There’s module_install and module_deinstall functions but can’t see an module_update anywhere. Does anyone have any examples I could use of how to do this?

Thanks

       
Focus Lab Dev Team's avatar
Focus Lab Dev Team
1,129 posts
15 years ago
Focus Lab Dev Team's avatar Focus Lab Dev Team

There isn’t anything built in to auto-run an update function. I’d recommend adding a method in your mcp.MODULE.php file for your update check and execution, and run it within your home method (whatever you run on the module’s CP home page). If the version is old and needs an update, perform the update and return a visual message. If not, silently return nothing additional.

Does that make sense?

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.