Results 1 to 3 of 3

Thread: Custom field - display as hyperlink

  1. #1
    ChocolateLover is offline Sugar Community Member
    Join Date
    Feb 2007
    Posts
    14

    Default Custom field - display as hyperlink

    I downloaded this fantastic package a few days ago and I'm having a go at modifying it.

    I'm working in Contacts. I've added a custom field (website) to both the EditView and DetailView and the content of the field is being saved successfully in EditView and displayed in DetailsView.

    I'd like to change the way that the contents of the field are displayed and display the field as it is displayed in the Accounts module - that is remove the http:// if it exists (remove_redundant_http) and display as a hyperlink (<A title='http://{WEBSITE}' href='http://{WEBSITE}' target="_blank" class="tabDetailViewDFLink">{WEBSITE}</A>).

    I think I can work out the changes, but I'm not sure where the custom fields are processed?

    Any help would be greatfully received.

    I couldn't find any documentation on customising forms and custom fields, other than what you can do in Studio. If any documentaion exists can someone point me in the right direction please.

    Thanks.
    SugarSuite 4.5.1
    OSX 10.4.8
    Apache 2
    PHP 5
    MySQL 4

  2. #2
    Supermathie is offline Junior Member
    Join Date
    Aug 2006
    Posts
    4

    Default Re: Custom field - display as hyperlink

    Waiting with bated breath to hear the answer to this one as well - we are doing the same thing and need the same change.

  3. #3
    ChocolateLover is offline Sugar Community Member
    Join Date
    Feb 2007
    Posts
    14

    Default Re: Custom field - display as hyperlink

    This came up in the similar threads area.

    http://www.sugarcrm.com/forums/showthread.php?t=11201

    Not sure why I didn't see it when I searched.

    Basically edit the Modules/ModuleName/DetailView.html file with <A title='http://{WEBSITE}' href='http://{WEBSITE}' target="_blank" class="tabDetailViewDFLink">{WEBSITE}</A> assuming the name of your field was website.

    To remove the http:// from the data try copying the remove_redundant_http function from the Accounts module to the Contacts module and add
    $this->remove_redundant_http();
    to the end of
    function fill_in_additional_list_fields()
    and
    function fill_in_additional_detail_fields()

    I decided not to use the field so I haven't tested this.
    SugarSuite 4.5.1
    OSX 10.4.8
    Apache 2
    PHP 5
    MySQL 4

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. custom field to sugar field
    By tanhaa in forum Developer Help
    Replies: 2
    Last Post: 2011-05-04, 03:52 PM
  2. Hyperlink in Custom Field
    By globekey in forum Help
    Replies: 7
    Last Post: 2007-01-04, 06:09 PM
  3. Asterisk Patch 1.1.0 Crash on logon
    By skyracer in forum Help
    Replies: 6
    Last Post: 2006-07-08, 06:30 AM
  4. Replies: 7
    Last Post: 2006-06-06, 07:56 PM
  5. Custom Fields don't display in Field Layout
    By sugarcrmvn in forum General Discussion
    Replies: 9
    Last Post: 2006-03-22, 07:15 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •