Answers.Body: <p>You are adding a new option for an existing field, rather than creating a new custom field.  The existing website token will show the URL of your new website type: <code>{contact.url}</code>   But if you want a token to show the website type (to output 'Portfolio'), you would need to <a href="https://civicrm.org/blog/colemanw/create-your-own-tokens-for-fun-and-profit" rel="nofollow noreferrer">create one</a> </p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-01-30T12:14:45.223Z
Answers.Text: Thanks Aidan! I'm not a good programmer. any code to follow? or to edit?
Answers.UserDisplayName: RaffyM
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-01-30T16:10:12.023Z
Answers.Text: There's some code in the blog post I linked to previously.  What output do you want your token to produce?
Answers.UserDisplayName: Aidan
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-01-31T00:10:16.107Z
Answers.Text: Yes, but the code seems too hard for me to follow. It will be good if there a easier guide. I just want to create a token that will output the Portfolio link.
Answers.UserDisplayName: RaffyM
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-01-31T00:18:55.080Z
Answers.Text: If you want the link, have you tried `{contact.url}` ?
Answers.UserDisplayName: Aidan
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-01-31T00:26:17.480Z
Answers.Text: Hey Aidan. Yes, but it ouputs the url in Work Type.
Answers.UserDisplayName: RaffyM
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-01-31T15:32:22.410Z
Answers.Text: @RaffyM I wish that I had a better answer - but unfortunately CiviCRM doesn't do this out of the box, and only programming can solve this!  If you're an amateur programmer, I'd try downloading Eileen's CiviToken extension and modifying the "phones" token: https://github.com/eileenmcnaughton/nz.co.fuzion.civitoken/tree/master/tokens.  Read up on the "API Explorer" - it will help you write your code!
Answers.UserDisplayName: Jon G - Megaphone Tech
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-01T00:07:32.030Z
Answers.Text: Hey @Jon G! thanks for pointing me to CiviToken, I'll try to review the phones token of the code.
Answers.UserDisplayName: RaffyM
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-01T11:19:38.687Z
Answers.Text: If you have multiple websites defined for a contact, `{contact.url}` seems to show the first one in the list.  If your portfolio URL is first (or the only one) then it will show your portfolio URL.   So, if your system is only interested in recording a portfolio url, you could disable all the other website types and then you can reliably use `{contact.url}`.  If you want multiple websites and a token that always yields the portfolio, then continue with code route.
Answers.UserDisplayName: Aidan
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-01-30T10:01:33.263Z
Answers.LastActivityDate: 2017-01-30T10:24:38.437Z
Answers.LastEditDate: 2017-01-30T10:24:38.437Z
Answers.UserDisplayName: Aidan
Body: <p>I have added a new website types (Administer> Customize Data and Screens> Dropdown Options> Website Types) called 'Portfolio' and want to add it on my CiviMail Message Templates using a token. I have tried to use the {contact.custom_id} but it doesn't work. I'm not sure if i'm doing it right but I follow the instruction in Token Help w/c is to get the ID in edit link (Please see the screenshots below):</p>
  
  <p><a href="https://i.sstatic.net/1f5Gh.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/1f5Gh.png" alt="enter image description here"></a></p>
  
  <p>so my custom code would be {contact.custom_844} right? </p>
  
  <p>PS. I'm using it on Organization. CiviCRM 4.7.14 on Wordpress 4.7.2</p>
  
  <p>Thanks!</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-01-30T12:57:12.613Z
Comments.Text: Welcome to StackExchange! It would be helpful if you could edit your post to include the version of CiviCRM and WordPress that you are using as this can sometimes affect the answers given.
Comments.UserDisplayName: William Mortada
Tags: <wordpress><civimail><tokens>
Title: Token For Custom Websites Types
ThreadText: # Token For Custom Websites Types
  
  (Asked by: username_0 on 2017-01-30)
  
  I have added a new website types (Administer> Customize Data and Screens> Dropdown Options> Website Types) called 'Portfolio' and want to add it on my CiviMail Message Templates using a token. I have tried to use the {contact.custom\_id} but it doesn't work. I'm not sure if i'm doing it right but I follow the instruction in Token Help w/c is to get the ID in edit link (Please see the screenshots below):
  
  [![enter image description here](https://i.sstatic.net/1f5Gh.png)](https://i.sstatic.net/1f5Gh.png)
  
  so my custom code would be {contact.custom\_844} right?
  
  PS. I'm using it on Organization. CiviCRM 4.7.14 on Wordpress 4.7.2
  
  Thanks!
  
  **Tags:** wordpress, civimail, tokens
  
  > **Comments:**
  > **username_1**: Welcome to StackExchange! It would be helpful if you could edit your post to include the version of CiviCRM and WordPress that you are using as this can sometimes affect the answers given.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_2 on 2017-01-30. Score: 2
  
  You are adding a new option for an existing field, rather than creating a new custom field. The existing website token will show the URL of your new website type: `{contact.url}` But if you want a token to show the website type (to output 'Portfolio'), you would need to [create one](https://civicrm.org/blog/colemanw/create-your-own-tokens-for-fun-and-profit)
  
  > **Comments:**
  > **username_0**: Thanks username_2! I'm not a good programmer. any code to follow? or to edit?  
  > **username_2**: There's some code in the blog post I linked to previously.  What output do you want your token to produce?  
  > **username_0**: Yes, but the code seems too hard for me to follow. It will be good if there a easier guide. I just want to create a token that will output the Portfolio link.  
  > **username_2**: If you want the link, have you tried `{contact.url}` ?  
  > **username_0**: Hey username_2. Yes, but it ouputs the url in Work Type.  
  > **username_3**: @username_0 I wish that I had a better answer - but unfortunately CiviCRM doesn't do this out of the box, and only programming can solve this!  If you're an amateur programmer, I'd try downloading Eileen's CiviToken extension and modifying the "phones" token: https://github.com/eileenmcnaughton/nz.co.fuzion.civitoken/tree/master/tokens.  Read up on the "API Explorer" - it will help you write your code!  
  > **username_0**: Hey @Jon G! thanks for pointing me to CiviToken, I'll try to review the phones token of the code.  
  > **username_2**: If you have multiple websites defined for a contact, `{contact.url}` seems to show the first one in the list.  If your portfolio URL is first (or the only one) then it will show your portfolio URL.   So, if your system is only interested in recording a portfolio url, you could disable all the other website types and then you can reliably use `{contact.url}`.  If you want multiple websites and a token that always yields the portfolio, then continue with code route.  
  
  ---
  
  