Hi,
I am using $.ig.loader to dynamically load resources on the webpage and then I take advantage of igButton to style some of the buttons. The problem is that there is a noticeable lag between when the button first appears in the browser and when the style is applied, yielding unwanted user experience. Can I reference the CSS directly and style the button in HTML? Can you provide an example? Or is there a better way to approach this (maybe make the button invisible by default)?
Thank you,
Daniel
Hello Daniel,
It's good approach to make button invisible as you suggest.
You can build them at run-time as well.
Here is example code:
$.ig.loader(function () {
$("<button id=\"myButton\"></button>").appendTo("body");
$("#myButton").igButton();
});
Regadrs,
Stanimir Todorov
Stanimir,
I would still like to see a solution that bypasses $.ig.loader and igButton() if possible.
Thanks,
To use the igButton you are required to use igButton() to activate it.
Instead of using $.ig.loader you can load the scripts manual.
<script src="scripts/jquery-1.4.4.js" type="text/javascript"></script>
<
script
src
="scripts/jquery-1.4.4.js"
type
="text/javascript"
></
>
<script src="scripts/jquery-ui.js" type="text/javascript"></script>
"scripts/jquery-ui.js"
"text/javascript"
<script src="scripts/infragistics.js" type="text/javascript"></script>
"scripts/infragistics.js"
</
<link href="css/themes/infragistics/infragistics.theme.css" rel="stylesheet" type="text/css" />
link
href
="css/themes/infragistics/infragistics.theme.css"
rel
="stylesheet"
="text/css"
/>
<link href="css/structure/infragistics.css" rel="stylesheet" type="text/css" />
="css/structure/infragistics.css"
<script>
(function() {
</script>
Stanimir