We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Onchange actions for custom entry fields

Development and Programming

vaneone's avatar
vaneone
2 posts
14 years ago
vaneone's avatar vaneone

Hello,

I am currently creating custom functionality within expressionengine to be able to cross-reference entry data with data from an external api

I created a custom field that will accept the id of the entity from the external api that the entry corresponds to

What I want to do is create an onchange event on my custom entry field that will accept a search term and run a search query against the external api and show an active list of results to choose from (like google search)

When the user clicks an entry in the list, I want the field to populate with the corresponding id

I have lots of experience with web development, and I already know how to handle all of the JS, but I am very new to EE and, after looking at the hooks documentation, I’m not really sure where I can add an event listener in an elegant fashion.

Maybe one of you EE-savvy folks can point me in the right direction?

Also, I would like to know where I can add script tags to the control panel’s header.

Any help is greatly appreciated.

Thanks -D

       
vaneone's avatar
vaneone
2 posts
14 years ago
vaneone's avatar vaneone

By the way I am running version 2.1.3

       
John Henry Donovan's avatar
John Henry Donovan
12,339 posts
14 years ago
John Henry Donovan's avatar John Henry Donovan

Hi vaneone,

We have a Development and Programming forum which is perfect for this type of question so moving this thread for you

This link may help. Now it is EE1.x and it doesn’t have anything to do with the final result you wish but the JS functionality it uses may help.

       
vaneone's avatar
vaneone
2 posts
14 years ago
vaneone's avatar vaneone

John,

Thanks for your reply!

There is some very useful information there, I think this is exactly what I was looking for.

I’ll post my own solution when I finish, I am pulling my autocomplete data with JSONP from external server

Thanks again!

v

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.