Code Junkie

ASP.Net, AJAX, jQuery and T-SQL Posts

  • Update Bubble Count For Filtered Lists - jQuery Mobile

    When using the Filtered List search (http://jquerymobile.com/demos/1.0/docs/lists/lists-search.html) and the Bubble Count (http://jquerymobile.com/demos/1.0/docs/lists/lists-count.html) in the jQuery Mobile interface the bubble count number doesn't auto-populate/auto-update. This is something you need to add yourself. It would seem to me that this should be simple enough to do myself and with a little event binding this can all be fixed.

    Read more...

  • jQuery Mobile Search Filter Bar - Programmatically Search

    I ran across another issue when trying to filter a list using jQuery Mobile's Filtered List (http://jquerymobile.com/demos/1.0/docs/lists/lists-search.html) The functionality itself is really nice, jQuery framework does all the heavy lifting for you. All you need to do is create a <UL> or <OL> and add the attributes data-role="listview" data-filter="true" to the tag and your off. The problem I encountered, I wanted to programmatically execute the filter. On my page I had a number of re-populated search terms that I wanted to provide the users. Clicking on the button would pop the search string into the search input box. The problem was, adding the search string to the box wasn't enough. It required some event to trigger in order to filter the list down. After digging around and trial and error I found that a simple keyup event in the search box worked.

    Read more...

  • jQuery Mobile

    I am starting to get my feet wet with jQuery Mobile and find the lack of documentation frustrating. I will be patient as I know that this is a new framework. But to help anyone running up against my frustration I will start posting issues and solutions that I have come accross.

    Read more...

  • SharePoint System Dialogs and Customized MasterPages

    Anyone who has tried to brand and customize SharePoint know what kind of madness and headaches that go along with it. Just when you think that your masterpage looks good you click into a deep dark subpage that makes your layout look hideous. Although things were made easier in 2010, for some reason I could never get the modal dialog pages look quite right. I finally determined that I wanted to just have those look OTB. I still wanted the system pages to have the branding, i just wanted to remove my branding from the dialogs. so with a little jaavscript/jquery calls, viola. First off you need to have set your branded system master page up with the proper class="s4-notdlg". This will allow sharepoint to hide headers, footers, quicklaunch, etc. But this doesn't remove the margins, paddings, and special layouts that may throw off the dialog layout. Mine, for instance, looked like this...

    Read more...

  • Simple jQuery Content Rotator

    jQuery to the rescue, again, to make my javascript coding life easy. What I needed was a simple text rotator. I went looking for some good examples of jQuery rotators and found a ton of great examples. Who knew it would be this easy?

    Read more...

  • Add Label To jQuery Slider Handle

    While in process of using the jQuery UI Slider in creating an alpha slider for a rolodex interface I came across some desired UI enhancements. Instead of having a slider that was plain i want to add the current value of the slider to interface. A quick simple line to the slider function gave me my desired appearance.

    Read more...

  • Hide The Default SharePoint Content Libraries/Lists *HACK*

    Recently for a client I created a custom Document Library that is specific to their organization. After creating it I wanted to hide the standard document library that comes with SharePoint. I don't want to delete it, just hide it so it can't be accidentally created. Here in lies my problem. I search high and low for a possible solution. While waiting to here back from the SharePoint blog team, I decided try and find a workaround. This is what I came up with. 

    I decided to look at the actually aspx page that you see when you select "Create" from the site content area. I thought maybe I can hide the fields as they are created on this page.  The file is called "/_layouts/create.aspx" and can be found at "C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\LAYOUTS". If you go down to line 158 you can see the code setting a string variable to the list template name. I found gold. After this line is where I inserted my nasty little hack.

    //IF YOU WANT TO HIDE CERTAIN LIBRARIES FROM BEING AVAILABLE
    if ((strTemplateDisplayName == "Document Library") || (strTemplateDisplayName == "Translation Management Library"))
    continue;

    This will hide the libraries from the view of the user. Just be aware that this might break if there is a Service Pack and/or Patch applied for SharePoint.

    If you can shed some light on a better way please, let me know.

    Read more...