NIMBUZZ TOOLS FORUM-2016
Kєяλℓλ-ßυzZ ►☻◄ ƒøяυλ⁄(-2016

✽✽✽✽✽✽✽✽✽✽✽✽ нι gυєѕт ✽✽✽✽✽✽✽✽✽✽✽✽✽✽

♚♚♚♚ωєℓ¢σмє тσ ♚kєяαℓα♕ßυzz♚ zσηє♚♚♚♚

ρℓєαѕє яєgιѕтєя тσ gєт ƒυℓℓ α¢¢єѕѕ αη∂ ∂σωηℓσα∂ ѕтυƒƒ . σηℓү яεgιsтεяε∂ мεмвεя αℓℓσωε∂ vιεω sρεcιαℓ zσηε αη∂ ∂σωηℓσα∂ sтυғғ.

тнαηк уσυ

вαℓυ кяιsнηα !
Latest topics
hacked any id facebook with my new soft Thu Jul 19, 2018 6:23 pmdeadtargetXio server botMon Jul 16, 2018 11:26 pmdeadtargetnew soft frezz any id and room wonderfulllllllllllllllllllllllllllll جديدنا تجميد اي نك نيمبوز او شات بلاس بالاضافة لتجميد رومات النيمبوزFri Jul 13, 2018 12:54 pmsofee95new codes for flood and frezz rooms amd id maker just for programer Fri Jul 13, 2018 12:48 pmsofee95Working Aurora Bot 2018Wed Jul 11, 2018 9:45 pmltc_mktRUN PYTHON BOTS LIKE AURORA / BLACKSMITH BOT IN YOUR ANDROID PHONESun Jul 08, 2018 1:22 pmltc_mktOnline server botFri Jul 06, 2018 6:08 pmltc_mktFloood 2019Mon Jun 18, 2018 5:10 pmgaber90000kpv serverTue Jun 12, 2018 2:51 pmabhePrime server Tue Jun 12, 2018 1:45 pmabheبرنامج تخمين سريع جدا للنيمبوز والشات بلاس 2019Sun Jun 10, 2018 5:55 amkoko777flood for Android too speed برنامج فلود رومات نيمبوز 2018 للاندرويدFri Apr 13, 2018 12:58 amkoko777هديه للجميع 500 نك فلوود قديم شغالين 500 old ids flood freeWed Apr 11, 2018 6:19 pmafndena_7200new soft flood brocking server 2018 فلود رومات جديد بعد التحديث Sat Mar 31, 2018 12:42 amkoko777 Kbz: id maker newFri Mar 09, 2018 4:49 pmshakir0 Server: 24/7 Server botsTue Mar 06, 2018 8:23 pmmoh000madDeathly add flooder all room chat+ professionalTue Feb 27, 2018 1:06 pm.3madvideo : Break the room protection chatp + nimbuzz / فيديو كسر حماية غرف الشات بلس ونمبوزSat Feb 24, 2018 12:57 pm.3madFlooder Sender Dc Chat+ 2018 (beta)Sun Feb 11, 2018 5:55 pm.3madWolF Flooder Chatp+ 2018 V.2 / فلود لشات بلس الاصدار الثانيFri Feb 09, 2018 3:04 pm.3mad
Top posters
330 Posts - 27%
284 Posts - 23%
127 Posts - 10%
107 Posts - 9%
69 Posts - 6%
54 Posts - 4%
53 Posts - 4%
53 Posts - 4%
51 Posts - 4%
Top posting users this week
Top posting users this month
3 Posts - 38%
3 Posts - 38%
2 Posts - 25%

Share
Go down
avatar
KßZ ►☻◄ ƒøяυλ⁄(-αđмιиιѕтяαтσя
KßZ ►☻◄ ƒøяυλ⁄(-αđмιиιѕтяαтσя
Male
BALU KRISHNA
AGE : 30
POSTS : 330
REPUTATION : 48
KBZ TEAM POINTS : 924
JOIN DATE : 2013-12-04
BIRTHDAY : 1988-05-15
LOCATION : India , kerala
View user profilehttp://kbzteam.forums1.net

Javascript: Forum "Add as friend" option in topic

on Mon Nov 30, 2015 10:31 am


Tutorial: "Add as friend" option in topic

This tutorial will allow you to add people as friends from the topics, rather than visiting their profiles and clicking add as friend button.


--> Tutorials, tips and tricks <--
"Add as friend" option in topic



- Javascript
Placement In the topic

Code:
[panda=js]$(function() {
      if (!_userdata.session_logged_in) {
          return false;
      }
      var FFinPosts = {
          sFriend: "Add As Friend",
          sFoes: "Add To Foes",
          oTarget: $('.post'),
          iLen: 0,
          sUser_name: "",
          oFF_list: null,
          aFF_list: [],
          vTemp: null,
          oThis: null
      };
      FFinPosts.iLen = FFinPosts.oTarget.length;

      $.ajax({
          url: "/u" + _userdata.user_id + 'friends',
          cache: false,
          type: "get",
          dataType: "text",
          success: function(response, status, xhr) {
            if (xhr.status == 200) {
                FFinPosts.oFF_list = $('#profile-advanced-details ol .message-header > a[href^="/u"]', response);

                for (var i = 0; i < FFinPosts.oFF_list.length; i++) {
                  FFinPosts.aFF_list[FFinPosts.aFF_list.length] = $(FFinPosts.oFF_list[i]).text();
                }

                for (var i = 0; i < FFinPosts.iLen; i++) {
                  FFinPosts.oThis = $(FFinPosts.oTarget[i]);
                  FFinPosts.sUser_name = FFinPosts.oThis.find('.author a, .name, .user a[href^="/u"]').text();

                  if (FFinPosts.sUser_name !== _userdata.username) {
                      FFinPosts.vTemp = FFinPosts.oThis.find('.postprofile dd:last, .postdetails.poster-profile, .user-contact');

                      if (FFinPosts.aFF_list.indexOf(FFinPosts.sUser_name) == -1) {

                        FFinPosts.vTemp.append(
                            '<a class="profile-icon" href="/profile?friend=' + encodeURIComponent(FFinPosts.sUser_name) + '&mode=editprofile&page_profil=friendsfoes">' +
                            '  <img title="Add As Friend" alt="Add As Friend" src="https://cdn2.iconfinder.com/data/icons/gnomeicontheme/16x16/apps/im-msn.png" width="16" height="16">' +
                            '</a>'
                        )
                      } else {
                        FFinPosts.vTemp.append(
                            '<a class="profile-icon" href="/profile?foe=' + encodeURIComponent(FFinPosts.sUser_name) + '&mode=editprofile&page_profil=friendsfoes">' +
                            '  <img title="Add To Foes" alt="Add To Foes" src="http://icons.iconarchive.com/icons/oxygen-icons.org/oxygen/16/Actions-list-remove-user-icon.png">' +
                            '</a>'
                        )
                      }
                  }
                }
            }
          }
      });
    });


- Preview



  • Forum Creator :  balu♥krishna

    *  How do I change my settings?
    *  How do I add a signature to my post?
    *  How do I show an image below my username?
    *  How do I change my rank?
    *  How do I post a topic in a forum?
    *  Can I post Images?

    IF YOU HAVE ANY DOUBTS LIKE THIS THEN [You must be registered and logged in to see this link.]
    OR ADD ME ON [You must be registered and logged in to see this link.]
    CHEERZ...
    [You must be registered and logged in to see this link.]


Back to top
Permissions in this forum:
You cannot reply to topics in this forum