owen2345 / camaleon-cms

Camaleon CMS is a dynamic and advanced content management system based on Ruby on Rails
https://camaleon.website
MIT License
1.21k stars 285 forks source link

Server migration and image url problem #538

Closed killinit closed 5 years ago

killinit commented 7 years ago

Hello.

I have moved website to new domain. 1) in sites settings I have changed URL to new domain. 2) I have cleaned media cache 3) I have cleaned front cache ( for all post types)

and when I: current_site = CamaleonCms::Site.first post = current_site.posts.find(69).decorate // page with feature image

post.the_thumb post.get_meta("thumb")

give me link with old domain.

how to change/clear meta information to new url?

and the: post.the_url(:en) => "http://test.host/en/our-software/lms/quizes"

I have never used local server for this project...

owen2345 commented 7 years ago

Hi @killinit please check this: http://camaleon.tuzitio.com/documentation/category/40756-uncategorized/migrate-to-another-domain.html

killinit commented 7 years ago

Hi @owen2345

1) I have site was change using admin/settings/site and slug value in cama_term_taxonomy has correct domain.

2) problem is that imaged assign before domain migration are added with old domain in cama_metas

suggestion: for key "thumb" it should store only path to public folder (no domain) except AWS S3 is used

3) what about post.the_url(:en) => "http://test.host/en/our-software/lms/quizes"

owen2345 commented 7 years ago

Fixed! please try again using the git version (it was a problem with draper dependency)

owen2345 commented 7 years ago

About the thumb, I have planned to change for the next version.

mohdsameer commented 6 years ago

Hi @owen2345 - I am getting the same issue. Any news on this?

Thanks,

owen2345 commented 6 years ago

Guys, today I released a new version which uses the relative path rather than absolute path for media files. Please test it and let me know if you see errors.