Sorry for my english, it's bad.
It's missing the word "this" at the line 235 and 262 in ajax.js.
Whitout this "this", a message says : "an error occurred".

CommentFileSizeAuthor
#19 screenshot1.PNG64.1 KBAnonymous (not verified)

Comments

linux.enthusiast768’s picture

I'm facing the same issue. Adding "this" reference as suggested in the bug description seems to take care of the error message. However I wasn't sure about the design intend. Is it O.K to proceed with the above mentioned work around?

Thanks.

merlinofchaos’s picture

I don't see why that should work; $.ajax doesn't require an object. It's just a call.

linux.enthusiast768’s picture

Still getting error when I click on buttons like 'Remove Dsiplay' or 'Preview", even after adding "this" as suggested in the bug.

Please note that the buttons like "Save", "Cancel" and "Delete" seems to work.

merlinofchaos’s picture

You get this in *Preview*?!

That's really strange. I've never seen that.

fab65’s picture

I don't know if it's the design intend when I add "this" reference but after I can edit my view normally. So I think it's a good idea to do that.
I don't know very well javascript thus I can explain why there is need of "this" reference.
After my post, I see others place where miss "this" reference. Maybe the best solution is to achieve a research on all javascript file and replace the string "$." by "$(this)."
After if you have an other idea, I will listen you.

jastern’s picture

i also get this problem, in a multi-site situation where the sites all share the same database tables (no prefix). (It used to be a single-site system. I changed it to a multi-site by adding some VirtualHosts in the httpd.conf, and some sites/ directories with their own settings.php files. I did not get the "An error occurred" problem when it was a single site system. Now I do, but only for the virtual hosts.) When I edit a View and click on one of the "Basic Settings" items, the "An error occurred" message pops up. There is nothing logged in the php log or syslog or httpd error_log.

However, as I say, for the "main" site, i don't have the problem. For the virtualhost sites, i do. All sites use /var/www/html/dru, but the main site's apache DocumentRoot is /var/www/html (so you have to specify "/dru" in the URL for that site; whereas the other sites, which are VirtualHost'ed, use a DocumentRoot of "/var/www/html/dru", so they don't have to specify "/dru" in the URL.).

When I tried making the changes on lines 235 and 262 only (in the sites/all/modules/views/js/ajax.js file), the problem did not go away. However, on a lark, I decided to try to replace all 5 occurrences of "$." with "$(this).", . I no longer get the "An error occurred" message. On the other hand, I did notice that now, there are two differences in behavior:

1) Now the little blue rotating clock/timer icon does not show up, when I click on an item and

2) when I click on a Basic Settings item, the choices for that item no longer appear in the section below, on the same web page. Instead, that section completely redraws and gives me the choices in a new web page.

But at least it "works" now, and I can edit these items.

Here are the changes I made to ajax.js, just FYI

45c45
<     $.extend(Drupal.settings, data.js);
---
>     $(this).extend(Drupal.settings, data.js);
117c117
<       var instance = $.ui.tabs.instances[$('#views-tabset').get(0).UI_TABS_UUID];
---
>       var instance = $(this).ui.tabs.instances[$('#views-tabset').get(0).UI_TABS_UUID];
153c153
<     $.extend(Drupal.settings, data.js);
---
>     $(this).extend(Drupal.settings, data.js);
235c235
<   $.ajax({
---
>   $(this).ajax({
262c262
<     $.ajax({
---
>     $(this).ajax({

hope this helps.. :-)

merlinofchaos’s picture

Ahh, the reason that 'works' is that you're crashing javascript during the click, so the non-javascript click takes over. Since the Views UI degrades 100%, this actually works.

But you have given me some interesting information, and something to test.

merlinofchaos’s picture

jastern, do you use firefox? If so, could you install firebug and enable it on your site that fails.

After you receive the 'an error occurred' message, in the console log that firebug has (hit f12) there should be a POST. I want to know:

1) what URL it posted to
2) what the response was.

andrewlevine’s picture

I tried and failed in reproducing this bug with a new multisite installation in firefox (linux) and also ie, safari (windows)

fab65’s picture

Status: Active » Fixed

The issue is resolve with the new version (views-6.x-2.x-dev) of Views module :

http://ftp.drupal.org/files/projects/views-6.x-2.x-dev.tar.gz

Anonymous’s picture

Status: Fixed » Closed (fixed)

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

jastern’s picture

Status: Closed (fixed) » Active

merlinofchaos,

my apologies for taking so long to respond. i monitored this discussion (and others) for a while each day but for some reason still did not see your response :( .. i'm just now seeing it again as i read over this issue, even though it is closed. i'll try to re-open it, and keep a closer watch on it from now on. (maybe i can figure out how to get the system to mail me when a post is made to the issue?)

anyway, i'll try to answer your question, since i am still getting this error, even though as of today my site is still using the latest development versions of the Views, Date, CCK, and Calendar modules:

Views 6.x-2.x-dev (2008-Jul-09)
Date 6.x-2.x-dev (2008-Jul-10)
Content Construction Kit (CCK) 6.x-2.x-dev (2008-Jul-10)
Calendar 6.x-2.x-dev (2008-Jul-08)

..as well as other, non-development modules. and i've also upgraded to drupal core 6.3.

also, i realize i'm posting about a development version of Views, even though this issue's official Version is "6.x-2.0-beta3", so let me know if you'd like me to post in a separate issue at this point or not.

to recap: when i go to views, add, and add a view (for a node), giving it the name "test_view_name4", for instance, then am taken to the edit page for that view, and i click on the "Add display" button (with "Page" as current choice), i am still getting the popup error message that says,

an error occurred at /admin/build/views/ajax/add-display/test_view_name4

per your 2 requests (plus a 3rd thing i noticed):

1) in my firebug, the URL posted to was:

http://<mysite>/admin/build/views/ajax/add-display/test_view_name4

2) the response was:

{ "tab": { "#views-tab-page_1": { "title": "Page", "body": "\x3cdiv class="clear-block views-display

 views-display-page_1"\x3e\n        \x3cdiv class="remove-display"\x3e\x3cform action="/admin/build/views

/nojs/remove-display/test_view_name4/page_1"  accept-charset="UTF-8" method="post" id="views-ui-remove-display-form"

 class="views-ajax-form"\x3e\n\x3cdiv\x3e\x3cinput type="submit" name="op" id="edit-remove-display" value

="Remove display"  class="form-submit" /\x3e\n\x3cinput type="hidden" name="form_build_id" id="form-87c1c972d4971cad9888d2fe085d5e41"

 value="form-87c1c972d4971cad9888d2fe085d5e41"  /\x3e\n\x3cinput type="hidden" name="form_token" id="edit-views-ui-remove-display-form-form-token"

 value="54115810dd7c4ec664ef8a6a4d6deb81"  /\x3e\n\x3cinput type="hidden" name="form_id" id="edit-views-ui-remove-display-form"

 value="views_ui_remove_display_form"  /\x3e\n\n\x3c/div\x3e\x3c/form\x3e\n\x3c/div\x3e\n    \x3cdiv

 class="top"\x3e\n    \x3cdiv class="inside"\x3e\n      \x3ca href="/help/views/display-page?popup=1"

 class="advanced-help-link" onclick="window.open(this.href, \x26#039;advanced_help_window\x26#039;, 

\x26#039;width=500,height=500,scrollbars,resizable\x26#039;); return false;" title="Page display"\x3e

\x3cspan\x3eHelp\x3c/span\x3e\x3c/a\x3e      \x3cspan class="display-title"\x3e\n        Page      \x3c

/span\x3e\n      \x3cspan class="display-description"\x3e\n        Display the view as a page, with a

 URL and menu links.      \x3c/span\x3e\n    \x3c/div\x3e\n  \x3c/div\x3e\n\n    \x3cdiv class="left

 tab-section"\x3e\n    \x3cdiv class="inside"\x3e\n            \n              \x3cdiv class="views-category"

\x3e\n          \x3cdiv class="views-category-title views-category-basic"\x3e\n            Basic settings

          \x3c/div\x3e\n          \x3cdiv class="views-category-content"\x3e\n                      

    \x3cdiv class="views-item-page-1-display-title"\x3e\n                Name: \x3ca href="/admin/build

/views/nojs/display/test_view_name4/page_1/display_title" class="views-ajax-link " title="Change the

 name of this display."\x3ePage\x3c/a\x3e              \x3c/div\x3e\n                          \x3cdiv

 class="views-item-default-title"\x3e\n                Title: \x3ca href="/admin/build/views/nojs/display

/test_view_name4/page_1/title" class="views-ajax-link " title="Change the title that this display will

 use."\x3eNone\x3c/a\x3e              \x3c/div\x3e\n                          \x3cdiv class="views-item-default-style-plugin"

\x3e\n                \x3ca href="/admin/build/views/nojs/display/test_view_name4/page_1/style_options"

 class="views-ajax-link views-button-configure" title="Change settings for this style"\x3e\x3cspan\x3eChange

 settings for this style\x3c/span\x3e\x3c/a\x3eStyle: \x3ca href="/admin/build/views/nojs/display/test_view_name4

/page_1/style_plugin" class="views-ajax-link " title="Change the style plugin."\x3eUnformatted\x3c/a

\x3e              \x3c/div\x3e\n                          \x3cdiv class="views-item-default-row-plugin"

\x3e\n                \x3ca href="/admin/build/views/nojs/display/test_view_name4/page_1/row_options"

 class="views-ajax-link views-button-configure" title="Change settings for this style"\x3e\x3cspan\x3eChange

 settings for this style\x3c/span\x3e\x3c/a\x3eRow style: \x3ca href="/admin/build/views/nojs/display

/test_view_name4/page_1/row_plugin" class="views-ajax-link " title="Change the row plugin."\x3eFields

\x3c/a\x3e              \x3c/div\x3e\n                          \x3cdiv class="views-item-default-use-ajax"

\x3e\n                Use AJAX: \x3ca href="/admin/build/views/nojs/display/test_view_name4/page_1/use_ajax"

 class="views-ajax-link " title="Change whether or not this display will use AJAX."\x3eNo\x3c/a\x3e 

             \x3c/div\x3e\n                          \x3cdiv class="views-item-default-use-pager"\x3e

\n                Use pager: \x3ca href="/admin/build/views/nojs/display/test_view_name4/page_1/use_pager"

 class="views-ajax-link " title="Change this display\x26#039;s pager setting."\x3eNo\x3c/a\x3e      

        \x3c/div\x3e\n                          \x3cdiv class="views-item-default-items-per-page"\x3e

\n                Items to display: \x3ca href="/admin/build/views/nojs/display/test_view_name4/page_1

/items_per_page" class="views-ajax-link " title="Change how many items to display."\x3e10\x3c/a\x3e 

             \x3c/div\x3e\n                          \x3cdiv class="views-item-default-distinct"\x3e

\n                Distinct: \x3ca href="/admin/build/views/nojs/display/test_view_name4/page_1/distinct"

 class="views-ajax-link " title="Display only distinct items, without duplicates."\x3eNo\x3c/a\x3e  

            \x3c/div\x3e\n                          \x3cdiv class="views-item-default-access"\x3e\n 

               Access: \x3ca href="/admin/build/views/nojs/display/test_view_name4/page_1/access" class

="views-ajax-link " title="Specify access control settings for this display."\x3eUnrestricted\x3c/a\x3e

              \x3c/div\x3e\n                          \x3cdiv class="views-item-default-header"\x3e\n

                Header: \x3ca href="/admin/build/views/nojs/display/test_view_name4/page_1/header" class

="views-ajax-link " title="Change this display\x26#039;s header."\x3eNone\x3c/a\x3e              \x3c

/div\x3e\n                          \x3cdiv class="views-item-default-footer"\x3e\n                Footer

: \x3ca href="/admin/build/views/nojs/display/test_view_name4/page_1/footer" class="views-ajax-link "

 title="Change this display\x26#039;s footer."\x3eNone\x3c/a\x3e              \x3c/div\x3e\n        

                  \x3cdiv class="views-item-default-empty"\x3e\n                Empty text: \x3ca href

="/admin/build/views/nojs/display/test_view_name4/page_1/empty" class="views-ajax-link " title="Change

 this display\x26#039;s empty text."\x3eNone\x3c/a\x3e              \x3c/div\x3e\n                  

        \x3cdiv class="views-item-page-1-analyze-theme"\x3e\n                Theme: \x3ca href="/admin

/build/views/nojs/display/test_view_name4/page_1/analyze-theme" class="views-ajax-link " title="Get information

 on how to theme this display"\x3eInformation\x3c/a\x3e              \x3c/div\x3e\n                 

     \x3c/div\x3e\n        \x3c/div\x3e\n              \x3cdiv class="views-category"\x3e\n         

 \x3cdiv class="views-category-title views-category-page"\x3e\n            Page settings          \x3c

/div\x3e\n          \x3cdiv class="views-category-content"\x3e\n                          \x3cdiv class

="views-item-page-1-path"\x3e\n                Path: \x3ca href="/admin/build/views/nojs/display/test_view_name4

/page_1/path" class="views-ajax-link " title="None"\x3eNone\x3c/a\x3e              \x3c/div\x3e\n   

                       \x3cdiv class="views-item-page-1-menu"\x3e\n                Menu: \x3ca href="

/admin/build/views/nojs/display/test_view_name4/page_1/menu" class="views-ajax-link " title="No menu"

\x3eNo menu\x3c/a\x3e              \x3c/div\x3e\n                      \x3c/div\x3e\n        \x3c/div

\x3e\n          \x3c/div\x3e\n  \x3c/div\x3e\n\n    \x3cdiv class="middle tab-section"\x3e\n    \x3cdiv

 class="inside"\x3e\n      \x3cdiv class="views-category"\x3e\n        \x3ca href="/admin/build/views

/nojs/rearrange/test_view_name4/page_1/relationship" class="views-button-rearrange views-ajax-link" title

="Rearrange"\x3e\x3cspan\x3eRearrange\x3c/span\x3e\x3c/a\x3e\x3ca href="/admin/build/views/nojs/add-item

/test_view_name4/page_1/relationship" class="views-button-add views-ajax-link" title="Add"\x3e\x3cspan

\x3eAdd\x3c/span\x3e\x3c/a\x3e\x3cdiv class="views-category-title"\x3e\n  \x3ca href="/help/views/relationship

?popup=1" class="advanced-help-link" onclick="window.open(this.href, \x26#039;advanced_help_window\x26

#039;, \x26#039;width=500,height=500,scrollbars,resizable\x26#039;); return false;" title="Relationships"

\x3e\x3cspan\x3eHelp\x3c/span\x3e\x3c/a\x3e  \x3ca href="/admin/build/views/nojs/config-type/test_view_name4

/page_1/relationship" class="views-ajax-link"\x3eRelationships\x3c/a\x3e\x3c/div\x3e\n\n\x3cdiv class

="views-category-content"\x3e\n      \x3cdiv\x3eNone defined\x3c/div\x3e\n  \x3c/div\x3e\n      \x3c

/div\x3e\n      \x3cdiv class="views-category"\x3e\n        \x3ca href="/admin/build/views/nojs/rearrange

/test_view_name4/page_1/argument" class="views-button-rearrange views-ajax-link" title="Rearrange"\x3e

\x3cspan\x3eRearrange\x3c/span\x3e\x3c/a\x3e\x3ca href="/admin/build/views/nojs/add-item/test_view_name4

/page_1/argument" class="views-button-add views-ajax-link" title="Add"\x3e\x3cspan\x3eAdd\x3c/span\x3e

\x3c/a\x3e\x3cdiv class="views-category-title"\x3e\n  \x3ca href="/help/views/argument?popup=1" class

="advanced-help-link" onclick="window.open(this.href, \x26#039;advanced_help_window\x26#039;, \x26#039

;width=500,height=500,scrollbars,resizable\x26#039;); return false;" title="Arguments"\x3e\x3cspan\x3eHelp

\x3c/span\x3e\x3c/a\x3e  \x3ca href="/admin/build/views/nojs/config-type/test_view_name4/page_1/argument"

 class="views-ajax-link"\x3eArguments\x3c/a\x3e\x3c/div\x3e\n\n\x3cdiv class="views-category-content"

\x3e\n      \x3cdiv\x3eNone defined\x3c/div\x3e\n  \x3c/div\x3e\n      \x3c/div\x3e\n              \x3cdiv

 class="views-category"\x3e\n          \x3ca href="/admin/build/views/nojs/rearrange/test_view_name4

/page_1/field" class="views-button-rearrange views-ajax-link" title="Rearrange"\x3e\x3cspan\x3eRearrange

\x3c/span\x3e\x3c/a\x3e\x3ca href="/admin/build/views/nojs/add-item/test_view_name4/page_1/field" class

="views-button-add views-ajax-link" title="Add"\x3e\x3cspan\x3eAdd\x3c/span\x3e\x3c/a\x3e\x3cdiv class

="views-category-title"\x3e\n  \x3ca href="/help/views/field?popup=1" class="advanced-help-link" onclick

="window.open(this.href, \x26#039;advanced_help_window\x26#039;, \x26#039;width=500,height=500,scrollbars

,resizable\x26#039;); return false;" title="Fields"\x3e\x3cspan\x3eHelp\x3c/span\x3e\x3c/a\x3e  \x3ca

 href="/admin/build/views/nojs/config-type/test_view_name4/page_1/field" class="views-ajax-link"\x3eFields

\x3c/a\x3e\x3c/div\x3e\n\n\x3cdiv class="views-category-content"\x3e\n      \x3cdiv\x3eNone defined\x3c

/div\x3e\n  \x3c/div\x3e\n        \x3c/div\x3e\n          \x3c/div\x3e\n  \x3c/div\x3e\n\n    \x3cdiv

 class="right tab-section"\x3e\n    \x3cdiv class="inside"\x3e\n      \x3cdiv class="views-category"

\x3e\n        \x3ca href="/admin/build/views/nojs/rearrange/test_view_name4/page_1/sort" class="views-button-rearrange

 views-ajax-link" title="Rearrange"\x3e\x3cspan\x3eRearrange\x3c/span\x3e\x3c/a\x3e\x3ca href="/admin

/build/views/nojs/add-item/test_view_name4/page_1/sort" class="views-button-add views-ajax-link" title

="Add"\x3e\x3cspan\x3eAdd\x3c/span\x3e\x3c/a\x3e\x3cdiv class="views-category-title"\x3e\n  \x3ca href

="/help/views/sort?popup=1" class="advanced-help-link" onclick="window.open(this.href, \x26#039;advanced_help_window

\x26#039;, \x26#039;width=500,height=500,scrollbars,resizable\x26#039;); return false;" title="Sorts"

\x3e\x3cspan\x3eHelp\x3c/span\x3e\x3c/a\x3e  \x3ca href="/admin/build/views/nojs/config-type/test_view_name4

/page_1/sort" class="views-ajax-link"\x3eSort criteria\x3c/a\x3e\x3c/div\x3e\n\n\x3cdiv class="views-category-content"

\x3e\n      \x3cdiv\x3eNone defined\x3c/div\x3e\n  \x3c/div\x3e\n      \x3c/div\x3e\n      \x3cdiv class

="views-category"\x3e\n        \x3ca href="/admin/build/views/nojs/rearrange/test_view_name4/page_1/filter"

 class="views-button-rearrange views-ajax-link" title="Rearrange"\x3e\x3cspan\x3eRearrange\x3c/span\x3e

\x3c/a\x3e\x3ca href="/admin/build/views/nojs/add-item/test_view_name4/page_1/filter" class="views-button-add

 views-ajax-link" title="Add"\x3e\x3cspan\x3eAdd\x3c/span\x3e\x3c/a\x3e\x3cdiv class="views-category-title"

\x3e\n  \x3ca href="/help/views/filter?popup=1" class="advanced-help-link" onclick="window.open(this

.href, \x26#039;advanced_help_window\x26#039;, \x26#039;width=500,height=500,scrollbars,resizable\x26

#039;); return false;" title="Filters"\x3e\x3cspan\x3eHelp\x3c/span\x3e\x3c/a\x3e  \x3ca href="/admin

/build/views/nojs/config-type/test_view_name4/page_1/filter" class="views-ajax-link"\x3eFilters\x3c/a

\x3e\x3c/div\x3e\n\n\x3cdiv class="views-category-content"\x3e\n      \x3cdiv\x3eNone defined\x3c/div

\x3e\n  \x3c/div\x3e\n      \x3c/div\x3e\n    \x3c/div\x3e\n  \x3c/div\x3e\n\n\x3c/div\x3e" } } }

3) also, i do see a javascript bug listed in the firebug console, which says:

missing } after property list

for test_view_name4 (line 46), and when i click on the link to that bug, it takes me to the following lines on the page:

<script type="text/javascript" src="/misc/collapse.js?n"></script>
42<script type="text/javascript" src="/misc/textarea.js?n"></script>
43<script type="text/javascript" src="/misc/tabledrag.js?n"></script>
44<script type="text/javascript" src="/misc/autocomplete.js?n"></script>
45<script type="text/javascript" src="/sites/all/modules/views/js/dependent.js?n"></script>
46<script type="text/javascript">jQuery.extend(Drupal.settings, { "basePath": "/", "views": { "ajax": { "id": "#views-ajax-pad", "title": "#views-ajax-title", "defaultForm": "\x3cdiv class="message"\x3eClick on an item to edit that item''s details.\x3c/div\x3e" } } });</script>
47 <!--[if lt IE 7]>
48 <link type="text/css" rel="stylesheet" media="all" href="/themes/garland/fix-ie.css" /> <![endif]-->
49 </head>
50 <body class="sidebar-left">
51
52<!-- Layout -->

does that help at all?

thanks again,
jeff

jastern’s picture

Version: 6.x-2.0-beta3 » 6.x-2.x-dev

haven't seen any activity on this issue since i last posted almost a couple of weeks ago, so i'm not sure why that is.. there also doesn't seem to be any way to contact the developers directly (that i can see), to get their attention, so i guess i'll try changing the "Version" of views this issue applies to, and see if that bumps it up into being seen and responded to..

fyi, i just updated all my site's dev modules (Views, CCK, Calendar, Date) today, to their latest versions:

Calendar 6.x-2.x-dev (2008-Jul-22)
Content Construction Kit (CCK) 6.x-2.x-dev (2008-Jul-16)
Date 6.x-2.x-dev (2008-Jul-22)
Views 6.x-2.x-dev (2008-Jul-22)

and i still get this error. Ajax is thus still not working for me.

merlinofchaos’s picture

I don't know why, but the quotes in that response from Views are not escaped correctly, turning the javascript invalid. This escaping is done by Drupal itself.

What PHP version are you running? And what Drupal version?

jastern’s picture

mm.. thanks for getting back, merlinofchaos... much appreciated.. your question reminded me that i had posted the most recent comment on this issue, but forgotten that i had found a solution in another context (see my comment #4 in #289120: Add magic_quotes_sybase = 0 to .htaccess (was: ajax features not working from a non-default multi-site site)).

the solution to both issues (the ajax features bombing out and also the quotes not being escaped correctly in the response from Views) is that "magic_quotes_sybase" has to be set to "0" in the <DRUPALDIR>/.htaccess file -- but it is not, in the released version of Drupal 6.x (at least as of today).

of course, these issues would pop up only for people who are altering their php.ini to have magic_quotes_sybase set to 1 (a non-default setting), on systems which they *also* use to access an Interbase, Sybase, or other single-quote-based database system. therefore, for everyone else, since the php.ini, as distributed with PHP, has magic_quotes_sybase set to 0 *anyway*, it's not going to make a difference. this would only need to be done so that the minority of people who have set magic_quotes_sybase to 1 elsewhere on their system have it set back to 0 when drupal runs.

therefore, it looks like a simple patch to the distributed <DRUPALDIR>/.htaccess would be in order, here, just to add in those lines to set "magic_quotes_sybase" correctly to 0. however, i did not submit a patch over in that issue, because i didn't know if it was intended to leave it out, since i am a Drupal newbie.

so i am still waiting on an answer in that issue (originally posted early august -- i just updated some minor text errors today), as to whether a patch for this additional setting would be a good idea.

merlinofchaos’s picture

jastern: Thanks a lot for that explanation. That's a very handy piece of information to have.

Anonymous’s picture

I'm working with Drupal6.4 and I've tried the dev and rc2 of Views without luck. I get this same error message ("An error occurred at /admin/build/views/ajax/analyze/archive"), but I don't know what's causing it. I added the magic_quotes_sybase to my .htaccess, and my apache error log doesn't indicate anything gone wrong. I'm new to Drupal, but I really would like to get Views working. Anybody got any suggestions for other things I can try?
Thanks,
nb

merlinofchaos’s picture

If possible, can you use firebug and cut & paste the POST response when this happens?

Anonymous’s picture

StatusFileSize
new64.1 KB

here's what I got - I think this is what you were asking for:

{ "display": "\x3cspan id=\"thmr_10\" class=\"thmr_call\"\x3e\n  \x3cform action=\"/admin/build/views

/ajax/config-type/archive/default/argument\"  accept-charset=\"UTF-8\" method=\"post\" id=\"views-ui-config-type-form

\"\x3e\n\x3cdiv\x3e\x3cdiv class=\"clear-block\"\x3e\x3cdiv class=\"form-buttons\"\x3e\x3cspan id=\"thmr_5

\" class=\"thmr_call\"\x3e\n  \x3cspan id=\"thmr_1\" class=\"thmr_call\"\x3e\n  \x3cspan id=\"thmr_2

\" class=\"thmr_call\"\x3e\n  \x3cinput type=\"submit\" name=\"op\" id=\"edit-submit\" value=\"Update

\"  class=\"form-submit\" /\x3e\n\x3c/span\x3e\n\n\x3c/span\x3e\n\n\x3cspan id=\"thmr_3\" class=\"thmr_call

\"\x3e\n  \x3cspan id=\"thmr_4\" class=\"thmr_call\"\x3e\n  \x3cinput type=\"submit\" name=\"op\" id

=\"edit-cancel\" value=\"Cancel\"  class=\"form-submit\" /\x3e\n\x3c/span\x3e\n\n\x3c/span\x3e\n\n\x3c

/span\x3e\n\n\x3c/div\x3e\x3c/div\x3e\x3cinput type=\"hidden\" name=\"form_build_id\" id=\"form-f2c14329469b49dd45eb7a8acc7f255e

\" value=\"form-f2c14329469b49dd45eb7a8acc7f255e\"  /\x3e\n\x3cspan id=\"thmr_7\" class=\"thmr_call\"

\x3e\n  \x3cinput type=\"hidden\" name=\"form_token\" id=\"edit-views-ui-config-type-form-form-token

\" value=\"0f18e58f6da65d710a15bb571f565d0d\"  /\x3e\n\x3c/span\x3e\n\n\x3cinput type=\"hidden\" name

=\"form_id\" id=\"edit-views-ui-config-type-form\" value=\"views_ui_config_type_form\"  /\x3e\n\n\x3c

/div\x3e\x3c/form\x3e\n\x3c/span\x3e\n\n", "title": "Defaults: Configure arguments", "url": "https:/

/www.squarewheeldesigns.com/admin/build/views/ajax/config-type/archive/default/argument", "js": null

, "hilite": ".views-item-defaultconfig-item" }<span id="thmr_12" class="thmr_call">

  <table class="sticky-enabled">

 <thead><tr><th>Duration (ms)</th><th>Template/Function</th><th>Candidate template files or function

 names</th> </tr></thead>

<tbody>

 <tr class="odd"><td>0.11</td><td><div id="devel_theme_log_link_thmr_2" class="devel_theme_log_link"

></div>

theme_button()</td><td></td> </tr>

 <tr class="even"><td>0.45</td><td><div id="devel_theme_log_link_thmr_1" class="devel_theme_log_link"

></div>

theme_submit()</td><td></td> </tr>

 <tr class="odd"><td>0.07</td><td><div id="devel_theme_log_link_thmr_4" class="devel_theme_log_link"

></div>

theme_button()</td><td></td> </tr>

 <tr class="even"><td>0.22</td><td><div id="devel_theme_log_link_thmr_3" class="devel_theme_log_link"

></div>

theme_submit()</td><td></td> </tr>

 <tr class="odd"><td>0.05</td><td><div id="devel_theme_log_link_thmr_5" class="devel_theme_log_link"

></div>

theme_markup()</td><td></td> </tr>

 <tr class="even"><td>0.18</td><td><div id="devel_theme_log_link_thmr_7" class="devel_theme_log_link"

></div>

theme_token()</td><td></td> </tr>

 <tr class="odd"><td>0.09</td><td><div id="devel_theme_log_link_thmr_10" class="devel_theme_log_link"

></div>

theme_form()</td><td></td> </tr>

</tbody>

</table>

</span>

I got an error, as shown in the screenshot1.png, but I think it's unrelated.
nb

merlinofchaos’s picture

nedbrush: Your error seems to be because devel.module information is getting attached. This shouldn't be happening, but I do recall that it used ot happen with very old versions of devel.module. Try updating and/or disabling devel.

Anonymous’s picture

merlinofchaos: I got it to work by turning off the devel.module. I wasn't expecting that to be a problem. It's a little clunky to switch off the devel, but as long as it works I'm happy. I really appreciate your help.

merlinofchaos’s picture

I use devel.module all the time, so there's something definitely wrong there; be sure you're using the actual latest devel as it hasn't had that bug in many months.

Anonymous’s picture

I tried all four combinations of devel.module (both 6.x-1.11 and 6.x-1.x-dev) and views (6.x-2.0-rc3 and 6.x-2.x-dev) without luck. They all give the same error. For now, I'm going to stick to turning off the devel.module when I need views. I wonder if it's another module getting in the way? I imagine a lot of people use both the devel and views module, and it seems like I'm one of the few seeing the problem.

merlinofchaos’s picture

Status: Active » Fixed

It might be, if for some reason something else is changing the header that devel looks at to see if it should not add text. Either way, it's now devel's problem, since Views IS doing the right thing here.

wmostrey’s picture

Version: 6.x-2.x-dev » 6.x-2.0-rc4
Assigned: fab65 » Unassigned
Status: Fixed » Active

For me it's not completely fixed in 6.x-2.0-rc4, the same error still appears.

However, when I apply "this" at the line 235 and 262 in ajax.js then it is working as if javascript was disabled, so I get redirect to a separate page instead of seeing the inline configuration screen. This is definitely an improvement as to when I was getting the error (since then views ui was unusable). So to confirm this: after upgrading to 6.x-2.0-rc4 I didn't see any improvement in this error, and I don't have the devel module installed.

merlinofchaos’s picture

The reason that works as if javascript is disabled is because it crashes. You can disable the javascript at admin >> build >> views >> tools and not actually break the code to do it.

Did you check out #15? That's the important comment in this thread, to me.

merlinofchaos’s picture

Seriously though, if it works for you on one server but not another, chances are 99.44% that it's a server config issue.

merlinofchaos’s picture

I realize, rereading my statement, that I wasn't clear. By 'it crashes', I mean the javascript actually crashes. When the js crashes, the links revert to their normal, non-js state, and the UI works nicely. It has to crash fairly early for this to happen; a crash late in the process could already have changed some stuff around so that the links try to work with js and can't. That gets ugly.

When debugging this, the most critical tool is using firebug and watching the POST response, and seeing what javascript thinks of the response. If the server is reporting an error you'll usually get a Drupal HTML page which the javascript can't parse. If it looks like a proper JSON response, it's possible that it's mangled (see the sybase quotes post above) by the server.

wmostrey’s picture

I did check #15 but magic_quotes_sybase is set to 0 by default on the server. To double-check I also updated .htaccess with this php_value but that didn't change things. I'll try to provide POST information but since Firebug seems to need to do a re-POST of the information I'm not getting a valid response. I'll see what I can do.

I agree that this is a server configuration but in my opinion it's something that needs to be documented. Many people with shared hosting might run into this issue and it will save everyone a lot of time if you can just say "Hey, that's because of setting x. If you can't change it, just disable the javascript functionality".

I'll try to bring proper results.

merlinofchaos’s picture

If you're not getting a valid response from firefox, that may indeed be what the server is sending. It's hard to say; firebug for FF2 never did that, and it confuses me greatly. I'm guessing FF3 changed in such a way that firebug is no longer able to spy on the actual POST, so it needs to POST again to get the response. :/

wmostrey’s picture

I can not provide you with any more information than I did in the other thread. Feel free to close this ticket until someone can provide more information.

So in short: my solution for the "an error occurred" issue was to disable javascript for views so I can still do configuration without the pop-ups.

fab65’s picture

Status: Active » Fixed
aczook’s picture

for what it is worth, the fix posted #1 by linux.enthusiast768 did the trick for me.

Status: Fixed » Closed (fixed)

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