I have this working if some of the cck content-profile form is complete but should the block be shown if a content-profile node has never been created by the user? (ie the user has never visited and saved the form) I can't see how to do that.
Thanks
Comments
Comment #1
pvhee commentedA block will only be shown if content of the specified type is created at this moment. I might put a link to "create content of that type" in the box, thanks for the suggestion.
Comment #2
pvhee commentedA block will only be shown if content of the specified type is created at this moment. I might put a link to "create content of that type" in the box, thanks for the suggestion.
Comment #3
Patroclas commentedThanks for your reply.
That facility would certainly be very useful for my application.
Comment #4
pvhee commentedComment #5
liliplanet commentedYes, subscribe thx! This is for users to create their profile and have not filled in any fields as yet ..
Comment #6
texas-bronius commentedNote: If you're using Content Profile, you could use something like this php snippet to detect for a profile or show a link to prompt the user to create it:
I adapted this from #720904: code to check if content profile 'profile' exists but am not sure why language might be required. I assume that it should relatively as simple to check for another node's existence.
Comment #7
gregoiresan commentedThis is interresting, but it still won't make it clear in term of completion. For e.g. : They are 3 content types to make a full profile. One content type if 50% completed. The Content Complete module will say that : Your profile is 50% complete, please complete... bla bla bla. But actually, it might be 15% completed only.
If we could sum up content types, then we could easily mix it to the page route module and having a coherent view of what is completed or not. Having choice to skip steps in the route and update the missing content later.
just an idea...
Comment #8
texas-bronius commentedFrom what I recall, my proposed php snippet was merely an on-off check to provide an easy link into completing the profile-- the Content Complete module should be configured to allow it to determine actual completeness (I think).
Comment #9
gregoiresan commentedActually, I found a roundabout to solve this issue. Espacially for none coders.
(@ Texas-bronius: Your code looks great, but I'm not confident with coding even if it seems simple).
Required modules : Rules & Trigger (core)
Trick : Create Content Profile nodes if user haven't created them
Set new trigger rule : User has logged in - this rule is active
Condition : User has profile (Negate)
Do :
save
Voilà !
Now, your newly registered users have the Content Profiles created. And Content Complete can therefore aggregate the data beautifully.