Migrate Google Notebook notes to personal database using PHPEver since Google Notebook closed it's doors on any future development and support, I've had this thought that it might be wise to use another web notebook utility for saving text snippets through a browser. Existing Google Notebook users can still use the application, but without any new development and support, it kind of feels like a wedding without the bride and groom. Since I am a web developer, I've decided the best route is a custom-built application, rather than spending time learning another web notebook application, and possibly having to pay for it. The first thing I need to do is migrate Google Notebook notes into my own MySQL database. I've created a bare-bones database table to start - at least enough fields to migrate my existing notes from Google Notebook into the table: The Next, I'll get an export of an individual notebook from Google Notebook: The Atom option will work just fine for our needs. This will prompt you to download the XML file: With PHP, I'm going to loop through each note and insert into my database. First, upload the XML file to your web server where PHP is running. You might want to give it a URL-friendly filename while you're at it. I've renamed my exported notebook file to:
Next, in your PHP script, your code to insert each note into your own database could look something like this: Here we use cURL to grab the XML content, then loop through it using a
Overall, though - this shows you how simple it can be to migrate old Google Notebook notes into your own database with PHP.
Comments/Mentions
|
Editor Picks
Email NewsletterSubscribe to the digest newsletter to receive posts by email: Recent Comments
Advertisements
|