User:Serkan: Difference between revisions
From FANTOM5_SSTAR
No edit summary |
No edit summary |
||
(37 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
<html> | <html> | ||
<script type="text/javascript" language="javascript" src="/resource_browser/rb_js/datatables/media/js/jquery.dataTables.min.js"></script> | |||
<script type="text/javascript" language="javascript" src="/resource_browser/rb_js/datatables/extras/TableTools/media/js/TableTools.min.js"></script> | |||
<style type="text/css" title="currentStyle"> | <style type="text/css" title="currentStyle"> | ||
@import "/resource_browser/rb_js/datatables/media/css/jquery.dataTables.css"; | @import "/resource_browser/rb_js/datatables/media/css/jquery.dataTables.css"; | ||
@import "/resource_browser/rb_js/datatables/extras/TableTools/media/css/TableTools.css"; | |||
</style> | </style> | ||
<script type="text/javascript"> | <script type="text/javascript"> | ||
$(document).ready(function() { | $(document).ready(function() { | ||
$('.known_motif_list').dataTable( { | motif_table=$('.known_motif_list').dataTable( { | ||
"iDisplayLength": | "iDisplayLength": 50, | ||
"aLengthMenu": [[25, 100, -1], [25, 100, "All"]], | "aLengthMenu": [[25, 100, -1], [25, 100, "All"]], | ||
"aaSorting": [[1, "asc"]], | "aaSorting": [[1, "asc"]], | ||
Line 14: | Line 16: | ||
{ "aTargets": [5], | { "aTargets": [5], | ||
"fnRender": function (obj ) { | "fnRender": function (obj ) { | ||
var uri =logoLocator($(obj.aData[0]).text(),$(obj.aData[0]).text()); | |||
return uri; | |||
} | } | ||
} | }, | ||
{"aTargets":[2], "fnRender": function ( obj ) { | |||
var motif_id = $(obj.aData[ obj.iDataColumn ]).text(); | |||
var motif_prefix = motif_id ; | |||
var motif_db = obj.aData[obj.iDataColumn-1]; | |||
var sReturn =motif_db+"_motif:"+motif_id; | |||
return '<a href=/resource_browser/'+sReturn+'>'+motif_id+'</a>';} | |||
}, | |||
{"aTargets":[1], "fnRender": function ( obj ) { | |||
var temp= $(obj.aData[ obj.iDataColumn ]).text(); | |||
return temp;} | |||
}, | |||
{"aTargets":[4], "fnRender": function ( obj ) { | |||
var temp= $(obj.aData[ obj.iDataColumn ]).text(); | |||
return parseFloat(temp).toFixed(5); } | |||
} | |||
] | ] | ||
} ); | } ); | ||
$('.dataTables_scrollBody').css("resize", "vertical"); | |||
motif_table_tools = new TableTools( motif_table, {"sSwfPath": "/resource_browser/rb_js/datatables/extras/TableTools/media/swf/copy_csv_xls_pdf.swf", "aButtons": [ {"sExtends": "copy", "mColumns": "visible"}, {"sExtends": "csv", "mColumns": "visible"}, {"sExtends": "pdf", "mColumns": "visible"} ]}); | |||
$('#motif_export_tool').before( motif_table_tools.dom.container ); | |||
} ); | } ); | ||
function hasWhiteSpace(s) { | |||
return s.indexOf(' ') >= 0; | |||
} | |||
function logoLocator(motif_db,motif_id){ | function logoLocator(motif_db,motif_id){ | ||
var | var index = motif_id.indexOf(' '); | ||
var tmp = " | |||
return '<img src=" | if (index >= 0) { | ||
motif_id= motif_id.substr(0, index - 1) +"_"+ motif_id.substr(index); | |||
} | |||
var tmp ="/resource_browser/seqlogos/"+ "known_motifs"+"_201304"+"/"+motif_id.toLowerCase()+".png"; | |||
var uri = encodeURI(tmp); | |||
return number_prefix='<img src="'+uri+'" width ="80" height = "20">'; | |||
} | } | ||
Line 49: | Line 83: | ||
else if(motif_db == "ENCODE"){ | else if(motif_db == "ENCODE"){ | ||
number_prefix = "683"; | number_prefix = "683"; | ||
} | |||
else if(motif_db == "KNOWN"){ | |||
number_prefix="11" | |||
} | } | ||
return number_prefix; | return number_prefix; | ||
Line 56: | Line 93: | ||
</html> | </html> | ||
{NAMESPACE}}<br> | |||
{{PAGENAME}}<br> | |||
{{BASEPAGENAME}}<br> | |||
{{BASEPAGENAMEE}}<br> | |||
{{SUBPAGENAME}} <br> | |||
{{SUBPAGENAMEE}}<br> | |||
{{FULLPAGENAME}}<br> | |||
{{TALKSPACE}} <br> | |||
{{TALKPAGENAME}} <br> | |||
{{SUBJECTSPACE}}<br> | |||
{{ARTICLESPACE}}<br> | |||
{{SUBJECTPAGENAME}}<br> | |||
{{ARTICLEPAGENAME}}<br> | |||
<span id = "motif_export_tool"></span> | |||
{{#ask:[[Category:MotifCluster2013March]] | {{#ask:[[Category:MotifCluster2013March]] | ||
|?Database=motif db | |?Database=motif db | ||
Line 66: | Line 117: | ||
|class=known_motif_list | |class=known_motif_list | ||
|offset=0 | |offset=0 | ||
|limit= | |limit=1000 | ||
|mainlabel=name | |mainlabel=name | ||
}} | }} | ||
Latest revision as of 17:11, 20 May 2013
{NAMESPACE}}
Serkan
Serkan
Serkan
Serkan
Serkan
User:Serkan
User talk
User talk:Serkan
User
User
User:Serkan
User:Serkan