jQuery(window).bind("load", function() {
	if (jQuery(".ycodaslider").length) {
	
		// el slider del portfolio
		jQuery(".ycodaslider").eq(0).ycodaslider({
			easeFunc: "easeOutBack",
			easeTime: 750,
			shortcut: [37, 39]
		}).end();
	}
	if (jQuery(".conocimientos").length) {
		//Cargamos los tabs
		loadjscssfile("/includes/jscripts/jquery/ijquery/ijquery.css", "css") ////dynamically load and add this .css file
		jQuery('.conocimientos').itabs('h3');
	}
	
	//Para los img transparentes
	//jQuery("div.yslider-navl , div.yslider-navr").ifixpng();
	// para los scroll
	jQuery('.scrollToID').click(function(e){
		jQuery.scrollTo($(this).attr('href'), {
			speed: 2500
		});
		return false;
	});
		
		
});



function loadjscssfile(filename, filetype){
 if (filetype=="js"){ //if filename is a external JavaScript file
  var fileref=document.createElement('script')
  fileref.setAttribute("type","text/javascript")
  fileref.setAttribute("src", filename)
 }
 else if (filetype=="css"){ //if filename is an external CSS file
  var fileref=document.createElement("link")
  fileref.setAttribute("rel", "stylesheet")
  fileref.setAttribute("type", "text/css")
  fileref.setAttribute("href", filename)
 }
 if (typeof fileref!="undefined")
  document.getElementsByTagName("head")[0].appendChild(fileref)
}
// pruebas
//loadjscssfile("myscript.js", "js") //dynamically load and add this .js file
//loadjscssfile("javascript.php", "js") //dynamically load "javascript.php" as a JavaScript file
//loadjscssfile("mystyle.css", "css") ////dynamically load and add this .css file

