Click here to Skip to main content
15,887,379 members
Home / Discussions / JavaScript
   

JavaScript

 
QuestionJTable Add New Record button Pin
Member 1231770910-Feb-16 0:25
Member 1231770910-Feb-16 0:25 
Questionhow to open the JTable Add new Record form in button click in another form Pin
Member 123177099-Feb-16 23:02
Member 123177099-Feb-16 23:02 
AnswerMy Vote of 1 Pin
Keith Barrow12-Feb-16 4:57
professionalKeith Barrow12-Feb-16 4:57 
Questionworking with showCreateForm() in jtable Pin
Member 123177099-Feb-16 19:23
Member 123177099-Feb-16 19:23 
AnswerRe: working with showCreateForm() in jtable Pin
F-ES Sitecore9-Feb-16 22:42
professionalF-ES Sitecore9-Feb-16 22:42 
GeneralRe: working with showCreateForm() in jtable Pin
Member 123177099-Feb-16 22:55
Member 123177099-Feb-16 22:55 
GeneralRe: working with showCreateForm() in jtable Pin
F-ES Sitecore9-Feb-16 22:58
professionalF-ES Sitecore9-Feb-16 22:58 
QuestionWhen IFrame load event is called ? Pin
Tridip Bhattacharjee4-Feb-16 1:45
professionalTridip Bhattacharjee4-Feb-16 1:45 
in the below code iframe is using to upload file to server. see the code and tell me when iframe load event is fired ?
JavaScript
<script type="text/javascript">

    $(document).ready(function () {

        $("#formsubmit").click(function () {

            var iframe = $('<iframe name="postiframe" id="postiframe" style="display: none"></iframe>');

            $("body").append(iframe);

            var form = $('#theuploadform');
            form.attr("action", "/upload.aspx");
            form.attr("method", "post");

            form.attr("encoding", "multipart/form-data");
            form.attr("enctype", "multipart/form-data");

            form.attr("target", "postiframe");
            form.attr("file", $('#userfile').val());
            form.submit();

            $("#postiframe").load(function () {
                iframeContents = this.contentWindow.document.body.innerHTML;
                $("#textarea").html(iframeContents);
            });

            return false;

        });

    });

</script>


code taken from here http://stackoverflow.com/questions/7909161/jquery-iframe-file-upload

the above code dynamically creating iframe and append to body and submitting the form. how the above code file is uploading to server by iframe not clear?

what is relation between file upload and iframe in above code ?

when iframe load will call ?
JavaScript
$("#postiframe").load(function () {
                iframeContents = this.contentWindow.document.body.innerHTML;
                $("#textarea").html(iframeContents);
            });

help me in details.

thanks
tbhattacharjee

AnswerRe: When IFrame load event is called ? Pin
F-ES Sitecore9-Feb-16 22:26
professionalF-ES Sitecore9-Feb-16 22:26 
GeneralRe: When IFrame load event is called ? Pin
Tridip Bhattacharjee10-Feb-16 2:09
professionalTridip Bhattacharjee10-Feb-16 2:09 
GeneralRe: When IFrame load event is called ? Pin
F-ES Sitecore10-Feb-16 2:16
professionalF-ES Sitecore10-Feb-16 2:16 
GeneralRe: When IFrame load event is called ? Pin
Tridip Bhattacharjee10-Feb-16 20:44
professionalTridip Bhattacharjee10-Feb-16 20:44 
QuestionJavascript on dynamic gridview textboxs Pin
HGCoolPal2-Feb-16 2:48
HGCoolPal2-Feb-16 2:48 
AnswerRe: Javascript on dynamic gridview textboxs Pin
Keith Barrow8-Feb-16 2:16
professionalKeith Barrow8-Feb-16 2:16 
QuestionNumber of day week in javascript Pin
Mazdak1-Feb-16 4:34
Mazdak1-Feb-16 4:34 
AnswerRe: Number of day week in javascript Pin
Keith Barrow1-Feb-16 4:56
professionalKeith Barrow1-Feb-16 4:56 
GeneralRe: Number of day week in javascript Pin
Mazdak1-Feb-16 5:03
Mazdak1-Feb-16 5:03 
GeneralRe: Number of day week in javascript Pin
Keith Barrow1-Feb-16 5:10
professionalKeith Barrow1-Feb-16 5:10 
GeneralRe: Number of day week in javascript Pin
Mazdak1-Feb-16 5:12
Mazdak1-Feb-16 5:12 
GeneralRe: Number of day week in javascript Pin
Mazdak1-Feb-16 5:11
Mazdak1-Feb-16 5:11 
Questioncomparing two dates in javascript Pin
Member 1026351927-Jan-16 22:40
Member 1026351927-Jan-16 22:40 
QuestionRe: comparing two dates in javascript Pin
Richard MacCutchan27-Jan-16 23:17
mveRichard MacCutchan27-Jan-16 23:17 
AnswerRe: comparing two dates in javascript Pin
Richard Deeming28-Jan-16 1:46
mveRichard Deeming28-Jan-16 1:46 
AnswerRe: comparing two dates in javascript Pin
Beginner Luck31-Jan-16 19:24
professionalBeginner Luck31-Jan-16 19:24 
QuestionConvert div into image in Java Script. Pin
varunPes23-Jan-16 2:11
professionalvarunPes23-Jan-16 2:11 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.