I put what seemed to be a reasonable expression into the include list. I think it was this:

*.domain.co.uk/*

and saved the settings.

(This turned out to be an incorrect pattern and I have the correct one working now.)

After saving, on the configuration page, the fieldset including this setting was then not a link and would not expand, so I could not correct the pattern. The admin menu toolbar also did not display on any pages unless the cache was cleared(???), so there may be several things happening here.

I had to edit the database directlly to remove the pattern.

I did not try anything in the exclude expression field to see if the same issue occurs.

Comments

dbashaw’s picture

Same issue noted after I tried to create an include path consisting of this string:

*\.pdf

I wonder if this may also be related to a conflict with the Admin Menu module. Currently when External Links is active, Admin Menu disappears. I've now removed External Links, and have Admin Menu back.

robert.laszlo’s picture

I believe this is a related issue.

The External Links module seems to break almost all Javascript on our admin pages. The Module Filter doesn't work. The CKEditor doesn't load on our node edit pages. Etc.

If I disable External Links, those things all come back.

I think we must have a bad regular expression in the setting field.

To fix this -- Where is this setting stored in the database? Which table/row? I can't seem to find it.

Thanks.

quicksketch’s picture

In the mean time, just disable JS in your browser and head to admin/settings/extlink and fix the regular expression.

*\.pdf

This is not a valid regular expression. Just use .*\.pdf.

*.domain.co.uk/*

Same. Use .*domain\.co\.uk.*.

quicksketch’s picture

Title: Extlink: Some include expressions disable the configuration interface » Invalid regular expressions (regex) may break the JavaScript on the site

Updating title, we've got a few of these issues out there.

metaface’s picture

subscribing (having same issue)

mototribe’s picture

thank you, that fixed the problem for me too.
It might be useful to include a help page with a few specific examples. The link to javascript examples was a bit too generic for myself.

ar-jan’s picture

Status: Active » Closed (duplicate)

There's a patch that adds checking for valid expressions in #1434104: Validate regexs (to prevent Javascript / regex problem: invalid quantifier), so I'll mark this as duplicate.