I am working with webform 6.x-3.6, arrange fields 6.x-1.4, jQuery UI 6.x-1.4 and the 1.6 plugin installed on a 6.19 core. after making all of my changes i use the "save position data" button and once the position data is saved it looks as i planned it. however, if i return to the arrange fields tab and re-open it to make any further changes, all of my text input areas reduce their vertical height by themselves. this height reduction makes it impossible to see what a person is typing. if i manually call out the dimensions of width and height it appears as if the placement box itself responds but definitely not the input field. it requires me to reposition all of my fields again from scratch. i am including this web address for you to see what visually happens after i have re-entered the arrange fields tab without applying any new changes. http://www.uwsfc.org/letterwritingcampaign

Comments

richardp’s picture

Hmm. Interesting. The module is definitely saving that the height is set to simply "0px". So, I am led to believe that this is the value actually returned by jQuery and then saved by the module. See, to get the height I just make a simple: height = $(test).height(); call on the element itself.

Does this happen in other browsers?

Have you tried clicking the "reset field positions" button, and then starting over? Clicking that button will actually delete all saved data on the form from the database's variable table. My thinking is that perhaps somewhere along the way those heights got improperly set, but then refuse to change when you go back and re-save the positions. If this is the case, you need to clear it out of the database entirely with the reset field positions button.

Also, just for fun, I usually clear the cache when any unusual problem happens. Have you done that recently, then tried resetting and re-saving the form?

Richard

fndtn357’s picture

I have been using two different browsers Firefox v3.6.11 and Chromium 7.0.521.0. This behavior happens with both browsers. During my investigation so far I have cleared both the website cache and the browser caches to see if that would clear up the problem. I have also reset and re-saved many times.

When I check the variables table after my initial drag and drop:

s:874:"edit-letter-draggable-wrapper,0px,0px,,0px,0px,275px,475px,,top,;edit-closing-draggable-wrapper,620px,0px,,0px,0px,;edit-myinfo-draggable-wrapper,110px,340px,,0px,0px,;edit-first-name-draggable-wrapper,170px,340px,input,162px,12px,275px,30px,,top,;edit-last-name-draggable-wrapper,250px,340px,input,162px,12px,275px,30px,,top,;edit-address-1-draggable-wrapper,320px,340px,input,162px,12px,275px,30px,,top,;edit-address-2-draggable-wrapper,390px,340px,input,162px,12px,275px,30px,,top,;edit-city-draggable-wrapper,460px,340px,input,162px,12px,275px,30px,,top,;edit-state-province-draggable-wrapper,530px,340px,,0px,0px,275px,30px,,top,;edit-zip-postal-code-draggable-wrapper,600px,340px,input,162px,12px,275px,30px,,top,;edit-email-address-draggable-wrapper,670px,340px,input,162px,12px,275px,30px,,top,;edit-submit-draggable-wrapper,760px,400px,,0px,0px,;~~maxBottom~~,796px";

After re-opening the arrange fields tab and dragging into new locations but not manipulating anything else, these are the new variables:

s:877:"edit-letter-draggable-wrapper,0px,0px,,0px,0px,275px,475px,,top,;edit-closing-draggable-wrapper,520px,0px,,0px,0px,,,,,;edit-myinfo-draggable-wrapper,30px,340px,,0px,0px,,,,,;edit-first-name-draggable-wrapper,90px,340px,input,146px,0px,275px,30px,,top,;edit-last-name-draggable-wrapper,150px,340px,input,146px,0px,275px,30px,,top,;edit-address-1-draggable-wrapper,210px,340px,input,146px,0px,275px,30px,,top,;edit-address-2-draggable-wrapper,270px,340px,input,146px,0px,275px,30px,,top,;edit-city-draggable-wrapper,330px,340px,input,146px,0px,275px,30px,,top,;edit-state-province-draggable-wrapper,390px,340px,,0px,0px,275px,30px,,top,;edit-zip-postal-code-draggable-wrapper,460px,340px,input,146px,0px,275px,30px,,top,;edit-email-address-draggable-wrapper,520px,340px,input,146px,0px,275px,30px,,top,;edit-submit-draggable-wrapper,590px,390px,,0px,0px,,,,,;~~maxBottom~~,626px";

richardp’s picture

That's so weird. Because clearly the heights *are* being saved correctly initially, but then get turned into 0px the next time you re-open the form. As I said earlier, the heights are taken from jQuery functions, so I am not sure what if anything I could do in my module. The best theory I can think of is that you might have something installed on your site which, for whatever reason, is interfering or just interacting with jQuery, and it is enough to throw off that .height() function. Can you think of any additional modules you've installed that might have something to do with jQuery?

I suppose it might also be possible that something in your theme's CSS could cause the .height() function to get the wrong value, but honestly I do not know for sure if that's how jQuery works.

Have you tried switching to a different theme, like simply Garland, to see if it does the same thing there?

Richard

fndtn357’s picture

The administration theme I was using was Rubik. With Garland enabled I can see a new formatting tool called "add markup" - nice! Also, the message "You may resize text fields by dragging the right side of the field." makes quite a bit more sense. So, I used Garland, as you suggested, to make all the changes and saved those changes. Then I returned and re-opened the "arrange field" tab and made new changes and finally, everything saves without changing anything else.
This is probably an issue I should add to the Rubik queue, although I don't know how to properly explain what the problem is.

I've learned a lot from this

  • always use the Garland theme for troubleshooting Drupal 6 version modules
  • talk to the module maintainer for insight
  • don't put off asking questions when stuck

Thanks for all your help. I really appreciate it. Now I can move on to other issues ;)

richardp’s picture

Status: Active » Fixed

I'm just glad you got it working!

That is odd about the Rubik theme. I have never installed it, but I do know that Arrange Fields is very sensitive to other javascript running on the page; perhaps that theme does something like that. The fact that you were actually missing buttons and markup from the page is quite odd indeed!

There is a module called Sections, which lets you define a theme on a per-url basis. Perhaps you can use that module to say that any time "arrange-fields" is in the URL, use Garland. That might make it easier for you than having to switch back and forth.

At any rate, it's always a happy ending when an issue is resolved (or at least when a workaround is figured out).

Good luck!
Richard

Status: Fixed » Closed (fixed)

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