Hi @all,

I just found out, that all AJAX behaviors of a view (sorting and pagin) do not work for my view, that is attached to a user profile (the view struct is attache dto this issue... only the blog module should be mandatory to reprodcue the behavior).

The view should display all blog entries of a specific user on its profile page. So I created a profile attachment view using the uid argument... The sorting and pager links work all fine when disabling javascript. but with javascript enabled, the throbber occures after clicking, but after that nothing happens anymore. So I examined the AJAX pager request:

http://localhost/views/ajax?js=1&page=1&view_name=profile_blog&view_disp...

This also looks fine and does not differ from any other AJAX pager request. But it returns the following JSON result:

{ 
  "status": true, 
  "display": "", 
  "title": "Blog entries", 
  "__callbacks": [ "Drupal.Views.Ajax.ajaxViewResponse" ], 
  "messages": "" 
}

You can see that the "display" property is left empty, even though this one should contain all new table rows...

I have several other unattached views running where those problems do not occur, so i think this is a problem produced by the views_attach module, right?

I also tested something where I changed the attachment argument behavior to the [uid] token, which results in working AJAX links, but the view then also showed blog entries by other users...

I'd appreciate any feedback on this, so this might get fixed soon :)

Thanx in advance & cheers

hctom

CommentFileSizeAuthor
view.txt5.67 KBhctom
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jzornig’s picture

I'm also experiencing this issue. I have a number of views attached to user profiles and if I select AJAX the pagers in these views do not work. After some experimentation triggered by the post above, I have changed the views so that the Profile settings: Arguments is now none instead of uid. Then I create a view argument with the following settings:

Action to take if argument is not present: Provide default argument
Default argument type: User ID from URL
Validator: User
Action to take if argument does not validate: Hide view/Page not found (404)

The AJAX pagers in the views now function correctly.

I hope this helps until the bug is identified and fixed.