Hi.
I've been using vt_default to create clean, more simple-looking node-forms but I ran into a problem when I tried to use insert with it. If an insert-enabled field (tried it with imagefield) it seems that FireFox won't let it insert stuff into the body field because the body field is in a div that's set to display:none; (the default tab that is hidden that way when viewing other tabs). However it works fine in Safari (haven't tried it in other browsers yet). Any ideas on how this could be solved?
If this can be solved it would also be nice if tabs were automatically switched (to the one containing the insert-target) when you click insert. That way you wouldn't have to click the tab cotaining the target to see the results.
I don't know how many people are using this method, inserting into fields in vertical tabs but I really like both modules and would love to be able to use them together.
Comment | File | Size | Author |
---|---|---|---|
#7 | insert_vertical_tab_active.patch | 2.99 KB | quicksketch |
Comments
Comment #1
Einkahumor CreditAttribution: Einkahumor commentedI just tested this a little more and found out that this is also a problem with IE 8 but not with Google Chrome (no surprise there since it works in Safari). Iv'e also had reports that this is a problem in FF on Windows (all my tests are on a Mac).
Comment #2
quicksketchHm, this sounds like it would be a problem with any textarea that's placed within a Vertical Tab. Are you using any WYSIWYGs on your site? That may also have an effect. It may very well be that some browsers don't allow you to change the content of textareas that are currently not visible to the user as a privacy/security feature.
Comment #3
Einkahumor CreditAttribution: Einkahumor commentedYup, I think this would be a problem with all textareas in Vertical Tabs. I'm using the Wysiwyg module and CKEditor but switching to another input format (thus switching off CKEditor) doesn't seem to change anything, FF and IE still won't let me insert anything into a textarea that's in a hidden Vertical Tab. Can you think of a way around this?
Comment #4
Einkahumor CreditAttribution: Einkahumor commentedI should add that I have tried changing display:none to display:block on the tab-pane that contains the insert-target-textarea via firebug and then insert works just fine on FF. I see this as a confirmation that the display:none div around the target is the problem. However, I'm just a themer and I have absolutely no idea if this can be solved or how.
Comment #5
quicksketchThe best approach I can think of is just activate the tab that contains the textarea before doing the insert. Of course done through JavaScript this would be so fast the user couldn't tell that the tab is activated first and then the content is inserted afterward. Basically I think using your suggestion to activate the tab would effectively solve the problem of inserting into a hidden textarea.
Comment #6
Einkahumor CreditAttribution: Einkahumor commentedGood thinking. I'll see if I can get something working. Any help would be greatly appreciated since I know almost nothing about javascript or php but of course I know you guys are pretty busy. Thanks for the help so far, great module btw.
Comment #7
quicksketchThis patch should correct the problem by activating the Vertical Tab that contains the editor if it is currently hidden. I've tested it with FCKeditor, tinyMCE, CKeditor, and plain textareas. It seems to work in all of them just fine. I've committed this to both branches and it will be in the next beta.
Comment #8
Einkahumor CreditAttribution: Einkahumor commentedWorks for me with CKEditor, this is awesome! Thanks a lot man.