I’m trying to use Jquery on the add/edit pod item page. I have a pod named ‘matches’ that holds the information for some boxing matches. I tried to write some elementary JQuery to test. I’m able to spit out an alert(), but not manipulate any of the elements in the form.
I’ve tried this is a display helper & as an input helper
var $ = jQuery;
I haven’t been able to do anything to any of the fields in the form on the add/edit pod item page. Is this becuase it’s added in with ajax? Or are we not allowed to manipulate the form in pods?
Hey thanks for the reply. I don’t know if you mean search for it. But it is specific to my pod so nothing came up.
I made the form field fighter2 in my boxer’s pod. And it is a pick/relationship in my matches pod. Using firefox firebug, I see the form input element gets a class of match_fighter2Helper automatically. But when I view page source it’s not there??
This is logged in a admin, and adding a new match. Choosing fighter1 or fighter2, I wanted to use jQuery on the input field and can’t select it….Maybe we just can’t change the input fields with jquery?
we can, and it’s pretty hard to block it.
try something like alert(jQuery(‘input.match_fighter2Helper’).html()) – this should output the insides of an element, so this will tell if jQuery finds this element.
I tried it and it’s alerting ‘null’. I can inspect the input field with firefox’s firebug, I know i’m getting the right selector ‘.match_fighter2Helper’, but the form fields aren’t in the source when i view page source.
The edit pod item form seems to be brought in with this code:
<div id="editArea" class="area">