- This topic is empty.
-
AuthorPosts
-
January 4, 2012 at 12:16 pm #35962mcgyver47Participant
Hi
I have copied my WP site from http://www.domain.org (database included etc..) to my home server for further local development.
New local IP is: 192.168.1.xxx/MB
Every thing is working well except none of my images located on original site in /wp-content/files/xxx.jpg are showing on local server (image not found of course)
I am pretty sure I can use htaccess file to solve this problem but have not succeded so far
Can I use something like :
Redirect 301 /wp-content/files 192.168.1.xxx/MB/wp-content/files/
This doesn’t work !
Anybody any ideas ?
Thanks for help
Regards from FranceJanuary 4, 2012 at 12:26 pm #93995TheDocMemberInstall a plugin called Velvet Blues Update URLs. You can change all of the URLs on your local copy.
January 5, 2012 at 2:07 am #94027mcgyver47ParticipantThanks
Will give it a try and keep you posted on how it works
Changing all URLs on local copy is to much to do as I have over 150 links to modifyJanuary 5, 2012 at 7:34 am #94040mcgyver47ParticipantUnfortunatly Velvet Blues Update doesn’t do the trick in this particular case
January 5, 2012 at 12:27 pm #94050TheDocMemberWhat doesn’t it change? It has worked flawlessly for me on many occasions.
January 6, 2012 at 12:24 pm #94133mcgyver47ParticipantAll images are referenced in original site: src=”/wp-content/files/onu-s.jpg”
Original site is in root folder
Local site : 192.168.1.190/MB
Images are located in folder: 192.168.1.190/MB/wp-content/files/
MB is just a sub-folder
I havn’t succeded with suggested plugin this is why I think htaccess redirect instructions might be a better answer. Or may be I didn’t use plugin the correct way !
Thanks for helpJanuary 6, 2012 at 12:34 pm #94136TheDocMemberAaahhh, so it’s a relative link… interesting, as WordPress never does it like that. Is this something that you’ve hard coded into a template or you’ve modified the src URLs in the actual WordPress pages?
I don’t know enough about htaccess to provide you with a solution there.
January 8, 2012 at 3:05 am #94257mcgyver47Participantit is definitly a relative link that I have hard coded into all posts with thumbnails
To improve my coding practices how do you recommand I should code these src URLs in the future.
Thanks for helpJanuary 8, 2012 at 3:20 am #94259BillyParticipantI’ve had the same problem that I can never get images into a template with HTML. I just use a div with a background of the image, and that does work for some reason.
January 8, 2012 at 7:24 pm #94295TheDocMemberHave you hardcoded it into a template (single.php, page.php, etc) or have done on a post by post basis?
-
AuthorPosts
- The forum ‘Other’ is closed to new topics and replies.