I use subdomain for the following:

Authenticated users can create only one node type: seotags. These seotags are 'created' into subdomains by pathauto. So if somebody creates the node 'test' with node type 'seotags' pathauto makes it reachable through test.domain.com.

I created a view (block) that shows nodes of a certain type (seotag's) created by the logged in user. (His own seotags he can administer, edit, delete etc).

It shows doubles though; every node is shown twice, except if logged in as Administrator. Standard 'Recent posts' also show double if not loggin in (anonymous).

If I give authenticated users the rights to 'administer nodes' in user rights/permissions, the doubles are gone when they re logged in, BUT the authenticated users are also allowed to create other content types (pages, stories, ...). If I uninstall the subdomain module, the doubles are gone as well.

Right now in permissions, they only have rights to

- create seotag content
- delete own seotag content
- edit own seotag content

How do I alter the view or the permissions so the view doesn't show each seotag twice ???
Or do I have to alter the settings for subdomain ? Right now in Domain Access settings, the main domain domain.com and www.domain.com are seen as one (all translate to domain.com). Maybe there lies the problem ?

I know the 'Distinct: Yes' in Views explains it doesn't always work, but how do I solve it ?

Here's an export of the view:

<?php
$view = new view; 
$view->name = 'own_content'; 
$view->description = 'own seo-tags'; 
$view->tag = ''; 
$view->view_php = ''; 
$view->base_table = 'node'; 
$view->is_cacheable = FALSE; 
$view->api_version = 2; 
$view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */ 
$handler = $view->new_display('default', 'Defaults', 'default'); 
$handler->override_option(
    'fields', array( 
        'title' => array( 
            'label' => 'Titel', 
            'alter' => array( 
                'alter_text' => 0, 
                'text' => '', 
                'make_link' => 0, 
                'path' => '', 
                'link_class' => '', 
                'alt' => '', 
                'prefix' => '', 
                'suffix' => '', 
                'target' => '', 
                'help' => '', 
                'trim' => 0, 
                'max_length' => '', 
                'word_boundary' => 1, 
                'ellipsis' => 1, 
                'strip_tags' => 0, 
                'html' => 0, ), 
                'empty' => '', 
                'hide_empty' => 0, 
                'empty_zero' => 0, 
                'link_to_node' => 1, 
                'exclude' => 0, 
                'id' => 'title', 
                'table' => 'node', 
                'field' => 'title', 
                'relationship' => 'none',
                ),
            )
    ); 
$handler->override_option(
    'arguments', array( 
        'uid' => array( 
            'default_action' => 'default', 
            'style_plugin' => 'default_summary', 
            'style_options' => array(), 
            'wildcard' => 'all', 
            'wildcard_substitution' => 'Alle', 
            'title' => '', 
            'breadcrumb' => '', 
            'default_argument_type' => 'current_user', 
            'default_argument' => '', 
            'validate_type' => 'user', 
            'validate_fail' => 'summary asc', 
            'break_phrase' => 0, 
            'not' => 0, 
            'id' => 'uid', 
            'table' => 'users', 
            'field' => 'uid', 
            'validate_user_argument_type' => 'either', 
            'validate_user_roles' => array( 
                '2' => 2, 
                '3' => 0, 
                '4' => 0, 
            ), 
            'relationship' => 'none', 
            'default_options_div_prefix' => '', 
            'default_argument_user' => 0, 
            'default_argument_fixed' => '', 
            'default_argument_php' => '', 
            'validate_argument_node_type' => array( 
                'page' => 0, 
                'seotag' => 0, 
                'story' => 0, 
                ), 
            'validate_argument_node_access' => 0, 
            'validate_argument_nid_type' => 'nid', 
            'validate_argument_vocabulary' => array(), 
            'validate_argument_type' => 'tid', 
            'validate_argument_transform' => 0, 
            'validate_user_restrict_roles' => 1, 
            'validate_argument_php' => '', 
            'override' => array( 
                'button' => 'Override',
            ), 
        ), 
    )); 
$handler->override_option(
    'filters', array( 
        'status' => array( 
            'operator' => '=', 
            'value' => '1', 
            'group' => '0', 
            'exposed' => FALSE, 
            'expose' => array( 
                'operator' => FALSE, 
                'label' => '',
            ), 
        'id' => 'status', 
        'table' => 'node', 
        'field' => 'status', 
        'relationship' => 'none',
        ), 
    )); 
$handler->override_option(
    'access', array( 
        'type' => 'domain', 
        'domains' => array( '0' => -1, ), 
        'domain_strict' => FALSE, 
        'domain_member' => FALSE, 
    )); 
$handler->override_option(
    'cache', array( 'type' => 'none', )); 
$handler->override_option('distinct', 1); 
$handler->override_option('exposed_block', TRUE); 
$handler = $view->new_display('block', 'Blok', 'block_1'); 
$handler->override_option(
    'arguments', array( 
        'uid' => array( 
            'default_action' => 'default', 
            'style_plugin' => 'default_summary', 
            'style_options' => array(), 
            'wildcard' => 'all', 
            'wildcard_substitution' => 'Alle', 
            'title' => '', 
            'breadcrumb' => '', 
            'default_argument_type' => 'current_user', 
            'default_argument' => '', 
            'validate_type' => 'user', 
            'validate_fail' => 'empty', 
            'break_phrase' => 0, 
            'not' => 0, 
            'id' => 'uid', 
            'table' => 'users', 
            'field' => 'uid', 
            'validate_user_argument_type' => 'uid', 
            'validate_user_roles' => array( 
                '2' => 2, 
                '3' => 0, 
                '4' => 0, 
                ), 
            'relationship' => 'none', 
            'default_options_div_prefix' => '', 
            'default_argument_user' => 0, 
            'default_argument_fixed' => '', 
            'default_argument_php' => '', 
            'validate_argument_node_type' => array( 
                'page' => 0, 
                'seotag' => 0, 
                'story' => 0, 
                ), 
            'validate_argument_node_access' => 0, 
            'validate_argument_nid_type' => 'nid', 
            'validate_argument_vocabulary' => array(), 
            'validate_argument_type' => 'tid', 
            'validate_argument_transform' => 0, 
            'validate_user_restrict_roles' => 0, 
            'validate_argument_php' => '', 
            'override' => array( 
                'button' => 'Use default', 
                ), 
            ), 
        )
    ); 
$handler->override_option('items_per_page', 25); 
$handler->override_option('block_description', ''); 
$handler->override_option('block_caching', -1);
?>

Comments

reizigertje’s picture

Status: Active » Fixed

Solved by creating a separate module for it.

ZyanKLee’s picture

Status: Fixed » Needs work

I still got this problem and creating a new module to replace subdomain is no valid choice for me.

Nodes are doubled at least on "og_ghp_ron" view and on a slightly modified version of the view "og_mytracker" (removed 2 fields).