Web Design Forum: jlspurling - Viewing Profile - Web Design Forum

Jump to content

WDF
WDF Premium Memberships Reseller Hosting

jlspurling's Profile User Rating: -----

Reputation: 3 Neutral
Group:
Members
Active Posts:
232 (0.19 per day)
Joined:
09-January 09
Profile Views:
8,196
Last Active:
User is offline May 01 2012 01:58 PM
Currently:
Offline

My Information

Member Title:
Dedicated Member
Age:
24 years old
Birthday:
February 3, 1988
Gender:
Not Telling Not Telling

Contact Information

E-mail:
Private
Website URL:
Website URL  http://jolora.co.uk

Users Experience

Experience:
Advanced
Area of Expertise:
Designer/Coder

Posts I've Made

  1. In Topic: Strange bug in iOS

    01 May 2012 - 01:58 PM

    SOLVED: it was an issue with how iOS handles overflow:hidden.
  2. In Topic: Javascript for loop

    27 June 2011 - 11:54 AM

    View PostSpitfire, on 27 June 2011 - 11:17 AM, said:

    .wrapInner() is the wrong function to use. It's meant for putting tags around an element, not adding content.

    Change this line:
    $('.fb_pages').wrapInner(function() {

    To:
    $('.fb_pages').append(function() {




    Thanks so much Spitfire! That seems embarrassingly obvious in retrospect!

    Here is the complete working function:

    function pages() {
    	FB.api('/me/accounts', 'get', {}, function(response) {
    		if(response.data) {
    			for(var i=0,page; page=response.data[i]; i++) {
    				if(page.name) {			
    					$('.fb_pages').append(function() {
      						return '<option value="' + page.id + ' - ' + page.access_token + '">' + page.name + '</option>';
    					});				
    				}
    			}
    		}
    	});
    };