I have a tricky questian this time...for me anyway....
clarify: i am using a virtual keyboard that has to work on deferent text fields, and deferent pages, every time i click on a text field it sould pop up and every key i press i need to show on the text field....the problem, as every one knows, is to bind a deferent text field to the virtual keyboard, And as i said, also, to use it on deferent pages without rewriting the keyboard code for every page again and again, some thing that will not do... still can not give any code as there is no code to give, sorry.....looking for the algorithem...for the basic solution, so there is no code....sorry....
Sorry i don't have code to show becouse i am trying to figure out how to do this and not showing a problem...
Background: I have an aspx file that holds a keyboard div and a hidd开发者_C百科en TextArea or an Input type=hidden (not decided yet). This page is a user control so it cen be used in all the pages that needs it...
What i am tring to do: Using JQuery bind('focus',...) method to bind any field in a certian aspx page (not the keyboard UC itself) to the hidden text field, i want that every thing i click on the keyboard will show in the text field that is on focus....
- Can i relate in JS/JQuery to a field that is in a different page, will it recognise it?
- how can i do the bind, how can i transfer text from one field to another?
- if there a better way to do this, i will be happy to hear about it...
10x :-)
- You can't use javascript across pages. It will only act on the currently active DOM.
- example: $('input.field1').live('change', function() { $('input.field2').text( $(this).text() ) });
- Please clarify your question, because it's not entirely clear what you want to achieve.
精彩评论