import-blogger.php not working

I have followed the instructions for importing Blogger to WP (from http://wiki.wordpress.org/BloggerImport and from import-blogger.php itself too). However, when I click on the OK button at the bottom of the page, nothing happens. The page simply reloads itself and nothing happens.

This is the url that I see: /import-blogger.php?action=step1&submit=OK

I dont know if this will help or not, but if you are on a host like dreamhost sometimes the ?x=blah part of those urls will work but not the &x=bleh bit for some reason. I’ve had experience with that myself.

I guess I should give more info, so we can try to get this worked out together. I’m using Canaca.net for my hosting needs. The php files for my three months of archiving are definately on there, but there’s also a directory called “2005” that has all my posts in html form. It’s creating both of those each time. When I run import-blogger.php, the instructions show up, but when I click OK, the page simply reloads. I’m using a Mac. I’ve tried it with Firefox and IE.

I was having the same problem. Then I found my way here: http://catsutorials.catsudon.org/?p=15. It’s the visual tutorial for a slightly modified version of import-blogger.php (it also collects blogger comments!). It’s helpful, btw. It confirmed for me that I did everything correctly, but the import script still did nothing.

With a feeling that it sure couldn’t hurt – I didn’t know where else to turn – I began reading the comments to the tutorial. Toward the bottom I found a comment by Brad ( http://catsutorials.catsudon.org/?p=15#comment-253 ), posted yesterday, who’d been having this same problem along with many others as shown in other comments. Well, ol’ Brad found a solution!

He stripped down the import file to make the script run as soon as you opened the file in your browser. He posted a link to his greatly modified script: http://alittlebitleft.com/import-blogger.phps. It worked! All the blogger files I was trying to import are now safely tucked away in their new WordPress home!

*Of course, this only works AFTER you’ve gotten all your blogger files in the proper place on your server. (This is for those who are less familiar with working with php.) If you are not sure what to do, be sure to read the comments on the above-mentioned tutorial.

Upon stumbling over this exact same problem (page merely reloads after clicking “OK” with junk added to the end of the URL) while using Justin’s excellent import-haloscan script, but having no quick and dirty stripped down script like the one I linked to above for importing blogger posts, I wrote Justin and asked if he would be willing to similarly customize his script for my use.

Well, I believe he has found the appropriate solution for both scripts! He changed a very small part of the script so that it uses a different mechanism for determing whether the “OK” button has been clicked.

He doesn’t guarantee whether it’s the best solution or the most secure solution, but it certainly does work.

Apparently the problem lies in some kind of change in the core WP code between 1.5.1.2 and 1.5.2.

The change to make in the import-blogger script included with the wp1.5.2 download is to replace lines 3-17, which should look like this:

Hello. I had this problem too. As a php programer I thought i would take a look at the scirpt to try and see what was wrong with it. After editing the script a bit, and trying it, i was pleasently suprised when it worked. Below is a zip download link to download the file. Once you have downloaded it, replace it with the old one 🙂
(Though I must say it doesn’t import comments, though I am working on that 😉 )

Seems the script is somewhat broken in 1.5.2. Looks like the $action variable isn’t populated, might have something to do with register_globals although I couldn’t be bothered to read through the code. The script from JoshHendo worked fine for me.