-
Notifications
You must be signed in to change notification settings - Fork 0
/
UserProfileViewController.swift
48 lines (32 loc) · 1.07 KB
/
UserProfileViewController.swift
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
//
// UserProfileViewController.swift
// InsTag
//
// Created by student8 on 05/01/15.
// Copyright (c) 2015 student8. All rights reserved.
//
import UIKit
class UserProfileViewController : UIViewController{
var followers : String!
var following : String!
var posts: String!
var userPhotoUrl : String!
var userName : String!
@IBOutlet weak var profileImage: UIImageView!
@IBOutlet weak var postsLabel: UILabel!
@IBOutlet weak var followersLabel: UILabel!
@IBOutlet weak var followingLabel: UILabel!
@IBOutlet weak var isFollowingLabel: UILabel!
@IBOutlet weak var isFollowYouLabel: UILabel!
override func viewDidLoad() {
super.viewDidLoad()
if let nsurl = NSURL(string: userPhotoUrl) {
if let nsdata = NSData(contentsOfURL: nsurl) {
profileImage.image = UIImage(data: nsdata)
}
}
followingLabel.text = following
followersLabel.text = followers
postsLabel.text = posts
}
}