Title: Problem with absolute image path
Last modified: August 22, 2016

---

# Problem with absolute image path

 *  [Nelson Amaya](https://wordpress.org/support/users/nelsonamaya/)
 * (@nelsonamaya)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/problem-with-absolute-image-path/)
 * Hi, I used this plugin on my site (local server) and everything worked like a
   charm. However, when I migrated my site to a web server, the images path was 
   wrong, cause they were saved on DB with the absolute path of my local server.
 * I checked the plugin code and it’s too easy to solve, however I’d like you to
   update this change (if possible) so I won’t have to hack the plugin, having in
   mind that this issue could be a common problem when a site using this plugin 
   need to be migrated to another server.
 * In line 212 I removed $imgurl[“host”] from the $imgsrc variable, so its now:
   
   $imgsrc=$imgurl[“path”];
 * Next I replaced the line 215 this way:
    Before: echo ‘<img src=”//’.$imgsrc.'”
   alt=”‘.esc_attr($$alt).'”>’; Now: echo ‘<img src=”‘.$imgsrc.'” alt=”‘.esc_attr(
   $$alt).'”>’;
 * And that solved my problem, I hope you can merge this fix into the original plugin.
 * [https://wordpress.org/plugins/links-with-icons-widget/](https://wordpress.org/plugins/links-with-icons-widget/)

The topic ‘Problem with absolute image path’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/links-with-icons-widget.svg)
 * [Links With Icons Widget](https://wordpress.org/plugins/links-with-icons-widget/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/links-with-icons-widget/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/links-with-icons-widget/)
 * [Active Topics](https://wordpress.org/support/plugin/links-with-icons-widget/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/links-with-icons-widget/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/links-with-icons-widget/reviews/)

## Tags

 * [absolute path](https://wordpress.org/support/topic-tag/absolute-path/)

 * 0 replies
 * 1 participant
 * Last reply from: [Nelson Amaya](https://wordpress.org/support/users/nelsonamaya/)
 * Last activity: [11 years, 9 months ago](https://wordpress.org/support/topic/problem-with-absolute-image-path/)
 * Status: not resolved