Title: inraid's Replies | WordPress.org

---

# inraid

  [  ](https://wordpress.org/support/users/inraid/)

 *   [Profile](https://wordpress.org/support/users/inraid/)
 *   [Topics Started](https://wordpress.org/support/users/inraid/topics/)
 *   [Replies Created](https://wordpress.org/support/users/inraid/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/inraid/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/inraid/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/inraid/engagements/)
 *   [Favorites](https://wordpress.org/support/users/inraid/favorites/)

 Search replies:

## Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Redirection] How to format CSV for import?](https://wordpress.org/support/topic/how-to-format-csv-for-import/)
 *  [inraid](https://wordpress.org/support/users/inraid/)
 * (@inraid)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/how-to-format-csv-for-import/#post-9216493)
 * use this:
    Source URL, Target URL, [Regex 0=false, 1=true], [HTTP Code] save 
   list as .csv
 * example:
    [https://mydomain.id/scopus-list/5300152732,https://www.targetdomain.com/sourceid/5300152732,1,301](https://mydomain.id/scopus-list/5300152732,https://www.targetdomain.com/sourceid/5300152732,1,301)
   [https://mydomain.id/scopus-list/29949,https://www.targetdomain.com/sourceid/29949,1,301](https://mydomain.id/scopus-list/29949,https://www.targetdomain.com/sourceid/29949,1,301)
   [https://mydomain.id/scopus-list/19700188320,https://www.targetdomain.com/sourceid/19700188320,1,301](https://mydomain.id/scopus-list/19700188320,https://www.targetdomain.com/sourceid/19700188320,1,301)
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [How to add an external url to a thumbnail featured image](https://wordpress.org/support/topic/how-to-add-an-external-url-to-a-thumbnail-featured-image/)
 *  Thread Starter [inraid](https://wordpress.org/support/users/inraid/)
 * (@inraid)
 * [10 years, 2 months ago](https://wordpress.org/support/topic/how-to-add-an-external-url-to-a-thumbnail-featured-image/#post-7426116)
 * Nevermind, i finally find it :), changed my theme though..
 * How to add an external url to a thumbnail featured image:
    Required plugin: Advanced
   Custom Fields
 * 1. Add the following code to **function.php**
 *     ```
       function link_url_thumb() {
         global $post;
         $thePostID = $post->ID;
         $post_id = get_post($thePostID);
         $title = $post_id->post_title;
         $perm  = get_permalink($post_id);
         $post_keys = array(); $post_val  = array();
         $post_keys = get_post_custom_keys($thePostID);
   
         if (!empty($post_keys)) {
             foreach ($post_keys as $pkey) {
                 if ($pkey=='urlthumb' || $pkey=='url_thumb' || $pkey=='thumb_url') {
                     $post_val = get_post_custom_values($pkey);
                 }
             }
             if (empty($post_val)) {
                 $link = $perm;
             } else {
                 $link = $post_val[0];
             }
         } else {
             $link = $perm;
         }
         echo ''.$link.'';
       }
       ```
   
 * 2. Once that’s done, open your **index.php** file and call the newly created 
   link_url_thumb() function:
 * Find something like this in your **index.php**:
    `<a>" rel="bookmark"><?php the_post_thumbnail('
   pingraphy-home-thumbnail'); ?></a>`
 * Changed to:
    `<a>" rel="bookmark"><?php the_post_thumbnail('pingraphy-home-thumbnail');?
   ></a>`
 * 3. Create Custom Fields called urlthumb or url_thumb or thumb_url and put the
   external URL complete with http in the value box.
 * source: [http://www.wpbeginner.com/wp-tutorials/how-to-link-to-external-links-from-the-post-title-in-wordpress/](http://www.wpbeginner.com/wp-tutorials/how-to-link-to-external-links-from-the-post-title-in-wordpress/)
 * check out the result on one of the thumb image at my site: [prankstuff.com](https://wordpress.org/support/users/inraid/replies/prankstuff.com?output_format=md)

Viewing 2 replies - 1 through 2 (of 2 total)