Using the option to display the profile tab on /user/12 pages as a top-level tab, rather than a subtask under the Edit tab, we are seeing the Edit tab disappear when we click into the edit profile tab.

CommentFileSizeAuthor
#1 jamesan_419662.patch753 bytesJamesAn
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

JamesAn’s picture

Status: Active » Needs review
FileSize
753 bytes

I agree; it looks like a bug. I've attached the patch to fix it in file content_profile/content_profile.module, line 45:

44:  foreach (content_profile_get_types('names') as $type => $type_name) {
45:    $items['user/%user/profile/'. $type] = array(
46:      'title callback' => 'check_plain',

The path, 'user/%user/profile/'. $type has the extra argument, profile, that prevents the edit tab from being rendered when you're editting the content profile.

To fix immediately, you can remove the profile argument:

45:    $items['user/%user/'. $type] = array(

The only catch is that the content type with the machine-readable name, edit can't show its edit tab on the user's page since its path, 'user/%user/edit', is the same as the user's edit page path. But who'd name their content type edit anyway.

andreiashu’s picture

This seems right to me.
Someone must ping fago to commit this.

JamesAn’s picture

Glad to know I was on the right track. ^_^
I just dropped in, so I don't know how to get a hold of fago.

andreiashu’s picture

Me neither. I just know that he doesn't have any time for maintaining this module - I concluded this because of the lack of commits of course. There are lots of patches floating around in the issue queue that are not committed.

I think someone should step in and help him maintain this module, of course with his approval. I'm not sure how we could do this though - I would be glad to help somehow but I don't know how to contact him and I also don't have any experience maintaining/co-maintaining a module.
So, all in all, if anyone thinks he/she can do this better just step in :)
I'm hoping fago will look over this comment and think whether he can add someone as a co-maintainer or at least give more love to this module.

mlncn’s picture

Status: Needs review » Reviewed & tested by the community

Thanks JamesAn. This works! Note that you may have to save the modules page to get the menu system to rebuild to see the changes.

If we can make a note somewhere in the module code or documentation about the "content type named edit and used as a profile" conflict, I think that's more than reasonable. Or we could even add an if statement to revert to the old behavior for a tab named edit.

andreiashu, JamesAn, if either of you would like to be a comaintainer send me your contact info and I can try to get it to Fago if I see him on IRC.

benjamin, Agaric Design Collective

andreiashu’s picture

If JamesAn agrees maybe we should both join forces for this, comaintaining this module.
Thanks Benjamin.

JamesAn’s picture

Join forces?! That'd be cool!
This'll be my first time maintaining a mod.. awesome.

I'm increasingly on IRC nowadays as JamesAn.

Who are all the co-maintainers? Is there a road map for Content Profiles, or are we just patching stuff up at this point?

andreiashu’s picture

@JamesAn great ! :)
The currently maintainers of CP are listed on its project page: fago, jgraham, marcp

As far as I know there isn't currently a road map for CP so I think that the first thing that we should do (if fago agrees that we can be comaintainers) would be patching stuff - as you said. There are also some more delicate problems that we will have to address like the #236467: Integrate profile with user/edit issue.

I'll try to be on IRC more often.

asak’s picture

So JamesAn, andreiashu, what's up? did you catch fago or anyone?

I'll be happy to help with the testing... it really seems this module is close to a release, and if you can manage to roll it out that would be beautiful!

JamesAn’s picture

Hola!

I haven't been able to get in touch with any of the co-maintainers. They're not on IRC much.. I also haven't gone through all the issues for the 6.x betas.

I'm working on #236467: Integrate profile with user/edit currently, but I'll take a broader look at the state of the module afterwards. Maybe fago or the other co-maintainers will pop in by then?

fago’s picture

Status: Reviewed & tested by the community » Needs work

this is an core-issue, see #259679: user/[uid]/edit tab not present at user's visits tracker

Until this is fixed, we could work around it though. However the patch misses an update (menu_rebuild), doesn't take care off fixing the content_profile_default_path_handler() and as mentioned has a problem with content types called 'edit' - which we need to take care off.

JamesAn’s picture

Status: Needs work » Postponed
HnLn’s picture

subscribe

Bilmar’s picture

subscribing

uomeds’s picture

Version: 6.x-1.0-beta3 » 6.x-1.0-beta4

The fix in #1 worked for me with drupal 6.14 and 1.0-beta4.

Though, FYI, the line that needs to be changed to:

$items['user/%user/'. $type] = array(

is now line 50 of content_profile.module. And you have to run update.php after changing it for the change to register.

Thanks.

victoria_b’s picture

Works like a charm - thank you!

YK85’s picture

#259679: user/[uid]/edit tab not present at user's visits tracker looks to need some reviewers for Drupal 6. Can anyone assist?

rburgundy’s picture

Status: Postponed » Active

#259679: user/[uid]/edit tab not present at user's visits tracker is now RTBC
would anyone please be able to further develop for content profile?

Shadlington’s picture

So... Now that that issue is dealt with, any further work on this issue?

sfyn’s picture

Bump! What's the status of this issue now?