Is it possible to integrate php for a specific form field

Hi i seem to have lost this thread from previously - is it possible to add php code/ javascript to specific form fields or form groups?
thanks in advance,

sorry to bump but really could do with some help here - i want to type into a field and it reference data from a database that the user has to choose, does anyone know if its possible to add coding possibilities to suite?

Hi eroticspoon,

Are you looking for something similar to a auto populate field ? it can be done will require some coding to allow this. I am not aware of any examples within SuiteCRM which do this currently, so you would need to attach an event handler to the field and use ajax to get the information from PHP.

If the information is in another module using a relate field would do the same job ?


Hi Ian, is there any information or documenntation about event handling of fields in suitecrm?

There are a number of ways to do this being upgrade safe.

so attaching js code to a field.

or the cleanner way is attaching a js file to a edit view.

which then you can just use jquery to attach a on click or on blur event to the field as you would normally do.


thats great thanks Ian, i take it i can also execute php requirements through here too?

I wouldnt recommend doing php in the edit defs as there is a possiblity if something is changed in studio for that layout it will clear the php.

have a look here,

This shows you how to extend the view which allows you to put php in the view. for what you want to do you would want to make a ajax call in the js file which will allow you to do php work and return the data.