插入很多产品opencart脚本
我有一个 python 脚本,其中包含我的所有产品、描述、图像等。现在我想将所有这些信息插入我的 Opencart 主题中。我试图找出如何将所有这些保存在 MySQl 数据库中。我知道我必须使用MySQLdb for python,但我不知道我必须在哪里保存名称、图像的方向、图像、大小......
我知道有导入/导出模块。也许我必须安装其中一个模块并将我的信息保存在 csv 文件中,然后导入它。
哪种方法是插入所有这些内容的最快方法?还有其他方法吗?因为模块相当昂贵。
太感谢了!!
I have a script in python in which I have all my products, descriptions , images, etc. Now I want to insert all this information in my Opencart theme. I try to find out how to save it all of this in the MySQl database. I know I have to use MySQLdb for python but I don't know in which place I have to save de name, the direction of the image, the image, the size....
I know that there is import/export modules. Maybe I have to install one of those modules and save my information in a csv file and then import it.
Which would be the most quick method to insert all of this? Is there any other method? Because the modules are quite expensive.
Thank you so much!!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我认为您最好的选择是使用导入/导出工具(有免费的工具可用,例如 JNeuhoff 的 Excel 工具)。一旦你弄清楚自己在做什么,它就相当容易使用。最好的办法是清除安装时附带的所有默认数据,创建几个产品、类别等并通过导入/导出工具导出,查看它如何包含数据,然后开始开发脚本来生成您当前商店商品中的字段来填充它。我还建议安装 vQmod ,这样您就可以安装它而无需对管理文件进行核心更改
Your best option in my opinion is to use an Import/Export tool (there are free ones available like the excel tool by JNeuhoff). It's fairly easy to use once you figure out what you are doing. The best thing to do is to clear all the default data that comes with an install, create a couple of products, categories etc and export via the import/export tool, see how it comprises the data, then start developing a script to generate the fields from your current store items to fill it. I would also recommend installing vQmod too so that you can install it without making core changes to your admin files