We are developing a site using drupal 7 So we created drupal site with name of myapp, so the url is http://localhost/myapp

Also another developer is working for same site in his development machine with the name of myapp2 so its http://localhost/myapp2

I have installed ckeditor for rich content and configured relative path for inserting images.

When I insert an image in myapp site the relative path comes like 'myapp/sites/all/files/images/img1.jpg' instead of 'sites/all/files/images/img1.jpg'

hense when I share my database with my other team member uses myapp2 they are not able view the inserted images. their path looks like this 'myapp2/myapp/sites/all/files/images/img1.jpg'

I have used pathologic to setup the two users urls in Text Format setting page like http://localhost/myapp and http//localhost/myapp2 but not works as expected.

any one help me what else I can do to solve the issue.


Pathologic will solve your problem, in the configuration of the filter put both http://localhost/myapp & http://localhost/myapp2 and the filter should work everything out


Finally I tried the solution found by searching various sites.

I put these two path items into text formats setting


now its working. :)

So, since the other user who have myapp2 in his development system, there would chances for forming images path like myapp2/sites/..., hence we have to add more filter items like below


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.