See the attached screenshot - giving anonymous users the ability to create content with more than one text format available to them results in the filter tips for both formats to be shown at once (although the javascript that hides all but the selected one does appear to be loaded), and also a funny box underneath the text format widget.

This problem appears in both Garland and Seven. I suspect the funny box underneath the widget is actually an empty version of the vertical tabs that would normally appear there.

CommentFileSizeAuthor
text_format_widget.png57.67 KBDavid_Rothstein
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

sun’s picture

Component: filter.module » forms system

Not caused by filter.module.

The vertical tabs widget is unconditionally added, even if the user does not have access to any tab in the group.

jp.stacey’s picture

@sun, despite this point, do you think getting this in for the code freeze is dependent on http://drupal.org/node/558666 ? If so, is 555866 going in? If that does not go in, then can we wontfix this bug?

I have put this down as a possible suggestion for the Saturday code sprint but maybe we need some guidance on what we should spend our energy tackling, to make sure we do the best for Drupal.

David_Rothstein’s picture

Since this is a bug, there is no reason it must be fixed before code freeze. It can be fixed afterwards as well.

(And I'm not sure how this is related to #558666: UX/security: Revamp text format/filter configuration? That issue is about the text format administration pages, and this bug occurs only on places where text formats are used - e.g., the node form.)

Also, I think this is actually two bug reports mixed into one. The vertical tabs issue seems to be a general issue with the forms system. The text format widget issue seems unrelated, unless it's the empty vertical tabs area that's somehow messing it up and causing it to display all the formats?

jp.stacey’s picture

Component: forms system » filter.module

@david_rothstein you're right about 558666 - my bad. I know bugs can be fixed before code freeze but I wasn't sure if the bug was dependent on as-yet unconfirmed functionality: so maybe it wasn't worth working on the bug. If the better text formats use situations (e.g. as you say on node forms) then yeah this bug is a bug :)

So this issue's main bug is:

  • if anonymous users can add content
  • and they're able to add content in multiple formats
  • then the help text for all formats, not just the one they picked, appears under the select box

? I've spun the vertical tabs box off to http://drupal.org/node/567224 and moved this bug back to the filter.module

sun’s picture

Status: Active » Postponed (maintainer needs more info)

Is this still an issue?

jp.stacey’s picture

Just downloaded the alpha2 and I can't repeat. Method:

  • Install
  • Visit website as admin user (browser used: Firefox on Linux)
    • Set all permissions for anonymous user to true
  • Visit website as anonymous user (browser used: Chrome on Linux)
    • Click add content
    • In lightbox, "Add article"
    • In article, check below "Body"
    • Input formats label and dropdown exist, but only documentation for current input format is shown

Suggest issue is closed?

David_Rothstein’s picture

Title: Text format widget broken for anonymous users » Text format widget broken for users who have an empty vertical tabs section
Status: Postponed (maintainer needs more info) » Active

This is still an issue - although turns out it is not limited to anonymous users. And interestingly, it seems that the two original issues I reported are related after all...

To reproduce, just give "create new article content" permission, nothing else beyond the defaults that come with the standard install profile. Then give "create and edit URL aliases" to the same user, which puts something in the vertical tabs section - the text format problem goes away then too.

David_Rothstein’s picture

Not sure why I didn't think to check Firebug before, but here's the JavaScript error:

focus.data("verticalTab") is undefined

This is on line 44 of vertical-tabs.js. So actually, this might be a duplicate of the main form system vertical tabs issue after all (if there's an issue for that)... Presumably this error just stops all JavaScript on the page from working, including the text format stuff.

sun’s picture

Status: Active » Closed (duplicate)

This bug gets already fixed in #679530: administer filters permission should not affect text format widget, and as that issue/patch is very close to RTBC, I'm marking this issue as duplicate.