Skip to main content
added 242 characters in body
Source Link
Cyclonecode
  • 3.4k
  • 31
  • 47

I tried the following and it seems to work:

  1. Create a new block view
  2. Add a Contextual filter of type Content: Nid
  3. Add a relationship of type Content: Author (Required)
  4. Add a relationship of type User: Content authored that uses the previous relationship and is required
  5. Under Format you set Show: Content | Full Content - You must also use the User: Content authored relationship for this one

You could also change the number of related nodes that will be shown and also you might wan't to add a filter of Content: Type to restrict what kind of nodes to display. Notice that you could create a template for a specific content-type ie node--<YOUR_CONTENT_TYPE>.tpl and load and execute the view from there.

In you node.tpl file you would load this view doing something similar to:

$view = views_get_view('YOUR_VIEW_NAME');
$view->set_display('YOUR_VIEW_BLOCK_NAME');
$view->set_arguments(array($node->nid));
$view->execute();
echo $view->render();

Note I think you should specify every field you wan't to use, in other words you shouldn't use Show: Content | Full Content - because this will result in an infinite loop. I don't think this is a complete solution, but perhaps it will point you in the right direction.

If you are using fields in the view you could create a separate template named views-view-fields--YOUR_VIEW_NAME--YOUR_VIEW_BLOCK_NAME.tpl that will be used to output the actual fields.

To exclude the current node from the listing you need to modify your contextual filter.

  • Click the More button for Content: Nid and choose exclude you should also make this filter use your relationship for Content: Authored

I tried the following and it seems to work:

  1. Create a new block view
  2. Add a Contextual filter of type Content: Nid
  3. Add a relationship of type Content: Author (Required)
  4. Add a relationship of type User: Content authored that uses the previous relationship and is required
  5. Under Format you set Show: Content | Full Content - You must also use the User: Content authored relationship for this one

You could also change the number of related nodes that will be shown and also you might wan't to add a filter of Content: Type to restrict what kind of nodes to display. Notice that you could create a template for a specific content-type ie node--<YOUR_CONTENT_TYPE>.tpl and load and execute the view from there.

In you node.tpl file you would load this view doing something similar to:

$view = views_get_view('YOUR_VIEW_NAME');
$view->set_display('YOUR_VIEW_BLOCK_NAME');
$view->set_arguments(array($node->nid));
$view->execute();
echo $view->render();

Note I think you should specify every field you wan't to use, in other words you shouldn't use Show: Content | Full Content - because this will result in an infinite loop. I don't think this is a complete solution, but perhaps it will point you in the right direction.

If you are using fields in the view you could create a separate template named views-view-fields--YOUR_VIEW_NAME--YOUR_VIEW_BLOCK_NAME.tpl that will be used to output the actual fields.

I tried the following and it seems to work:

  1. Create a new block view
  2. Add a Contextual filter of type Content: Nid
  3. Add a relationship of type Content: Author (Required)
  4. Add a relationship of type User: Content authored that uses the previous relationship and is required
  5. Under Format you set Show: Content | Full Content - You must also use the User: Content authored relationship for this one

You could also change the number of related nodes that will be shown and also you might wan't to add a filter of Content: Type to restrict what kind of nodes to display. Notice that you could create a template for a specific content-type ie node--<YOUR_CONTENT_TYPE>.tpl and load and execute the view from there.

In you node.tpl file you would load this view doing something similar to:

$view = views_get_view('YOUR_VIEW_NAME');
$view->set_display('YOUR_VIEW_BLOCK_NAME');
$view->set_arguments(array($node->nid));
$view->execute();
echo $view->render();

Note I think you should specify every field you wan't to use, in other words you shouldn't use Show: Content | Full Content - because this will result in an infinite loop. I don't think this is a complete solution, but perhaps it will point you in the right direction.

If you are using fields in the view you could create a separate template named views-view-fields--YOUR_VIEW_NAME--YOUR_VIEW_BLOCK_NAME.tpl that will be used to output the actual fields.

To exclude the current node from the listing you need to modify your contextual filter.

  • Click the More button for Content: Nid and choose exclude you should also make this filter use your relationship for Content: Authored
added 191 characters in body
Source Link
Cyclonecode
  • 3.4k
  • 31
  • 47

I tried the following and it seems to work:

  1. Create a new block view
  2. Add a Contextual filter of type Content: Nid
  3. Add a relationship of type Content: Author (Required)
  4. Add a relationship of type User: Content authored that uses the previous relationship and is required
  5. Under Format you set Show: Content | Full Content - You must also use the User: Content authored relationship for this one

You could also change the number of related nodes that will be shown and also you might wan't to add a filter of Content: Type to restrict what kind of nodes to display. Notice that you could create a template for a specific content-type ie node--<YOUR_CONTENT_TYPE>.tpl and load and execute the view from there.

In you node.tpl file you would load this view doing something similar to:

$view = views_get_view('YOUR_VIEW_NAME');
$view->set_display('YOUR_VIEW_BLOCK_NAME');
$view->set_arguments(array($node->nid));
$view->execute();
echo $view->render();

Note I think you should specify every field you wan't to use, in other words you shouldn't use Show: Content | Full Content - because this will result in an infinite loop. I don't think this is a complete solution, but perhaps it will point you in the right direction.

If you are using fields in the view you could create a separate template named views-view-fields--YOUR_VIEW_NAME--YOUR_VIEW_BLOCK_NAME.tpl that will be used to output the actual fields.

I tried the following and it seems to work:

  1. Create a new block view
  2. Add a Contextual filter of type Content: Nid
  3. Add a relationship of type Content: Author (Required)
  4. Add a relationship of type User: Content authored that uses the previous relationship and is required
  5. Under Format you set Show: Content | Full Content - You must also use the User: Content authored relationship for this one

You could also change the number of related nodes that will be shown and also you might wan't to add a filter of Content: Type to restrict what kind of nodes to display. Notice that you could create a template for a specific content-type ie node--<YOUR_CONTENT_TYPE>.tpl and load and execute the view from there.

In you node.tpl file you would load this view doing something similar to:

$view = views_get_view('YOUR_VIEW_NAME');
$view->set_display('YOUR_VIEW_BLOCK_NAME');
$view->set_arguments(array($node->nid));
$view->execute();
echo $view->render();

Note I think you should specify every field you wan't to use, in other words you shouldn't use Show: Content | Full Content - because this will result in an infinite loop. I don't think this is a complete solution, but perhaps it will point you in the right direction.

I tried the following and it seems to work:

  1. Create a new block view
  2. Add a Contextual filter of type Content: Nid
  3. Add a relationship of type Content: Author (Required)
  4. Add a relationship of type User: Content authored that uses the previous relationship and is required
  5. Under Format you set Show: Content | Full Content - You must also use the User: Content authored relationship for this one

You could also change the number of related nodes that will be shown and also you might wan't to add a filter of Content: Type to restrict what kind of nodes to display. Notice that you could create a template for a specific content-type ie node--<YOUR_CONTENT_TYPE>.tpl and load and execute the view from there.

In you node.tpl file you would load this view doing something similar to:

$view = views_get_view('YOUR_VIEW_NAME');
$view->set_display('YOUR_VIEW_BLOCK_NAME');
$view->set_arguments(array($node->nid));
$view->execute();
echo $view->render();

Note I think you should specify every field you wan't to use, in other words you shouldn't use Show: Content | Full Content - because this will result in an infinite loop. I don't think this is a complete solution, but perhaps it will point you in the right direction.

If you are using fields in the view you could create a separate template named views-view-fields--YOUR_VIEW_NAME--YOUR_VIEW_BLOCK_NAME.tpl that will be used to output the actual fields.

added 179 characters in body
Source Link
Cyclonecode
  • 3.4k
  • 31
  • 47

I tried the following and it seems to work:

  1. Create a new block view
  2. Add a Contextual filter of type Content: Nid
  3. Add a relationship of type Content: Author (Required)
  4. Add a relationship of type User: Content authored that uses the previous relationship and is required
  5. Under Format you set Show: Content | Full Content - You must also use the User: Content authored relationship for this one

You could also change the number of related nodes that will be shown and also you might wan't to add a filter of Content: Type to restrict what kind of nodes to display. Notice that you could create a template for a specific content-type ie node--<YOUR_CONTENT_TYPE>.tpl and load and execute the view from there.

In you node.tpl file you would load this view doing something similar to:

$view = views_get_view('YOUR_VIEW_NAME');
$view->set_display('YOUR_VIEW_BLOCK_NAME');
$view->set_arguments(array($node->nid));
$view->execute();
echo $view->render();

Note I think you should specify every field you wan't to use, in other words you shouldn't use Show: Content | Full Content - because this will result in an infinite loop. I don't think this is a complete solution, but perhaps it will point you in the right direction.

I tried the following and it seems to work:

  1. Create a new block view
  2. Add a Contextual filter of type Content: Nid
  3. Add a relationship of type Content: Author (Required)
  4. Add a relationship of type User: Content authored that uses the previous relationship and is required
  5. Under Format you set Show: Content | Full Content - You must also use the User: Content authored relationship for this one

You could also change the number of related nodes that will be shown and also you might wan't to add a filter of Content: Type to restrict what kind of nodes to display. Notice that you could create a template for a specific content-type ie node--<YOUR_CONTENT_TYPE>.tpl and load and execute the view from there.

In you node.tpl file you would load this view doing something similar to:

$view = views_get_view('YOUR_VIEW_NAME');
$view->set_display('YOUR_VIEW_BLOCK_NAME');
$view->set_arguments(array($node->nid));
$view->execute();
echo $view->render();

Note I think you should specify every field you wan't to use, in other words you shouldn't use Show: Content | Full Content - because this will result in an infinite loop.

I tried the following and it seems to work:

  1. Create a new block view
  2. Add a Contextual filter of type Content: Nid
  3. Add a relationship of type Content: Author (Required)
  4. Add a relationship of type User: Content authored that uses the previous relationship and is required
  5. Under Format you set Show: Content | Full Content - You must also use the User: Content authored relationship for this one

You could also change the number of related nodes that will be shown and also you might wan't to add a filter of Content: Type to restrict what kind of nodes to display. Notice that you could create a template for a specific content-type ie node--<YOUR_CONTENT_TYPE>.tpl and load and execute the view from there.

In you node.tpl file you would load this view doing something similar to:

$view = views_get_view('YOUR_VIEW_NAME');
$view->set_display('YOUR_VIEW_BLOCK_NAME');
$view->set_arguments(array($node->nid));
$view->execute();
echo $view->render();

Note I think you should specify every field you wan't to use, in other words you shouldn't use Show: Content | Full Content - because this will result in an infinite loop. I don't think this is a complete solution, but perhaps it will point you in the right direction.

added 179 characters in body
Source Link
Cyclonecode
  • 3.4k
  • 31
  • 47
Loading
Source Link
Cyclonecode
  • 3.4k
  • 31
  • 47
Loading