Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script type="text/javascript" src="jquery.js"></script>
- <script type="text/javascript">
- jQuery(document).ready(function(){
- var client = sessionStorage.getItem('client_cookie');
- if (client != null)
- {
- $.get('/batch_/runBatches_custom.php?client=' + client + '&from=' + ' ' + '&to=' + ' ' + '&period=' + 'Monthly',
- function(data)
- {
- var iframe = document.createElement("iframe");
- $(iframe).css({ 'width' : 400, 'height' : 500 });
- $(iframe).attr("id", "content-iframe");
- $('#cheese').append(iframe);
- var doc = iframe.document;
- if(iframe.contentDocument)
- doc = iframe.contentDocument; // For NS6
- else if(iframe.contentWindow)
- doc = iframe.contentWindow.document; // For IE5.5 and IE6
- // Put the content in the iframe
- doc.open();
- doc.writeln(data);
- doc.close();
- $textBox = $('<input type = "text" id = "textBox" />');
- $textBox.appendTo('#cheese');
- $textBox.css({
- position: 'aboslute',
- top : iframe.position().top -10,
- right: iframe.position().right + (iframe.position.width()/2),
- })
- });
- }
- else
- {
- var textbox = document.createElement("div");
- textbox.innerHTML = "Please go back to Analyst Data and select a valid client.";
- document.getElementById('cheese').appendChild(textbox);
- }
- });
- </script>
Add Comment
Please, Sign In to add comment