0

I have this code to search someone in my database :

<script type="text/javascript">
    $(function () {
        $('#search').click(function () {
            $mvc.jssearchNational.search({ nationalCode: $("#karkonan_MelliCode").val() }).success(function (data) {
                $("#searchres").replaceWith("<span id=searchres>" + data.message + "</span>");
            });
        });
    });
</script>

I want after the successful search, load person info in page by jquery. is it anyone to bind model dynamically and refresh the page by jquery or I have to assign each field to my page's controls?

1 Answer 1

1

If you want to use bindings, try taking a look at the MVVM pattern and KnockOutJS

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.