Results 1 to 3 of 3

Thread: Referencing a custom field in a HTML field

  1. #1
    wolfie19 is offline Member
    Join Date
    Mar 2009
    Posts
    6

    Default Referencing a custom field in a HTML field

    Hi, this is my second post, so please bear with me.

    I am running 5.5 with no known problems.

    I am trying to link to an external website by having a button on the client detail page. I have already managed to get the link field to work and can display the URL of the new site in the detail section. This link works with taking the client reference # (the variable) and connecting without problems. Unfortunately I have 2 problems with this:
    1. long URL looks messy
    2. link opens in same page/tab as Sugar - not ideal


    I have now started to look at creating a button using the HTML field. This works as intended if I hard code the client reference #, but when I try to add any of the custom fields into the URL, the smarty compiler errors with:

    Fatal error: Smarty error: [in cache/modules/Contacts/DetailView.tpl line 219]: syntax error: unrecognized tag xxxxxxxl_c' (Smarty_Compiler.class.php, line 580) in /var/www/xxxxxxx/include/Smarty/Smarty.class.php on line 1095

    Any help or suggestions would be gratefully received on this.

    Thanks

  2. #2
    wolfie19 is offline Member
    Join Date
    Mar 2009
    Posts
    6

    Default Re: Referencing a custom field in a HTML field

    OK, so I have now got past the compile error from Smarty.

    What I am getting now, is the answer to my query being ARRAY not the value of the field that I was requesting.

    Anyone have an idea on where I should look to resolve this?

    Thanks

  3. #3
    wolfie19 is offline Member
    Join Date
    Mar 2009
    Posts
    6

    Default Re: Referencing a custom field in a HTML field

    This has to be a first by me! I have actually resolved my own post

    thanks to the link from P-Unterberg, referenced here:

    http://www.sugarcrm.com/forums/showt...marty+compiler

    I realised that i had not added the .value to the
    <p><a href=insert link here?userid={$fields.fieldname.value}" target="_blank"><img style="border: 0pt none; ;" src=image" alt="" width="25" /></a></p>

    I hope that this helps anyone else doing this.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Field validation in custom EditView.html
    By flymirco in forum Developer Help
    Replies: 0
    Last Post: 2009-03-11, 02:58 PM
  2. Replies: 4
    Last Post: 2008-12-14, 10:48 PM
  3. custom field of html type with dynamic querystring???
    By dogfuel in forum Developer Help
    Replies: 9
    Last Post: 2008-11-05, 07:05 AM
  4. Replies: 0
    Last Post: 2008-02-01, 08:01 PM
  5. Replies: 2
    Last Post: 2006-06-13, 11:24 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
  •