Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrating from Wordpress #1771

Closed
pt-br opened this issue Aug 20, 2018 · 10 comments
Closed

Migrating from Wordpress #1771

pt-br opened this issue Aug 20, 2018 · 10 comments

Comments

@pt-br
Copy link

pt-br commented Aug 20, 2018

What is the expected behavior?
Migrate a Wordpress application to Strapi

Hi guys!

Is there any tool in order to do that?

Has anyone did that before?

@lauriejim
Copy link
Contributor

Hello @pt-br ! There is no tools for this kind of migration.

@hashinteractive
Copy link
Contributor

I know this is an older PR but if anyone is still interested I wrote an article about migrating your WordPress Blog to a Strapi installation (strapi beta)

https://hashinteractive.com/blog/migrating-a-wordpress-blog-to-strapi

Hope it can help!

@altezza04
Copy link

I know this is an older PR but if anyone is still interested I wrote an article about migrating your WordPress Blog to a Strapi installation (strapi beta)

https://hashinteractive.com/blog/migrating-a-wordpress-blog-to-strapi

Hope it can help!

That's very cool! is that a way to call the import action in the admin interface (for example as a menu item in the Strapi Admin) instead of calling the API endpoint?

@juicecultus
Copy link

I know this is an older PR but if anyone is still interested I wrote an article about migrating your WordPress Blog to a Strapi installation (strapi beta)

https://hashinteractive.com/blog/migrating-a-wordpress-blog-to-strapi

Hope it can help!

Hi
thanks for the tutorial. I've tried implementing it but I run into an error when running GET http://localhost:1337/posts/import into POSTMAN.
The error is:

(node:12066) UnhandledPromiseRejectionWarning: ReferenceError: created is not defined
    at /Users/jus/CODE/Strapi-Import/backend/api/post/controllers/post.js:43:22
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:12066) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 5)
(node:12066) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
(node:12066) UnhandledPromiseRejectionWarning: ReferenceError: created is not defined
    at /Users/jus/CODE/Strapi-Import/backend/api/post/controllers/post.js:43:22
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:12066) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 6)
(node:12066) UnhandledPromiseRejectionWarning: ReferenceError: created is not defined
    at /Users/jus/CODE/Strapi-Import/backend/api/post/controllers/post.js:43:22
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:12066) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 7)
(node:12066) UnhandledPromiseRejectionWarning: ReferenceError: created is not defined
    at /Users/jus/CODE/Strapi-Import/backend/api/post/controllers/post.js:43:22
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:12066) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 8)

@sevenkoncepts
Copy link

I know this is an older PR but if anyone is still interested I wrote an article about migrating your WordPress Blog to a Strapi installation (strapi beta)

https://hashinteractive.com/blog/migrating-a-wordpress-blog-to-strapi

Hope it can help!

Hello every one when i use this formla to upload file in strapi

const image = await fetch(imageUrl)
.then(res => res.buffer())
const buffers = await strapi.plugins.upload.services.upload.bufferize({
buffer: image,
name: 'logo.png',
mime: 'image/png',
size: 20000
});
const uploadedFiles = await strapi.plugins.upload.services.upload.upload(
buffers, {
provider: 'local',
name: 'Local server',
enabled: true,
sizeLimit: 1000000
}
);

I get this error

error TypeError: strapi.plugins.upload.services.upload.bufferize is not a function
at Object.module.exports [as upload] (/Users/macbookpro/path-to-folder/config/functions/upload.js:24:62)

In upload.js on line 24 I have this code

const buffers = await strapi.plugins.upload.services.upload.bufferize({
path: imgPath,
buffer: image,
name: name,
type: image/${ext},
size: buffer.toString().length
});

Looking forward to hear from you all experts

@sitknewnormal
Copy link

Any answer?

@rfos
Copy link

rfos commented Apr 11, 2021

I know this is an older PR but if anyone is still interested I wrote an article about migrating your WordPress Blog to a Strapi installation (strapi beta)

https://hashinteractive.com/blog/migrating-a-wordpress-blog-to-strapi

Hope it can help!

@hashinteractive any chance to create an updated tutorial and share a git here in hithub?

@dulcetti
Copy link

Hi @sevenkoncepts, this function was removed. Now exist the formatFileInfo: https://github.com/strapi/strapi/blob/master/packages/strapi-plugin-upload/services/Upload.js

@dulcetti
Copy link

A link with the differences between them:
e5b319d#diff-3a7fa35e6ea39d3bd6114d319f1ce604b67ab84e30d27078045cb79d5fe5829cL26

@kvnol
Copy link

kvnol commented Aug 14, 2022

I had a hard time doing this, but it worked. I wrote a gist to save this. Strapi v4: https://gist.github.com/kvnol/8492e38a98f428f210fa0479dec18007

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants