Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
By aamato on
I need someone to help me migrate the phpnuke site www.asclepios.com.br to drupal.
First of all, i need to keep all users (i have few)
Then I need to keep all web_links and downloads (what are the equivalent modules in drupal??)
after that all stories
If possible I would like to keep all statistics
After that is done, I will need to migrate some modules that were customized for me. But this is a second fase of the project.
If you can help me, please reply.
I already tried the php2drupal that already exists, but I am having difficult to migrate
Thanks
Comments
Make your price
make your bid
=-=
I'd contact the person who wrote this script: http://drupal.org/node/498
_____________________________________________________________________
My posts & comments are usually dripping with sarcasm.
If you ask nicely I'll give you a towel : )
I'd contact the person who
That would be me, although I really heavily modified an existing script. I use the Drupal 5.0 API as much as possible but there are some older parts that are straight DB manipulation that should probably be updated...
W
Some help on your way to migrating weblinks from phpnuke...
Oh, and as for weblinks and downloads-- your best bet is to use the CCK and CCK "links" field module to create custom content types for your download files as well as your links.
I wrote a custom addition to the script to move my web links over. To use, you first have to set up a custom content type with CCK. Here's a slightly-modified export of my "mylinks" content type that you can maybe import with CCK and play with:
Pretty simple content type.
Now here's some code (which I hereby release under the GPLv2) you can try... hope this works, as I haven't tried it in months. I believe it can also filter out links with bad URLs and can remove duplicate links as well (keeping the most recently added link when there are duplicates). See more below.
If you want to migrate the link's *categories*, you will also need to manually pre-create the link category terms as taxonomy terms via the Administration menu. If you don't know what all the categories are that you'll need to create, the first (commented out) bit of code below will spit out all the categories in your phpnuke site along with their category id (or "cid"). Its best to create the terms in Drupal in the same the order they appear in phpnuke so that you can determine the offset between the cid and the newly created term id. The script below should then be able to use that offset (in my case it was only +1) to re-associate the old categories to the new terms.
If you choose not to keep your categories, or if what I just typed sounded too complicated, you can just comment out anything having to do with categories/taxonomy/terms in the code below and don't worry about categories/terms for your migration.
--CODE BEGINS--
--CODE ENDS--
The reason I didn't include this (and a few other bits) in phpnuke2drupal is that it required CCK, the link field, and pre-creating custom content types with specific field names, plus you have to pre-make the taxonomy categories to match your phpnuke link categories, so it wasn't "universal" enough to include in a general migration script.
Caveats: this isnt tested beyond my own personal use. I haven't really scoured through to make sure this will all work and am kinda going from memory Don't run on a DB that isn't thoroughly backed up. That's obvious I guess. This is messy programming. Inefficient and probably the "wrong way" to do it. But it worked for me, and was meant for one-time execution.
You also may want to change $promote to zero unless you want the new links to appear on the front page...
Good luck,
W
And here's how I did the reviews...
Don't know if anyone is interested in the code, but I have a few moments to add my "migrate the reviews" code. I modified my own code to make it more generic, so hopefully I haven't introduced any bugs...
As before, here is my (slightly generic-afied) CCK 5.x structure I exported of the reviews node. As above, make sure you have CCK & the CCK link field module installed. Simply import this stuff as a first step.
And here is the reviews migration code using the previous content type. Add it to the phpnuke2drupal script (version .002 or whatever the latest was) so that it executes after it's done all the other migration steps.
Note: I haven't carefully reviewed the code- I'm basically copy/pasting from my migration script as it was run months ago with a few tweaks for clarity. If it doesn't work for you, you may need to tweak it a little bit. Post here if you have questions. I'll try to check in every so often...
I am GPLing this below as well. (v2).
If you import the reviews, you will notice that the reviews simply have the number 1-10 listed as the rating. I wanted to graphically show the rating with images-- that is, show the # of stars so that a rating of 1 looks like "*" and a rating of ten looks like "**********" (where asterisks are replaced by the star.jpg graphic).
To create a (very easy) custom display of the reviews, I first created a file at /sites/default/files/star.png which was literally a tiny star with a transparent background. I then created a template file in the /sites/all/themes/garland/ directory that I called node-myreviews.tpl.php, which has the following content:
Hope this works for ya! Good luck,
W
Site Transfer
Hi,
We would be interested talking with you about this project.
B
Migration
Hi
How would i migrate the downloads module?
And also how do i keep my stats for each of the downloads?
If someone can migrate my site with a large downloads mod content and categories,im willing to pay
Thanks