RcBuilder@walla.com
call centre: 054-5614020

angular tracks basic example

Posted by: RcBuilder  /   Category: $http / AngularJS / autocomplete / Controllers / CSS / Data Providers / Directives / Events / Factories / HTML / JAVASCRIPT / jQuery / jquery-ui / Model / module / OOP / Services / Views   /   No Comments
27
Jan
2016

angular tracks basic example app.js var module = angular.module('my-app', ; $scope.tracks = ); } $scope.Search = function () { tracksFactory.searchForTracks($scope.searchPhrase, function (response) { $scope.tracks = response; }); } $scope.LoadAutocomplete = function () { if ($scope.searchPhrase.lengh < 3) return; tracksFactory.getNames($scope.searchPhrase, function (response) { angular.element("#searchPhrase").autocomplete({ source: response }); }); } }); module.factory('tracksFactory', function ($http) { var server = 'http://ws.audioscrobbler.com/2.0/'; var queryBase = '?method=track.search&track={0}&api_key=0604d2c5492dc743997cabe3fd636099&format=json&limit={1}'; var foreach = function (arr, callback) { for (var i = 0; i < arr.length; i++) callback.call(arr); }; return { getNames:.

Read more

angular with jQuery

Posted by: RcBuilder  /   Category: AngularJS / Config / Directives / jQuery / module / Views   /   No Comments
26
Jan
2016

angular with jQuery use jqLite library angular includes a built-in library called jqLite- it's actually a lite weight library based on the known jquery. this library includes only the basics of the jquery library core. the 'element' object is the access point to those libraries. (see 'jqLite available methods' below) note! to transfer to jquery mode, all you need to do.

Read more

jQuery UI datepicker

Posted by: RcBuilder  /   Category: CSS / HTML / JAVASCRIPT / jQuery / Render Block   /   No Comments
17
Nov
2014

jQuery UI datepicker <link rel="stylesheet" type="text/css" href="css/jquery-ui.css" /> <script src="jquery-1.4.2.min.js" type="text/javascript"></script> <script src="jquery-ui.min.js" type="text/javascript"></script> <asp:TextBox ID="txtDate" runat="server" /> <script type="text/javascript"> $(document).ready(function(){ $("#<%=txtDate.ClientID %>").datepicker({ showOn: 'button', buttonImageOnly: true, buttonImage: 'images/calendar_trading.png', dateFormat: 'dd/mm/yy' }); $("#<%=txtDate.ClientID %>").datepicker("option", "firstDay",.

Read more

disable enter key

Posted by: RcBuilder  /   Category: events / form / HTML / JAVASCRIPT / jQuery / onkeydown event   /   No Comments
16
Nov
2014

disable enter key <form onkeydown="return DisabledEnter(event);"> .... .... </form> ------------------------------------------------ function DisabledEnter(e) { var evt = e || window.event return evt.keyCode !=.

Read more

option javascript class

Posted by: RcBuilder  /   Category: append / Array / HTML / JAVASCRIPT / jQuery / onchange / select   /   No Comments
09
Nov
2014

option javascript class OPTION CLASS function option(text, value) { this.text = text; this.value = value; this.toTag = toTag; function toTag() { return '<option value="' + this.value + '">' + this.text + '</option>'; } } HTML <select id="cmbMaster" onchange="LoadSlaveCombo(this.value);" style="width:130px;"> <option value="males">males</option> <option value="females">females</option> </select> <select id="cmbSlave" style="width:130px;"></select> USING // two levels selects // fill slave combo refer to master combo selection var arr_names = new Array(); arr_names = ; arr_names = ; function LoadSlaveCombo(type) { var cmb = $('#cmbSlave'); var arr.

Read more

javascript CLOCK

Posted by: RcBuilder  /   Category: CSS / HTML / HTML 5 / JAVASCRIPT / jQuery / setTimeout / span   /   No Comments
09
Nov
2014

javascript CLOCK CLOCK CLASS function CLOCK(targetName, options) { var that = this; var time = new Date(); var target = $('#' + targetName); var intervalInSeconds = options.interval || 1; var autoStart = options.autoStart || true; if (options.startTime) SetTime(options.startTime); var timer = null; this.Start = Start; this.Stop = Stop; if (autoStart) Start(); function SetTime(startTime) { try{ var time_parts = startTime.split(':'); var hh = parseInt(time_parts); var mm = parseInt(time_parts); var ss = parseInt(time_parts); if (isNaN(hh) || isNaN(mm).

Read more

jQuery Counters – count page elements

Posted by: RcBuilder  /   Category: a / body / children / div / each / HTML / JAVASCRIPT / jQuery / not / size / span / tagName   /   No Comments
20
Oct
2014

jQuery Counters - count page elements html <html xmlns="http://www.w3.org/1999/xhtml"> <head> <script type="text/javascript" src="jquery-1.5.2.min.js"></script> </head> <body> <a limited="1">LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a>LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a limited="1">LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a>LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a limited="1">LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a limited="0">LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a limited="1">LINK</a> <br /><br /> <span>SPAN</span>&nbsp;&nbsp;|&nbsp;&nbsp; <span limited="1">SPAN</span>&nbsp;&nbsp;|&nbsp;&nbsp; <span limited="1">SPAN</span>&nbsp;&nbsp;|&nbsp;&nbsp; <span>SPAN</span> </body> </html> counters // 14 (all elements within the body element) alert($('body').children('*').size()); // 18 (all tags including head, script etc.) alert($('*').size()); // 7 (all non link elements within the body element) alert($('body').children('*').not('a').size()); using $('body').children('*').each(function () { alert(this.tagName);.

Read more

jquery custom attributes

Posted by: RcBuilder  /   Category: a / body / CSS / css / HTML / JAVASCRIPT / jQuery / span   /   No Comments
20
Oct
2014

jquery custom attributes jquery script <script type="text/javascript" src="jquery-1.5.2.min.js"></script> HTML <a limited="1">LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a>LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a limited="1">LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a>LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a limited="1">LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a limited="0">LINK</a>&nbsp;&nbsp;|&nbsp;&nbsp; <a limited="1">LINK</a> <br /><br /> <span>SPAN</span>&nbsp;&nbsp;|&nbsp;&nbsp; <span limited="1">SPAN</span>&nbsp;&nbsp;|&nbsp;&nbsp; <span limited="1">SPAN</span>&nbsp;&nbsp;|&nbsp;&nbsp; <span>SPAN</span> script // all elements in the document have the attribute limited set to value 1 $('').css('color', 'blue'); // all elements in the document have the attribute limited set to value 1 $('body > ').css('color',.

Read more

jQuery ajax – status codes, json and http methods PUT POST GET DELETE

Posted by: RcBuilder  /   Category: AJAX / each / JAVASCRIPT / jQuery / JSON / Request   /   No Comments
12
Oct
2014

jQuery ajax - status codes, json and http methods PUT POST GET DELETE USING JSON $.ajax({ type: 'POST', url: '/api/users', // dataType: 'json', data: { Id: 145, FirstName: 'Roby', LastName: '2222', Age: 32 }, success: function (data) { $('<div>' + data.FirstName + '</div>').appendTo('#divUsers'); }, error: function (xhr) { alert('STATUS = ' + xhr.status); } }); USING STATUS CODES $.ajax({ type: 'POST', url: '/api/users', dataType: 'json', data: { Id: 145, FirstName: 'Roby', LastName: '2222', Age:.

Read more
12
  • פיתוח מערכות
  • פתרונות טכנולוגים
  • קידום אתרים
  • בניית אתרים