1. Create a new Link Image Field or convert an existing Image field to a Link Image Field
2. Notice that if you have the filefield sources module installed, you cannot choose an alternate file picker.

expected: User can choose an alternative file picker such as IMCE to browse the server for an image

Comments

spgd01’s picture

I second the request

webdrips’s picture

+1 to see this request

chrisgross’s picture

This would be great, especially to be able to use tokens for custom file paths.

andrew_mallis’s picture

+1

dejavu_007’s picture

I managed to do this by changing in Filefield source module.
In line:60 of filefield_sources.module add 'linkimagefield_widget' to the array().

/**
 * Implements hook_filefield_sources_widgets().
 *
 * This returns a list of widgets that are compatible with FileField Sources.
 */
function filefield_sources_filefield_sources_widgets() {
  return array('filefield_widget', 'imagefield_widget', 'linkimagefield_widget');
}
versantus.nik’s picture

Well found!

Better yet, add this either in the linkimagefield.module file, or better yet into your own custom module so that you're not messing about with the filefield Sources code (and making your life harder when it comes time to upgrade).

If you implement the available hook, you can just add your own widgets to the filefield Sources list.

Put this in linkimagefield.module, or create your own module and add it in there.

/**                                                                                                                                                                            * Implement hook_filefield_sources_widgets().      
  *                                
  * This returns a list of widgets that are compatible with FileField Sources.
  */
function linkimagefield_filefield_sources_widgets() {
         return array('linkimagefield_widget');
}

Remember to enable your custom module if you used one, and then edit your linkimagefield CCK field to enable other filefield sources.

pfrenssen’s picture

Version: 6.x-1.0-alpha4 » 6.x-1.x-dev
Priority: Major » Normal
Status: Active » Reviewed & tested by the community
StatusFileSize
new957 bytes

Nice, it works! Here is the code from #6 in a patch, I just changed the documentation a bit.

chriscohen’s picture

StatusFileSize
new439 bytes

Let's get that patch committed, and also this patch, which is the same thing, but for Drupal 7.

sickness29’s picture

Issue summary: View changes
Status: Reviewed & tested by the community » Closed (outdated)

Development or support is not planned for D6. All D6-related issues are marked as outdated in a bunch.

Everyone can apply the patch above (not tested by the maintainers, tested by the community) to their D6 projects.
If the issue remains relevant for D10+ versions, merge requests with proposed solutions for a new module version (D10+) are welcome in a new follow-up issue.

Thanks!

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.