Moti Mashiah
asked on
asp.net mvc
Hi Guys,
I"m wondering if is it possible to use element from index page to partial view:
For example:
I have index page and inside the page I have my partial view.
Now in the index page I have button <input type="button" id="btid">
I would like to use this "btid" in my partial view but it seems I can't do it as I can't use elements backwards. like if I have element in my partial view the index page can use them but not in the other way.
There is any trick that can make it work.
Thanks,
I"m wondering if is it possible to use element from index page to partial view:
For example:
I have index page and inside the page I have my partial view.
Now in the index page I have button <input type="button" id="btid">
I would like to use this "btid" in my partial view but it seems I can't do it as I can't use elements backwards. like if I have element in my partial view the index page can use them but not in the other way.
There is any trick that can make it work.
Thanks,
ASKER CERTIFIED SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
ASKER
Thanks.
ASKER
Actually, I had to use the button from the index as I return the index page just one and then I return the partial, so in that case I couldn't see the button element as I had to hide it by condition.
I have solved the issue by moving the button from Index to partial view. Now both partial and index can use this button element.
Thanks.