I am currently working on Ajax-Jquery,
- When user signin using Lightbox , after signin verification it will lead to the previous page without any refresh.
- Now my problem is after successful signin , I want to refresh the content of div in header portion without refreshing the whole page.
- Like Welcome User , my Account etc...
- Now i am able to retain in the previous page(but the header portion is able to refresh).
- the reference link below http://stackoverflow.com/questions/2...ogged-div?rq=1
- My try is ,
Code:
Code:
<script>
    $(document).ready(function(){
        $("#signin").submit(function(e){
            var postData = $(this).serializeArray();
            var formURL = $(this).attr("action");
            $.ajax({
                url : formURL,
                type: "POST",
                data : postData,
                success:function(data) {
                    $(".message").html(data); // header portion with welcome message will appear here , i want to replace the link from (login,Register-> Welcome user , Myaccount)
                },
                error: function(errorThrown) {
                    $("#overlaypage").html(errorThrown);
                }
            });
            e.preventDefault();    //STOP default action
            e.unbind();
        });
    });
</script>