Search Results

Search found 23477 results on 940 pages for 'jquery ui sortable'.

Page 7/940 | < Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >

  • Looking into the JQuery Image Zoom Plugin

    - by nikolaosk
    I have been using JQuery for a couple of years now and it has helped me to solve many problems on the client side of web development.  You can find all my posts about JQuery in this link. In this post I will be providing you with a hands-on example on the JQuery Image Zoom Plugin.If you want you can have a look at this post, where I describe the JQuery Cycle Plugin.You can find another post of mine talking about the JQuery Carousel Lite Plugin here.I will be writing more posts regarding the most commonly used JQuery Plugins. I have been using extensively this plugin in my websites.You can use this plugin to move mouse around an image and see a zoomed in version of a portion of it. In this hands-on example I will be using Expression Web 4.0.This application is not a free application. You can use any HTML editor you like. You can use Visual Studio 2012 Express edition. You can download it here.  You can download this plugin from this link I launch Expression Web 4.0 and then I type the following HTML markup (I am using HTML 5) <html lang="en">  <head>    <title>Liverpool Legends</title>        <meta http-equiv="Content-Type" content="text/html;charset=utf-8" >        <link rel="stylesheet" type="text/css" href="style.css">        <script type="text/javascript" src="jquery-1.8.3.min.js"> </script>     <script type="text/javascript" src="jqzoom.pack.1.0.1.js"></script>        <script type="text/javascript">        $(function () {            $(".nicezoom").jqzoom();        });    </script>       </head>  <body>    <header>        <h1>Liverpool Legends</h1>    </header>        <div id="main">            <a href="championsofeurope-large.jpg" class="nicezoom" title="Champions">        <img src="championsofeurope.jpg"  title="Champions">    </a>          </div>            <footer>        <p>All Rights Reserved</p>      </footer>     </body>  </html>   This is a very simple markup. I have added one large and one small image (make sure you use your own when trying this example) I have added references to the JQuery library (current version is 1.8.3) and the JQuery Image Zoom Plugin. Then I add 2 images in the main div element.Note the class nicezoom inside the href element. The Javascript code that makes it all happen follows.    <script type="text/javascript">        $(function () {            $(".nicezoom").jqzoom();        });    </script>     It couldn't be any simpler than that. I view my simple in Internet Explorer 10 and it works as expected. I have tested this simple solution in all major browsers and it works fine.Inside the head section we can add another Javascript script utilising some more options regarding the zoom plugin.   <script type="text/javascript">            $(function () {        var options = {                  zoomType: 'standard',                  lens:true,                  preloadImages: true,                  alwaysOn:false,                  zoomWidth: 400,                  zoomHeight: 350,                  xOffset:190,                  yOffset:80,                  position:'right'                          };          $('.nicezoom').jqzoom(options);      });         </script> I would like to explain briefly what some of those options mean. zoomType - Other admitted option values are 'reverse','drag','innerzoom' zoomWidth - The popup window width showing the zoomed area zoomHeight - The popup window height showing the zoomed area xOffset - The popup window x offset from the small image.  yOffset - The popup window y offset from the small image.  position - The popup window position.Admitted values:'right' ,'left' ,'top' ,'bottom' preloadImages - if set to true,jqzoom will preload large images. You can test it yourself and see the results in your favorite browser. Hope it helps!!!

    Read the article

  • Connect sortable lists together and update SQL using jQuery UI

    - by rebellion
    I'm using jQuery UI's sortable lists to sort items in a todo list, and the reordering of the lists works like a charm. I have several UL lists for each todo category, i.e. Design, Development, etc. I want to be able to move an item from one category to another, and jQuery UI's sortable lists plugin allows me to do this with the connectWith option parameter. But I can't seem to find how to update the database as well. The todo database table has a field for a reference to the category which is laying in it's own table. This is the current code: $('.sortable').sortable({ axis: 'y', opacity: .5, cancel: '.no-tasks', connectWith: '.sortable', update: function(){ $.ajax({ type: 'POST', url: basepath + 'task/sort_list', data: $(this).sortable('serialize') }); } }); Do I need to add another value to the AJAX's data parameter, or do the sortable plugin this for me in the serialize function?

    Read the article

  • how to indicate a change in list elements' order using jquery?

    - by keisimone
    i am using jquery sortable. right now i have a list of items that i can ALREADY use drag and drop. which is cool. i will use a submit button at the bottom of the list to submit the new order. the change in the list is not automatically submitted. All i need is somehow indicate that an element's position has changed. I googled quite a bit. no answer. original list: item1 item2 item3 item4 item5 submitbutton here. changed list: i moved item 2 below item3 for eg. item1 item3 item2 * item4 item5 submitbutton here. how do i use the sortable in jquery for me to display a sign on the item 2? i think should be the change event of sortable but i still do not know how to use it since i am a newbie in jquery. http://docs.jquery.com/UI/Sortable#event-change thank you.

    Read the article

  • JQuery Autocomplete plugin not working with JQuery 1.4.1

    - by Russ Clark
    I've been using the JQuery Autocomplete plugin with JQuery version 1.3.2, and it has been working great. I recently updated JQuery in my project to version 1.4.2, and the Autocomplete plugin is now broken. The JQuery code to add items to a textbox on my web page doesn't seem to be getting called at all. Does anyone know if the JQuery Autocomplete plugin is incompatible with JQuery version 1.4.2, and if there is a fix for this problem? Here is some sample code I've built in an ASP.Net web site (which works fine if I change the JQuery file to jquery-1.3.2.js, but nothing happens using jquery-1.4.2.js): <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title>Untitled Page</title> <script type="text/javascript" src="js/jquery-1.4.2.js" ></script> <script type="text/javascript" src="js/jquery.autocomplete.js" ></script> <script type="text/javascript"> $(document).ready(function() { var data = "Core Selectors Attributes Traversing Manipulation CSS Events Effects Ajax Utilities".split(" "); $(':input:text:id$=sapleUser').autocomplete(data); }); </script> </head> <body> <form id="form1" runat="server"> API Reference: <input id="sapleUser" autocomplete="off" type="text" runat="server" /> (try "C" or "E") </form> </body> </html>

    Read the article

  • jQuery + Sortable + live

    - by user202411
    I'm adding list items to a page dynamically with $.get, then appending them to the OL element. Pretty usual to this point. But jQuery isn't aware of these new items when they get loaded into the page, and I'm not being able to make them sortable. I made some trials with jQuery Live, but didn't get anywhere whit that...

    Read the article

  • JQuery UI Autocomplete - disallow free text entry?

    - by JK
    Is it possible to disallow free text entry in the JQuery UI autocomplete widget? eg I only want the user to be allowed to select from the list of items that are presented in the autocomplete list, and dont want them to be able to write some random text. I didn't see anything in the demos/docs describing how to do this. http://jqueryui.com/demos/autocomplete/ I'm using autocomplete like this $('#selector').autocomplete({ source: url, minlength: 2, select: function (event, ui) { // etc }

    Read the article

  • Do you know why introducing jquery ui autocomplete for my dropdown boxes is also changing my listbox

    - by oo
    I am trying to change my comboboxes to use autocomplete so i leverage the code listed here (which worked perfectly for my dropdowns) The issue is that i also on the same page have a listbox with the following code: <%= Html.ListBox("Cars", Model.BodyParts.Select( x => new SelectListItem { Text = x.Name, Value = x.Id, Selected = Model.CarsSelected.Any(y => y.Id == x.Id) } ))%> and it appears that the jquery ui code is changing this to a autocomplete dropdown as well (as opposed to keeping it as a multi select list box) any idea how to prevent this from happening? i literally am just using the exact code on this page <script type="text/javascript"> (function($) { $.widget("ui.combobox", { _create: function() { var self = this; var select = this.element.hide(); var input = $("<input>") .insertAfter(select) .autocomplete({ source: function(request, response) { var matcher = new RegExp(request.term, "i"); response(select.children("option").map(function() { var text = $(this).text(); if (!request.term || matcher.test(text)) return { id: $(this).val(), label: text.replace(new RegExp("(?![^&;]+;)(?!<[^<>]*)(" + request.term.replace(/([\^\$\(\)\[\]\{\}\*\.\+\?\|\\])/gi, "\\$1") + ")(?![^<>]*>)(?![^&;]+;)", "gi"), "<strong>$1</strong>"), value: text }; })); }, delay: 0, select: function(e, ui) { if (!ui.item) { // remove invalid value, as it didn't match anything $(this).val(""); return false; } $(this).focus(); select.val(ui.item.id); self._trigger("selected", null, { item: select.find("[value='" + ui.item.id + "']") }); }, minLength: 0 }) .addClass("ui-widget ui-widget-content ui-corner-left"); $("<button>&nbsp;</button>") .insertAfter(input) .button({ icons: { primary: "ui-icon-triangle-1-s" }, text: false }).removeClass("ui-corner-all") .addClass("ui-corner-right ui-button-icon") .position({ my: "left center", at: "right center", of: input, offset: "-1 0" }).css("top", "") .click(function() { // close if already visible if (input.autocomplete("widget").is(":visible")) { input.autocomplete("close"); return; } // pass empty string as value to search for, displaying all results input.autocomplete("search", ""); input.focus(); }); } }); })(jQuery); $(function() { $("select").combobox(); }); </script>

    Read the article

  • jQuery UI datepicker customization

    - by Chad
    I have the jQuery datepicker working, but I need to be able to select more than just dates. I need to be able to select between some strings as well "Yesterday" and "Today" to be precise. So, the underlying input can contain any date as well as the strings "Yesterday" or "Today". Is there some way I can do this by tweaking the existing jQuery UI datepicker?

    Read the article

  • jQuery UI sortable issue

    - by colourandcode
    When I try to use a sortable event . (For instance the stop() event) It only works when I bind it using : $('.selector').bind('sortstop', function(event, ui) { ... }); rather than $('.selector').sortable({ stop: function(event, ui) { ... } }); Is there a missing piece in this? The only reason I ask is because when I bind using the actual bind() method it's not giving me access to the event or ui parameters I pass in. I'm always returned undefined.

    Read the article

  • jQuery UI Dialog adding unwanted inline styles to images

    - by oliver
    I am using JQUery UI to for the front end of a rails app I am developing. I am using jQuery dialog windows for displaying some tabbed data and inside one of these tabs I want to render some images. The rendering of the images works fine if I view the page without Javascript, however for some reason when putting it all in a dialog window all but the last image that I render gets some inline styles from somewhere! wihtout the dialog window: <img alt="Dsc_0085" class="picture" src="/system/sources/3/normal/DSC_0085.jpg?1260300748" /> <img alt="Dsc_0006" class="picture" src="/system/sources/4/normal/DSC_0006.jpg?1260301612" /> with the dialog window: <img alt="Dsc_0085" class="picture" src="/system/sources/3/normal/DSC_0085.jpg?1260300748" style="height: 0px; width: 0px; border-top-width: 1px; border-bottom-width: 1px; font-size: 22px; border-left-width: 1px; border-right-width: 1px; display: inline; "> <img alt="Dsc_0006" class="picture" src="/system/sources/4/normal/DSC_0006.jpg?1260301612" style="display: inline; "> I can't work out why putting the images into a dialog window is giving them inline styles with height and width of 0px, does anyone have any ideas?

    Read the article

  • Clear form field after select for jQuery UI Autocomplete

    - by jonfhancock
    I'm developing a form, and using jQuery UI Autocomplete. When the user selects an option, I want the selection to pop into a span appended to the parent <p> tag. Then I want the field to clear rather than be populated with the selection. I have the span appearing just fine, but I can't get the field to clear. How do you cancel jQuery UI Autocomplete's default select action? Here is my code: var availableTags = ["cheese", "milk", "dairy", "meat", "vegetables", "fruit", "grains"]; $("[id^=item-tag-]").autocomplete({ source: availableTags, select: function(){ var newTag = $(this).val(); $(this).val(""); $(this).parent().append("<span>" + newTag + "<a href=\"#\">[x]</a> </span>"); } }); Simply doing $(this).val(""); doesn't work. What is maddening is that almost the exact function works fine if I ignore autocomplete, and just take action when the user types a comma as such: $('[id^=item-tag-]').keyup(function(e) { if(e.keyCode == 188) { var newTag = $(this).val().slice(0,-1); $(this).val(''); $(this).parent().append("<span>" + newTag + "<a href=\"#\">[x]</a> </span>"); } }); The real end result is to get autocomplete to work with multiple selections. If anybody has any suggestions for that, they would be welcome.

    Read the article

  • jquery ui-tabs widget , changing the color of the background with css causes problem with display

    - by Ronedog
    I'm using the jquery tabs plugin and want to have the background a light grey color. In the css section for tabs, I found this line of code where I manually added the background-color part: .ui-tabs .ui-tabs-panel { padding: 1em 1em; display: block; border-width: 0; background-color:#EEEEEE;} The problem comes as seen in the picture below, where the grey background is only extending down part of the way. I initially thought I could update the div container with the same background color, but it didn't work. It looks like that white portion below might be some kind of padding, so I looked for that in the css but everything I tried had the same effect. Anyone got some ideas? This is what the HTML looks like (Theoretically): <div id="tabs_here"> <ul> <li><a href="#" onclick="$('#T_1').html('Display the data');" >Item Groups</a> </li> </ul> <div id="T_1"></div> </div>

    Read the article

  • How to get the child of an element being dragged with jQuery UI

    - by Walden
    I have the following html: <div id="gallery"> <ul> <li> <a href="url I want to get">link</a> </li> </ul> </div> and some jQuery that allows it to be dropped on another div: $trash.droppable({ accept: '#gallery > li', activeClass: 'ui-state-highlight', drop: function(ev, ui) { deleteImage(ui.draggable); var $flickrparenturl = $("a").attr("href"); //only gets href of <li> #1, not <li> being dragged $.post("updateDB.php", { 'flickrparenturl': $flickrparenturl } ); } }); What is the correct way to get the href attribute of the child of the element being dragged? $("a").attr("href"); is only getting the href of the 1st li on the page, not the one being dragged.

    Read the article

  • jQuery UI Tabs animation

    - by Ayrton
    Hi I haven't been able to find a lot of documentation on animating the jQuery UI Tabs, so I'm wondering if anyone knows how to simulate a grow/shrink effect relatively to the current tab I don't really like the height: 'toggle' animation where the tab goes to height 0px first and then the height of the new tab. when tab 1 has a height of 100px and the second a height of 120px I would like the tab to grow 20px

    Read the article

  • load google annotated chart within jquery ui tab content via ajax method

    - by twmulloy
    Hi, I am encountering an issue with trying to load a google annotated chart (http://code.google.com/apis/visualization/documentation/gallery/annotatedtimeline.html) within a jquery ui tab using content via ajax method (http://jqueryui.com/demos/tabs/#ajax). If instead I use the default tabs functionality, writing out the code things work fine: <div id="tabs"> <ul> <li><a href="#tabs-1">Chart</a></li> </ul> <div id="tabs-1"> <script type="text/javascript"> google.load('visualization', '1', {'packages':['annotatedtimeline']}); google.setOnLoadCallback(drawChart); function drawChart() { var data = new google.visualization.DataTable(); data.addColumn('date', 'Date'); data.addColumn('number', 'cloudofinc.com'); data.addColumn('string', 'header'); data.addColumn('string', 'text') data.addColumn('number', 'All Clients'); data.addRows([ [new Date('May 12, 2010'), 2, '2 New Users', '', 3], [new Date('May 13, 2010'), 0, undefined, undefined, 0], [new Date('May 14, 2010'), 0, undefined, undefined, 0], ]); var chart = new google.visualization.AnnotatedTimeLine(document.getElementById('chart_users')); chart.draw(data, { displayAnnotations: false, fill: 10, thickness: 1 }); } </script> <div id='chart_users' style='width: 100%; height: 400px;'></div> </div> </div> But if I use the ajax method for jquery ui tab and point to the partial for the tab, it doesn't work completely. The page renders and once the chart loads, the browser window goes white. However, you can see the tab partial flash just before the chart appears to finish rendering (the chart never actually displays). I have verified that the partial is indeed loading properly without the chart. <div id="tabs"> <ul> <li><a href="ajax/tabs-1">Chart</a></li> </ul> </div>

    Read the article

  • JQuery UI Tabs - "Loading..." message

    - by Balu
    All, I am using Jquery UI nested tabs. I was just wondering if there is any way to display an AJAX Spinner image next to the tab text, while the tab is loading. I do not want to change the tab text to "Loading..". Consider that when multiple tabs are loading at the same time or one after the other, the spinner image should be displayed next to each loading tab.. Any Suggestions? Thanks

    Read the article

  • Ajax-based data loading using jQuery.load() function in ASP.NET

    - by hajan
    In general, jQuery has made Ajax very easy by providing low-level interface, shorthand methods and helper functions, which all gives us great features of handling Ajax requests in our ASP.NET Webs. The simplest way to load data from the server and place the returned HTML in browser is to use the jQuery.load() function. The very firs time when I started playing with this function, I didn't believe it will work that much easy. What you can do with this method is simply call given url as parameter to the load function and display the content in the selector after which this function is chained. So, to clear up this, let me give you one very simple example: $("#result").load("AjaxPages/Page.html"); As you can see from the above image, after clicking the ‘Load Content’ button which fires the above code, we are making Ajax Get and the Response is the entire page HTML. So, rather than using (old) iframes, you can now use this method to load other html pages inside the page from where the script with load function is called. This method is equivalent to the jQuery Ajax Get method $.get(url, data, function () { }) only that the $.load() is method rather than global function and has an implicit callback function. To provide callback to your load, you can simply add function as second parameter, see example: $("#result").load("AjaxPages/Page.html", function () { alert("Page.html has been loaded successfully!") }); Since load is part of the chain which is follower of the given jQuery Selector where the content should be loaded, it means that the $.load() function won't execute if there is no such selector found within the DOM. Another interesting thing to mention, and maybe you've asked yourself is how we know if GET or POST method type is executed? It's simple, if we provide 'data' as second parameter to the load function, then POST is used, otherwise GET is assumed. POST $("#result").load("AjaxPages/Page.html", { "name": "hajan" }, function () { ////callback function implementation });   GET $("#result").load("AjaxPages/Page.html", function () { ////callback function implementation });   Another important feature that $.load() has ($.get() does not) is loading page fragments. Using jQuery's selector capability, you can do this: $("#result").load("AjaxPages/Page.html #resultTable"); In our Page.html, the content now is: So, after the call, only the table with id resultTable will load in our page.   As you can see, we have loaded only the table with id resultTable (1) inside div with id result (2). This is great feature since we won't need to filter the returned HTML content again in our callback function on the master page from where we have called $.load() function. Besides the fact that you can simply call static HTML pages, you can also use this function to load dynamic ASPX pages or ASP.NET ASHX Handlers . Lets say we have another page (ASPX) in our AjaxPages folder with name GetProducts.aspx. This page has repeater control (or anything you want to bind dynamic server-side content) that displays set of data in it. Now, I want to filter the data in the repeater based on the Query String parameter provided when calling that page. For example, if I call the page using GetProducts.aspx?category=computers, it will load only computers… so, this will filter the products automatically by given category. The example ASPX code of GetProducts.aspx page is: <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="GetProducts.aspx.cs" Inherits="WebApplication1.AjaxPages.GetProducts" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title></title> </head> <body> <form id="form1" runat="server"> <div> <table id="tableProducts"> <asp:Repeater ID="rptProducts" runat="server"> <HeaderTemplate> <tr> <th>Product</th> <th>Price</th> <th>Category</th> </tr> </HeaderTemplate> <ItemTemplate> <tr> <td> <%# Eval("ProductName")%> </td> <td> <%# Eval("Price") %> </td> <td> <%# Eval("Category") %> </td> </tr> </ItemTemplate> </asp:Repeater> </ul> </div> </form> </body> </html> The C# code-behind sample code is: public partial class GetProducts : System.Web.UI.Page { public List<Product> products; protected override void OnInit(EventArgs e) { LoadSampleProductsData(); //load sample data base.OnInit(e); } protected void Page_Load(object sender, EventArgs e) { if (Request.QueryString.Count > 0) { if (!string.IsNullOrEmpty(Request.QueryString["category"])) { string category = Request.QueryString["category"]; //get query string into string variable //filter products sample data by category using LINQ //and add the collection as data source to the repeater rptProducts.DataSource = products.Where(x => x.Category == category); rptProducts.DataBind(); //bind repeater } } } //load sample data method public void LoadSampleProductsData() { products = new List<Product>(); products.Add(new Product() { Category = "computers", Price = 200, ProductName = "Dell PC" }); products.Add(new Product() { Category = "shoes", Price = 90, ProductName = "Nike" }); products.Add(new Product() { Category = "shoes", Price = 66, ProductName = "Adidas" }); products.Add(new Product() { Category = "computers", Price = 210, ProductName = "HP PC" }); products.Add(new Product() { Category = "shoes", Price = 85, ProductName = "Puma" }); } } //sample Product class public class Product { public string ProductName { get; set; } public decimal Price { get; set; } public string Category { get; set; } } Mainly, I just have sample data loading function, Product class and depending of the query string, I am filtering the products list using LINQ Where statement. If we run this page without query string, it will show no data. If we call the page with category query string, it will filter automatically. Example: /AjaxPages/GetProducts.aspx?category=shoes The result will be: or if we use category=computers, like this /AjaxPages/GetProducts.aspx?category=computers, the result will be: So, now using jQuery.load() function, we can call this page with provided query string parameter and load appropriate content… The ASPX code in our Default.aspx page, which will call the AjaxPages/GetProducts.aspx page using jQuery.load() function is: <asp:RadioButtonList ID="rblProductCategory" runat="server"> <asp:ListItem Text="Shoes" Value="shoes" Selected="True" /> <asp:ListItem Text="Computers" Value="computers" /> </asp:RadioButtonList> <asp:Button ID="btnLoadProducts" runat="server" Text="Load Products" /> <!-- Here we will load the products, based on the radio button selection--> <div id="products"></div> </form> The jQuery code: $("#<%= btnLoadProducts.ClientID %>").click(function (event) { event.preventDefault(); //preventing button's default behavior var selectedRadioButton = $("#<%= rblProductCategory.ClientID %> input:checked").val(); //call GetProducts.aspx with the category query string for the selected category in radio button list //filter and get only the #tableProducts content inside #products div $("#products").load("AjaxPages/GetProducts.aspx?category=" + selectedRadioButton + " #tableProducts"); }); The end result: You can download the code sample from here. You can read more about jQuery.load() function here. I hope this was useful blog post for you. Please do let me know your feedback. Best Regards, Hajan

    Read the article

  • Looking into the JQuery Carousel Lite Plugin

    - by nikolaosk
    I have been using JQuery for a couple of years now and it has helped me to solve many problems on the client side of web development. You can find all my posts about JQuery in this link. In this post I will be providing you with a hands-on example on the JQuery Carousel Lite Plugin.If you want you can have a look at this post, where I describe the JQuery Cycle Plugin. I will be writing more posts regarding the most commonly used JQuery Plugins. I have been using extensively this plugin in my websites.You can show a portion of a set of images with previous and next navigation.In this hands-on example I will be using Expression Web 4.0.This application is not a free application. You can use any HTML editor you like.You can use Visual Studio 2012 Express edition. You can download it here. You can download this plugin from this linkI launch Expression Web 4.0 and then I type the following HTML markup (I am using HTML 5)<html lang="en">  <head>    <title>Liverpool Legends</title>        <meta http-equiv="Content-Type" content="text/html;charset=utf-8" >        <link rel="stylesheet" type="text/css" href="style.css">        <script type="text/javascript" src="jquery-1.8.3.min.js"> </script>     <script type="text/javascript" src="jcarousellite_1.0.1.min.js"></script>      <script type="text/javascript">        $(function () {            $(".theImages").jCarouselLite({                btnNext: "#Nextbtn",                btnPrev: "#Previousbtn"            });        });    </script>       </head>  <body>    <header>        <h1>Liverpool Legends</h1>    </header>        <div id="main">           <img id="Previousbtn" src="previous.png" />        <div class="theImages">            <ul>                <li><img src="championsofeurope.jpg"></li>                <li><img src="steven_gerrard.jpg"></li>                <li><img src="ynwa.jpg"></li>                <li><img src="dalglish.jpg"></li>                <li><img src="Souness.jpg"></li>                  </ul>    </div>    <img id="Nextbtn" src="next.png" />          </div>            <footer>        <p>All Rights Reserved</p>      </footer>     </body>  </html>  This is a very simple markup. I have added my photos (make sure you use your own when trying this example)I have added references to the JQuery library (current version is 1.8.3) and the JQuery Carousel Lite Plugin. Then I add 5 images in the theImages div element.The Javascript code that makes it all happen follows.  <script type="text/javascript">        $(function () {            $(".theImages").jCarouselLite({                btnNext: "#Nextbtn",                btnPrev: "#Previousbtn"            });        });    </script>I also have added some basic CSS style rules in the style.css file. body{background-color:#efefef;color:#791d22;}       #Previousbtn{position:absolute; left:5px; top:100px;}#Nextbtn {position:absolute; left:812px; top:100px;}.theImages {margin-left:145px;margin-top:10px;} It couldn't be any simpler than that. I view my simple in Internet Explorer 10 and it works as expected.I have tested this simple solution in all major browsers and it works fine.Hope it helps!!!

    Read the article

  • Looking into the JQuery Cycle Plugin

    - by nikolaosk
    I have been using JQuery for a couple of years now and it has helped me to solve many problems on the client. You can find all my posts about JQuery in this link. In this post I will be providing you with a hands-on example on the JQuery Cycle Plugin.I have been using extensively this plugin in my websites.You can rotate a series of images using various transitions with this plugin.It is a slideshow type of experience. I will be writing more posts regarding the most commonly used JQuery Plugins.  In this hands-on example I will be using Expression Web 4.0.This application is not a free application. You can use any HTML editor you like.You can use Visual Studio 2012 Express edition. You can download it here.  You can download this plugin from this link I launch Expression Web 4.0 and then I type the following HTML markup (I am using HTML 5) <!DOCTYPE html><html lang="en">  <head>    <title>Liverpool Legends</title>        <meta http-equiv="Content-Type" content="text/html;charset=utf-8" >            <script type="text/javascript" src="jquery-1.8.3.min.js"> </script>     <script type="text/javascript" src="jquery.cycle.all.js"></script>              <script type="text/javascript">        $(function() {            $('#main').cycle({ fx: 'fade'});        });    </script>       </head>  <body>    <header>        <h1>Liverpool Legends</h1>    </header>        <div id="main">                   <img src="championsofeurope.jpg" alt="Champions of Europe">                        <img src="steven_gerrard.jpg" alt="Steven Gerrard">                        <img src="ynwa.jpg" alt="You will never walk alone">                       </div>            <footer>        <p>All Rights Reserved</p>      </footer>     </body>  </html> This is a very simple markup. I have added three photos (make sure you use your own when trying this example)I have added references to the JQuery library (current version is 1.8.3) and the JQuery Cycle Plugin. Then I have added 3 images in the main div element.The Javascript code that makes it all happen follows.  <script type="text/javascript">        $(function() {            $('#main').cycle({ fx: 'fade'});        });    </script>  It couldn't be any simpler than that. I view my simple in Internet Explorer 10 and it works as expected. I have this series of images transitioning one after the other using the "fade" effect. I have tested this simple solution in all major browsers and it works fine.We can have a different transition effect by changing the JS code. Have a look at the code below       <script type="text/javascript">        $(function() {            $('#main').cycle({                     fx: 'cover',        speed: 500,        timeout: 2000                        });        });    </script>   We set the speed to 500 milliseconds, that is the speed we want to have for the ‘cover’ transition.The timeout is set to two seconds which is the time the photo will show until the next transition will take place.We can customise this plugin further but this is a short introduction to the plugin.Hope it helps!!!

    Read the article

  • z-index not working in IE8 with the sortable jQuery plugin

    - by Ojtwist
    I'm working with the jQuery Sortable plugin to drag and drop images from one box to another box. This works fine in ff,chrome and safari but it fails in IE8. It seems that when you start dragging that the image is send to the back. I've tried to solve this by adding the z-index option to the sortable plugin, i've tried appending it to a node higher in the hierarchy (body). It appears that setting a z-index on every other item in the page would fix this, haven't tried it yet and i'm not planning on doing this because this would mess up alot. So the user can drag an image from 1 gallery to the next gallery screenshot of how it should work: http://img69.imageshack.us/i/draganddrop.jpg/ Some html: <!--SECOND ARROCRDION ITEM --> <a class="flickr_accordeon_header" id="flickr_second_header" href="javascript:;">__MSG__SEARCH_FOR_PHOTOS__</a> <div> <p class ="flickr_text" > __MSG__SEARCH_FOR_PHOTOS__</p> <form method="GET" action="javascript:;"> <p> <input type="text" value="__MSG__SEARCH__" id="flickr_key_input" class="flickr_changeColorNormal" /> <button class="s3d-button flickr_search" id="flickr_seach_button"> <span class="s3d-button-inner" >__MSG__SEARCH__</span> </button> <img src="/devwidgets/flickr/images/ajax-loader-gray.gif" alt="__MSG__LOADING_IMAGE__" id="flickr_loading_img" /> <a href="javascript:;" id="flickr_refresh_key_button"><img src="/dev/_images/recent_activity_icon.png" alt="refresh" title='refresh' /></a> </p> </form> <div id="flickr_input_error">__MSG__INPUT_ERROR__</div> <div id="flickr_input_same_error">__MSG__INPUT_SAME_ERROR__</div> **<div id="flickr_key_gallery" ><ul class="flickr_key_ul"><li></li></ul></div>** <div id="flickr_key_pagging" ></div> </div> </div> <!--SLIDING SIDEBAR --> <div id="flickr_sidebar" class="jcarousel-skin-tango"> <div id="flickr_side_paging"></div> **<ul> <li><img src="/devwidgets/flickr/images/drop-image.png" alt="__MSG__DROP_HERE__" class="flick_drop_here"></li> </ul>** </div> The images get rendered into the ul, so basically it's just an ul with li's with images javascript for sortable: horizontal: { helper: "clone", // Instead of dragging the real image a copy will be dragged connectWith: ["#flickr_sidebar ul"], // To be able to drag and drop an image to another image gallery they need to be connected cursor: 'pointer', //change the cursor when dragging opacity: 0.50, //Change the opacity while dragging appendTo: 'body', //When dropped the images need to be appended to the image gallery where they are dropped containment: 'body', //Make sure the user can't drag the images outside the widget revert: true, // if the user releases the image ouside the dropbox it'll return to it's original position zIndex: 9999 } I've tried it with setting the dragged image to absolute and the container on relative... doesn't work Anyone know how to solve this in IE8 ?

    Read the article

  • Include OpenX ad in a jquery-ui dialog?

    - by planetclaire
    I'm loading some content into a jquery-ui dialog via .ajax. That's all working fine but now I've been given an OpenX ad to embed into the dialog & can't figure out how to do it. I know all the script is stripped when coming in via ajax, & I know how to use $.getScript to load .js files for use in the dialog, but the OpenX ad script I've got uses document.write so I think it's expecting to be embedded inline into the desired position on the page. I've tried appending the escaped script string into the div on ajax success of the main content as below, but this results in the page being redirected to a page with just the ad on it. Attempt shown below: $("#" + idHelpPage).find(".adScript").append("<script type='text/javascript'>var m3_u = (location.protocol=='https:'?'https://d1.openx.org/ajs.php':'http://d1.openx.org/ajs.php');var m3_r = ... etc etc I'm ok with jquery but not great with javascript, would really appreciate any help! Also if you want to see any other code.

    Read the article

  • Undefined Results in jQuery Autocomplete

    - by CreativeNotice
    So I've got the latest versions of jQuery and UI running. I'm using the basic autocomplete invocation and returning valid JSON (validated via JSONLint). $("input#cust_id").autocomplete({ source: yoda.app.base + "/assets/cfc/util/autocomplete.cfc?method=cust", minLength: 2, select: function(event, ui) { log(ui.item ? ("Selected: " + ui.item.value + " aka " + ui.item.id) : "Nothing selected, input was " + this.value); } }); Both the value and label elements of the returned array show up in the list as undefined. I can watch the results returned via Firebug and the JSON is correct there as well. Also, while the list only says "undefined" it does say that the same number of times as records returned in JSON. [{"VALUE":"custid1","LABEL":"My Customer Name 1"},{"VALUE":"custname2","LABEL":"My customer name 2"}]

    Read the article

  • jQuery UI resizable : auto height when using east handle alone

    - by z33m
    i have a jqueryui re-sizable div. I want only the width to be re-sizable and the height to remain auto, so that the div grows or shrinks with the content. If i set it to display only the east handle and use css height:auto, after resize the height also gets set even though only the width changed. I have to set the height to auto on resize event everytime like so: resize: function(event, ui) { $(this).css('height', 'auto'); } to prevent the height from being set. Is there a better way to prevent the height from getting set when only the east handle is used?

    Read the article

< Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >