My profile block(button)

Status: 
Open
Question: 

I desided to create two different account types, each one assigned to different role. So i created a new content type called "Regular profile(regular_profile)" wich i use for my new account type.The question is how to modify the code below to work properly with both content types.

<?php
global $user;
$myuid= $user->uid;
$node= content_profile_load(profile, $myuid);
//profile above=the name of our content type
$profileid= $node->nid;
print l(t('My Profile'), 'node/'.$node->
nid, array('html' => true))
?>

Responses

1. It's O.K. I used views

It's O.K. I used views instead.