USES
Drupal 7.12+41-dev
Link 7.x-1.0+10-dev

FIELD CONFIG
Link field settings = standard except Validate URL = NO

IN MY OWN FORM
$node->field_cmelink[$node->language][0]['field_cmelink_url'] = 'http://dmaster.cord.no';
$node->field_cmelink[$node->language][0]['field_cmelink_title'] = 'Info';

RESULT
Notice: Undefined index: url in _link_process() (line 345 of ../link.module).

Anyone who can tell me how to solve this?

CommentFileSizeAuthor
#4 link-1483494-4.patch827 bytesvinmassaro
linksupport.txt2.27 KBcord1

Comments

n20’s picture

same here, did you solved the problem?

n20’s picture

that worked for me...

$node->field_xml_url['und'][0]['url']               = $xml_remote_url;
$node->field_xml_url['und'][0]['title']             = 'Link';
SilviaT’s picture

Same problem here: in the field configuration I have set Optional URL to YES but still, if I don;t enter a URL the module complains that is missing.

vinmassaro’s picture

Status: Active » Needs review
StatusFileSize
new827 bytes

I am running into this with Feed imports to link fields. If the source does not have a URL, I get this error. Here is a patch that fixes the issue.

nicxvan’s picture

Issue summary: View changes
Status: Needs review » Reviewed & tested by the community

This patch worked for and is very simple can we please commit this?

It just checks that the url is set before trimming it.

  • jcfiala committed 45ecc18 on 7.x-1.x authored by vinmassaro
    Issue #1483494 by vinmassaro, cord1: Notice: Undefined index: url in...
jcfiala’s picture

Status: Reviewed & tested by the community » Fixed

Passes tests, seems harmless enough, and the patch applied cleanly.

Merged into current 7.x-1.x branch.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.