No regular expressions were active.
1 |
|
<?
|
|
1 |
|
<?
|
2 |
|
|
|
2 |
|
|
3 |
|
/*********
**********
**********
**********
**********
**********
**********
******
|
|
3 |
|
/*********
**********
**********
**********
**********
**********
**********
******
|
4 |
|
*
D
olphin Sma
rt Communi
ty Builder
|
|
4 |
|
*
D
olphin Sma
rt Communi
ty Builder
|
5 |
|
*
---------
--------
|
|
5 |
|
*
---------
--------
|
6 |
|
* begi
n
: M
on Mar 23
2006
|
|
6 |
|
* begi
n
: M
on Mar 23
2006
|
7 |
|
* copy
right
: (
C) 2006 Bo
onEx Group
|
|
7 |
|
* copy
right
: (
C) 2006 Bo
onEx Group
|
8 |
|
* webs
ite
: h
ttp://www.
boonex.com
/
|
|
8 |
|
* webs
ite
: h
ttp://www.
boonex.com
/
|
9 |
|
* This fil
e is part
of Dolphin
- Smart C
ommunity B
uilder
|
|
9 |
|
* This fil
e is part
of Dolphin
- Smart C
ommunity B
uilder
|
10 |
|
*
|
|
10 |
|
*
|
11 |
|
* Dolphin
is free so
ftware. Th
is work is
licensed
under a Cr
eative Com
mons Attri
bution 3.0
License.
|
|
11 |
|
* Dolphin
is free so
ftware. Th
is work is
licensed
under a Cr
eative Com
mons Attri
bution 3.0
License.
|
12 |
|
* http://c
reativecom
mons.org/l
icenses/by
/3.0/
|
|
12 |
|
* http://c
reativecom
mons.org/l
icenses/by
/3.0/
|
13 |
|
*
|
|
13 |
|
*
|
14 |
|
* Dolphin
is distrib
uted in th
e hope tha
t it will
be useful,
but WITHO
UT ANY WAR
RANTY;
|
|
14 |
|
* Dolphin
is distrib
uted in th
e hope tha
t it will
be useful,
but WITHO
UT ANY WAR
RANTY;
|
15 |
|
* without
even the i
mplied war
ranty of
MERCHANTAB
ILITY or F
ITNESS FOR
A PARTICU
LAR PURPOS
E.
|
|
15 |
|
* without
even the i
mplied war
ranty of
MERCHANTAB
ILITY or F
ITNESS FOR
A PARTICU
LAR PURPOS
E.
|
16 |
|
* See the
Creative C
ommons Att
ribution 3
.0 License
for more
details.
|
|
16 |
|
* See the
Creative C
ommons Att
ribution 3
.0 License
for more
details.
|
17 |
|
* You shou
ld have re
ceived a c
opy of the
Creative
Commons At
tribution
3.0 Licens
e along wi
th Dolphin
,
|
|
17 |
|
* You shou
ld have re
ceived a c
opy of the
Creative
Commons At
tribution
3.0 Licens
e along wi
th Dolphin
,
|
18 |
|
* see lice
nse.txt fi
le; if not
, write to
marketing
@boonex.co
m
|
|
18 |
|
* see lice
nse.txt fi
le; if not
, write to
marketing
@boonex.co
m
|
19 |
|
**********
**********
**********
**********
**********
**********
**********
*****/
|
|
19 |
|
**********
**********
**********
**********
**********
**********
**********
*****/
|
20 |
|
|
|
20 |
|
|
21 |
|
require_on
ce( 'inc/h
eader.inc.
php' );
|
|
21 |
|
require_on
ce( 'inc/h
eader.inc.
php' );
|
22 |
|
require_on
ce( BX_DIR
ECTORY_PAT
H_INC . 'd
esign.inc.
php' );
|
|
22 |
|
require_on
ce( BX_DIR
ECTORY_PAT
H_INC . 'd
esign.inc.
php' );
|
23 |
|
require_on
ce( BX_DIR
ECTORY_PAT
H_INC . 'p
rofiles.in
c.php' );
|
|
23 |
|
require_on
ce( BX_DIR
ECTORY_PAT
H_INC . 'p
rofiles.in
c.php' );
|
24 |
|
require_on
ce( BX_DIR
ECTORY_PAT
H_INC . 'u
tils.inc.p
hp' );
|
|
24 |
|
require_on
ce( BX_DIR
ECTORY_PAT
H_INC . 'u
tils.inc.p
hp' );
|
25 |
|
|
|
25 |
|
|
26 |
|
// -------
-------- p
age variab
les and lo
gin
|
|
26 |
|
// -------
-------- p
age variab
les and lo
gin
|
27 |
|
|
|
27 |
|
|
28 |
|
$_page['na
me_index']
= 129;
|
|
28 |
|
$_page['na
me_index']
= 129;
|
29 |
|
$_page['cs
s_name']
= 'con
tacts.css'
;
|
|
29 |
|
$_page['cs
s_name']
= 'con
tacts.css'
;
|
30 |
|
|
|
30 |
|
|
31 |
|
$logged['m
ember'] =
member_aut
h(0);
|
|
31 |
|
$logged['m
ember'] =
member_aut
h(0);
|
32 |
|
|
|
32 |
|
|
33 |
|
$memberID
= (int)$_C
OOKIE['mem
berID'];
|
|
33 |
|
$memberID
= (int)$_C
OOKIE['mem
berID'];
|
34 |
|
|
|
34 |
|
|
35 |
|
$_page['he
ader'] = _
t( "_My Co
ntacts" );
|
|
35 |
|
$_page['he
ader'] = _
t( "_My Co
ntacts" );
|
36 |
|
$_page['he
ader_text'
] = _t( "_
My Contact
s" );
|
|
36 |
|
$_page['he
ader_text'
] = _t( "_
My Contact
s" );
|
37 |
|
|
|
37 |
|
|
38 |
|
$free_mode
= getPara
m("free_mo
de") == "o
n" ? 1 : 0
;
|
|
38 |
|
$free_mode
= getPara
m("free_mo
de") == "o
n" ? 1 : 0
;
|
39 |
|
|
|
39 |
|
|
40 |
|
$_ni = $_p
age['name_
index'];
|
|
40 |
|
$_ni = $_p
age['name_
index'];
|
41 |
|
|
|
41 |
|
|
42 |
|
|
|
42 |
|
|
43 |
|
// do acti
ons
|
|
43 |
|
// do acti
ons
|
44 |
|
if( $_POST
['HotList_
i_del'] )
del
FromList(
'HotList',
'ID
', 'Pr
ofile' );
|
|
44 |
|
if( $_POST
['HotList_
i_del'] )
del
FromList(
'HotList',
'ID
', 'Pr
ofile' );
|
45 |
|
if( $_POST
['FriendLi
st_i_del']
) del
FromList(
'FriendLis
t', 'ID
', 'Pr
ofile' );
|
|
45 |
|
if( $_POST
['FriendLi
st_i_del']
) del
FromList(
'FriendLis
t', 'ID
', 'Pr
ofile' );
|
46 |
|
if( $_POST
['BlockLis
t_i_del']
) del
FromList(
'BlockList
', 'ID
', 'Pr
ofile' );
|
|
46 |
|
if( $_POST
['BlockLis
t_i_del']
) del
FromList(
'BlockList
', 'ID
', 'Pr
ofile' );
|
47 |
|
if( $_POST
['VKisses_
i_del'] )
del
FromList(
'VKisses',
'ID
', 'Me
mber' );
|
|
47 |
|
if( $_POST
['VKisses_
i_del'] )
del
FromList(
'VKisses',
'ID
', 'Me
mber' );
|
48 |
|
if( $_POST
['Profiles
Track_i_de
l'] ) del
FromList(
'ProfilesT
rack', 'Me
mber', 'Pr
ofile' );
|
|
48 |
|
if( $_POST
['Profiles
Track_i_de
l'] ) del
FromList(
'ProfilesT
rack', 'Me
mber', 'Pr
ofile' );
|
49 |
|
|
|
49 |
|
|
50 |
|
if( $_POST
['VKisses_
me_del'] )
del
FromList(
'VKisses',
'Me
mber', 'I
D' );
|
|
50 |
|
if( $_POST
['VKisses_
me_del'] )
del
FromList(
'VKisses',
'Me
mber', 'I
D' );
|
51 |
|
if( $_POST
['FriendLi
st_me_del'
] ) del
FromList(
'FriendLis
t', 'Pr
ofile', 'I
D' );
|
|
51 |
|
if( $_POST
['FriendLi
st_me_del'
] ) del
FromList(
'FriendLis
t', 'Pr
ofile', 'I
D' );
|
52 |
|
if( $_POST
['Profiles
Track_me_d
el'] ) del
FromList(
'ProfilesT
rack', 'Pr
ofile', 'M
ember' );
|
|
52 |
|
if( $_POST
['Profiles
Track_me_d
el'] ) del
FromList(
'ProfilesT
rack', 'Pr
ofile', 'M
ember' );
|
53 |
|
|
|
53 |
|
|
54 |
|
if( $_POST
['FriendLi
st__del']
) del
FromList(
'FriendLis
t', 'ID
', 'Pr
ofile', tr
ue );
|
|
54 |
|
if( $_POST
['FriendLi
st__del']
) del
FromList(
'FriendLis
t', 'ID
', 'Pr
ofile', tr
ue );
|
55 |
|
|
|
55 |
|
|
56 |
|
if( $_POST
['HotList_
me_add'] )
add
ToList(
'HotList',
'ID
', 'Pr
ofile' );
|
|
56 |
|
if( $_POST
['HotList_
me_add'] )
add
ToList(
'HotList',
'ID
', 'Pr
ofile' );
|
57 |
|
if( $_POST
['BlockLis
t_me_add']
) add
ToList(
'BlockList
', 'ID
', 'Pr
ofile' );
|
|
57 |
|
if( $_POST
['BlockLis
t_me_add']
) add
ToList(
'BlockList
', 'ID
', 'Pr
ofile' );
|
58 |
|
|
|
58 |
|
|
59 |
|
if( $_POST
['FriendLi
st_me_add'
] ) app
roveFriend
Invites();
|
|
59 |
|
if( $_POST
['FriendLi
st_me_add'
] ) app
roveFriend
Invites();
|
60 |
|
|
|
60 |
|
|
61 |
|
|
|
61 |
|
|
62 |
|
switch( $_
GET['show'
] )
|
|
62 |
|
switch( $_
GET['show'
] )
|
63 |
|
{
|
|
63 |
|
{
|
64 |
|
case '
hot':
|
|
64 |
|
case '
hot':
|
65 |
|
if
( $_GET['l
ist'] != '
me' )
|
|
65 |
|
if
( $_GET['l
ist'] != '
me' )
|
66 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Hot
List', 'ID
', 'Profil
e' );
|
|
66 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Hot
List', 'ID
', 'Profil
e' );
|
67 |
|
if
( $_GET['l
ist'] != '
i' )
|
|
67 |
|
if
( $_GET['l
ist'] != '
i' )
|
68 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Ho
tList', 'P
rofile', '
ID' );
|
|
68 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Ho
tList', 'P
rofile', '
ID' );
|
69 |
|
break;
|
|
69 |
|
break;
|
70 |
|
case '
friends_in
v':
|
|
70 |
|
case '
friends_in
v':
|
71 |
|
if
( $_GET['l
ist'] != '
me' )
|
|
71 |
|
if
( $_GET['l
ist'] != '
me' )
|
72 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Fri
endList',
'ID', 'Pro
file', '',
'AND `Che
ck`=0' );
|
|
72 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Fri
endList',
'ID', 'Pro
file', '',
'AND `Che
ck`=0' );
|
73 |
|
if
( $_GET['l
ist'] != '
i' )
|
|
73 |
|
if
( $_GET['l
ist'] != '
i' )
|
74 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Fr
iendList',
'Profile'
, 'ID', ''
, 'AND `Ch
eck`=0' );
|
|
74 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Fr
iendList',
'Profile'
, 'ID', ''
, 'AND `Ch
eck`=0' );
|
75 |
|
break;
|
|
75 |
|
break;
|
76 |
|
case '
friends':
|
|
76 |
|
case '
friends':
|
77 |
|
$r
et .= Page
CompListMe
mbers( '',
'FriendLi
st', 'Prof
ile', 'ID'
, '', 'AND
`Check`=1
' );
|
|
77 |
|
$r
et .= Page
CompListMe
mbers( '',
'FriendLi
st', 'Prof
ile', 'ID'
, '', 'AND
`Check`=1
' );
|
78 |
|
break;
|
|
78 |
|
break;
|
79 |
|
case '
block':
|
|
79 |
|
case '
block':
|
80 |
|
if
( $_GET['l
ist'] != '
me' )
|
|
80 |
|
if
( $_GET['l
ist'] != '
me' )
|
81 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Blo
ckList', '
ID', 'Prof
ile' );
|
|
81 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Blo
ckList', '
ID', 'Prof
ile' );
|
82 |
|
if
( $_GET['l
ist'] != '
i' )
|
|
82 |
|
if
( $_GET['l
ist'] != '
i' )
|
83 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Bl
ockList',
'Profile',
'ID' );
|
|
83 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Bl
ockList',
'Profile',
'ID' );
|
84 |
|
break;
|
|
84 |
|
break;
|
85 |
|
case '
greet':
|
|
85 |
|
case '
greet':
|
86 |
|
if
( $_GET['l
ist'] != '
me' )
|
|
86 |
|
if
( $_GET['l
ist'] != '
me' )
|
87 |
|
$ret .=
PageCompLi
stMembers(
'i', 'VKi
sses', 'ID
', 'Member
', ', `Arr
ived`, `Nu
mber`', ''
, '`Arrive
d` DESC, '
);
|
|
87 |
|
$ret .=
PageCompLi
stMembers(
'i', 'VKi
sses', 'ID
', 'Member
', ', `Arr
ived`, `Nu
mber`', ''
, '`Arrive
d` DESC, '
);
|
88 |
|
if
( $_GET['l
ist'] != '
i' )
|
|
88 |
|
if
( $_GET['l
ist'] != '
i' )
|
89 |
|
$ret .=
PageCompLi
stMembers(
'me', 'VK
isses', 'M
ember', 'I
D', ', `Ar
rived`, `N
umber`, `N
ew`', '',
'`Arrived`
DESC, ' )
;
|
|
89 |
|
$ret .=
PageCompLi
stMembers(
'me', 'VK
isses', 'M
ember', 'I
D', ', `Ar
rived`, `N
umber`, `N
ew`', '',
'`Arrived`
DESC, ' )
;
|
90 |
|
break;
|
|
90 |
|
break;
|
91 |
|
case '
view':
|
|
91 |
|
case '
view':
|
92 |
|
if
( $_GET['l
ist'] != '
me' )
|
|
92 |
|
if
( $_GET['l
ist'] != '
me' )
|
93 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Pro
filesTrack
', 'Member
', 'Profil
e', ', `Ar
rived`', '
', '`Arriv
ed` DESC,
' );
|
|
93 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Pro
filesTrack
', 'Member
', 'Profil
e', ', `Ar
rived`', '
', '`Arriv
ed` DESC,
' );
|
94 |
|
if
( $_GET['l
ist'] != '
i' )
|
|
94 |
|
if
( $_GET['l
ist'] != '
i' )
|
95 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Pr
ofilesTrac
k', 'Profi
le', 'Memb
er', ', `A
rrived`',
'', '`Arri
ved` DESC,
' );
|
|
95 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Pr
ofilesTrac
k', 'Profi
le', 'Memb
er', ', `A
rrived`',
'', '`Arri
ved` DESC,
' );
|
96 |
|
break;
|
|
96 |
|
break;
|
97 |
|
case '
all':
|
|
97 |
|
case '
all':
|
98 |
|
defaul
t:
|
|
98 |
|
defaul
t:
|
99 |
|
if
( $_GET['l
ist'] != '
me' )
|
|
99 |
|
if
( $_GET['l
ist'] != '
me' )
|
100 |
|
{
|
|
100 |
|
{
|
101 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Hot
List', 'ID
', 'Profil
e' );
|
|
101 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Hot
List', 'ID
', 'Profil
e' );
|
102 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Fri
endList',
'ID', 'Pro
file', '',
'AND `Che
ck`=0' );
|
|
102 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Fri
endList',
'ID', 'Pro
file', '',
'AND `Che
ck`=0' );
|
103 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Blo
ckList', '
ID', 'Prof
ile' );
|
|
103 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Blo
ckList', '
ID', 'Prof
ile' );
|
104 |
|
$ret .=
PageCompLi
stMembers(
'i', 'VKi
sses', 'ID
', 'Member
', ', `Arr
ived`, `Nu
mber`', ''
, '`Arrive
d` DESC, '
);
|
|
104 |
|
$ret .=
PageCompLi
stMembers(
'i', 'VKi
sses', 'ID
', 'Member
', ', `Arr
ived`, `Nu
mber`', ''
, '`Arrive
d` DESC, '
);
|
105 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Pro
filesTrack
', 'Member
', 'Profil
e', ', `Ar
rived`', '
', '`Arriv
ed` DESC,
' );
|
|
105 |
|
$ret .=
PageCompLi
stMembers(
'i', 'Pro
filesTrack
', 'Member
', 'Profil
e', ', `Ar
rived`', '
', '`Arriv
ed` DESC,
' );
|
106 |
|
}
|
|
106 |
|
}
|
107 |
|
|
|
107 |
|
|
108 |
|
if
( $_GET['l
ist'] != '
i' )
|
|
108 |
|
if
( $_GET['l
ist'] != '
i' )
|
109 |
|
{
|
|
109 |
|
{
|
110 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Ho
tList', 'P
rofile', '
ID' );
|
|
110 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Ho
tList', 'P
rofile', '
ID' );
|
111 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Fr
iendList',
'Profile'
, 'ID', ''
, 'AND `Ch
eck`=0' );
|
|
111 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Fr
iendList',
'Profile'
, 'ID', ''
, 'AND `Ch
eck`=0' );
|
112 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Bl
ockList',
'Profile',
'ID' );
|
|
112 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Bl
ockList',
'Profile',
'ID' );
|
113 |
|
$ret .=
PageCompLi
stMembers(
'me', 'VK
isses', 'M
ember', 'I
D', ', `Ar
rived`, `N
umber`, `N
ew`', '',
'`Arrived`
DESC, ' )
;
|
|
113 |
|
$ret .=
PageCompLi
stMembers(
'me', 'VK
isses', 'M
ember', 'I
D', ', `Ar
rived`, `N
umber`, `N
ew`', '',
'`Arrived`
DESC, ' )
;
|
114 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Pr
ofilesTrac
k', 'Profi
le', 'Memb
er', ', `A
rrived`',
'', '`Arri
ved` DESC,
' );
|
|
114 |
|
$ret .=
PageCompLi
stMembers(
'me', 'Pr
ofilesTrac
k', 'Profi
le', 'Memb
er', ', `A
rrived`',
'', '`Arri
ved` DESC,
' );
|
115 |
|
}
|
|
115 |
|
}
|
116 |
|
|
|
116 |
|
|
117 |
|
$r
et .= Page
CompListMe
mbers( '',
'FriendLi
st', 'Prof
ile', 'ID'
, '', 'AND
`Check`=1
' );
|
|
117 |
|
$r
et .= Page
CompListMe
mbers( '',
'FriendLi
st', 'Prof
ile', 'ID'
, '', 'AND
`Check`=1
' );
|
118 |
|
}
|
|
118 |
|
}
|
119 |
|
|
|
119 |
|
|
120 |
|
$_page_con
t[$_ni]['p
age_main_c
ode'] = $r
et;
|
|
120 |
|
$_page_con
t[$_ni]['p
age_main_c
ode'] = $r
et;
|
121 |
|
|
|
121 |
|
|
122 |
|
send_heade
rs_page_ch
anged();
|
|
122 |
|
send_heade
rs_page_ch
anged();
|
123 |
|
PageCode()
;
|
|
123 |
|
PageCode()
;
|
124 |
|
|
|
124 |
|
|
125 |
|
function P
ageCompLis
tMembers(
$list, $ta
ble, $sqlW
ho, $sqlWh
om, $sqlSe
lectAdd =
'', $sqlWh
ereAdd = '
', $sqlOrd
erAdd = ''
)
|
|
125 |
|
function P
ageCompLis
tMembers(
$list, $ta
ble, $sqlW
ho, $sqlWh
om, $sqlSe
lectAdd =
'', $sqlWh
ereAdd = '
', $sqlOrd
erAdd = ''
)
|
126 |
|
{
|
|
126 |
|
{
|
127 |
|
global
$memberID
;
|
|
127 |
|
global
$memberID
;
|
128 |
|
global
$site;
|
|
128 |
|
global
$site;
|
129 |
|
global
$dir;
|
|
|
130 |
|
global
$tmpl;
|
|
129 |
|
global
$tmpl;
|
131 |
|
|
|
130 |
|
|
132 |
|
$form
= "{$table
}_{$list}"
;
|
|
131 |
|
$form
= "{$table
}_{$list}"
;
|
133 |
|
|
|
132 |
|
|
134 |
|
if( $l
ist == ''
)
|
|
133 |
|
if( $l
ist == ''
)
|
135 |
|
{
|
|
134 |
|
{
|
136 |
|
$q
uery = "
|
|
135 |
|
$q
uery = "
|
137 |
|
SELECT
|
|
136 |
|
SELECT
|
138 |
|
IF(
`$table`.`
$sqlWho` =
$memberID
, `$table`
.`$sqlWhom
`, `$table
`.`$sqlWho
` ) AS `$s
qlWhom`,
|
|
137 |
|
IF(
`$table`.`
$sqlWho` =
$memberID
, `$table`
.`$sqlWhom
`, `$table
`.`$sqlWho
` ) AS `$s
qlWhom`,
|
139 |
|
`Pro
files`.`Ni
ckName`
|
|
138 |
|
`Pro
files`.`Ni
ckName`
|
140 |
|
$sql
SelectAdd
|
|
139 |
|
$sql
SelectAdd
|
141 |
|
FROM `$t
able`
|
|
140 |
|
FROM `$t
able`
|
142 |
|
LEFT JOI
N `Profile
s`
|
|
141 |
|
LEFT JOI
N `Profile
s`
|
143 |
|
ON `
Profiles`.
`ID` = IF(
`$table`.
`$sqlWho`
= $memberI
D, `$table
`.`$sqlWho
m`, `$tabl
e`.`$sqlWh
o` )
|
|
142 |
|
ON `
Profiles`.
`ID` = IF(
`$table`.
`$sqlWho`
= $memberI
D, `$table
`.`$sqlWho
m`, `$tabl
e`.`$sqlWh
o` )
|
144 |
|
WHERE
|
|
143 |
|
WHERE
|
145 |
|
( `$
table`.`$s
qlWho` = $
memberID O
R `$table`
.`$sqlWhom
` = $membe
rID )
|
|
144 |
|
( `$
table`.`$s
qlWho` = $
memberID O
R `$table`
.`$sqlWhom
` = $membe
rID )
|
146 |
|
$sql
WhereAdd
|
|
145 |
|
$sql
WhereAdd
|
147 |
|
ORDER BY
$sqlOrder
Add `Profi
les`.`Nick
Name` ASC
|
|
146 |
|
ORDER BY
$sqlOrder
Add `Profi
les`.`Nick
Name` ASC
|
148 |
|
";
|
|
147 |
|
";
|
149 |
|
}
|
|
148 |
|
}
|
150 |
|
else
|
|
149 |
|
else
|
151 |
|
{
|
|
150 |
|
{
|
152 |
|
$q
uery = "
|
|
151 |
|
$q
uery = "
|
153 |
|
SELECT
|
|
152 |
|
SELECT
|
154 |
|
`$ta
ble`.`$sql
Who`,
|
|
153 |
|
`$ta
ble`.`$sql
Who`,
|
155 |
|
`$ta
ble`.`$sql
Whom`,
|
|
154 |
|
`$ta
ble`.`$sql
Whom`,
|
156 |
|
`Pro
files`.`Ni
ckName`
|
|
155 |
|
`Pro
files`.`Ni
ckName`
|
157 |
|
$sql
SelectAdd
|
|
156 |
|
$sql
SelectAdd
|
158 |
|
FROM `$t
able`
|
|
157 |
|
FROM `$t
able`
|
159 |
|
LEFT JOI
N `Profile
s`
|
|
158 |
|
LEFT JOI
N `Profile
s`
|
160 |
|
ON `
Profiles`.
`ID` = `$t
able`.`$sq
lWhom`
|
|
159 |
|
ON `
Profiles`.
`ID` = `$t
able`.`$sq
lWhom`
|
161 |
|
WHERE
|
|
160 |
|
WHERE
|
162 |
|
`$ta
ble`.`$sql
Who` = $me
mberID
|
|
161 |
|
`$ta
ble`.`$sql
Who` = $me
mberID
|
163 |
|
$sql
WhereAdd
|
|
162 |
|
$sql
WhereAdd
|
164 |
|
ORDER BY
$sqlOrder
Add `Profi
les`.`Nick
Name` ASC
|
|
163 |
|
ORDER BY
$sqlOrder
Add `Profi
les`.`Nick
Name` ASC
|
165 |
|
";
|
|
164 |
|
";
|
166 |
|
}
|
|
165 |
|
}
|
167 |
|
|
|
166 |
|
|
168 |
|
$rMemb
ers = db_r
es( $query
);
|
|
167 |
|
$rMemb
ers = db_r
es( $query
);
|
169 |
|
if( $n
um_res = m
ysql_num_r
ows( $rMem
bers ) )
|
|
168 |
|
if( $n
um_res = m
ysql_num_r
ows( $rMem
bers ) )
|
170 |
|
{
|
|
169 |
|
{
|
171 |
|
$sWhole
=
file_get_c
ontents(
"
{$dir['roo
t']}
templates/
tmpl_{$tmp
l}/contact
s_tmpl.htm
l"
);
|
|
170 |
|
$sWhole
=
file_get_c
ontents(
BX_DIRECTO
RY_PATH_RO
OT
.
"
templates/
tmpl_{$tmp
l}/contact
s_tmpl.htm
l"
);
|
172 |
|
|
|
171 |
|
|
173 |
|
$a
MyTmpl = p
reg_split(
"/\{\/?In
sertRows\}
/", $sWhol
e );
|
|
172 |
|
$a
MyTmpl = p
reg_split(
"/\{\/?In
sertRows\}
/", $sWhol
e );
|
174 |
|
$t
mplRow = $
aMyTmpl[1]
;
|
|
173 |
|
$t
mplRow = $
aMyTmpl[1]
;
|
175 |
|
$s
Whole = "
{$aMyTmpl[
0]}{Insert
Rows /}{$a
MyTmpl[2]}
";
|
|
174 |
|
$s
Whole = "
{$aMyTmpl[
0]}{Insert
Rows /}{$a
MyTmpl[2]}
";
|
176 |
|
|
|
175 |
|
|
177 |
|
$I
nsertRows
= '';
|
|
176 |
|
$I
nsertRows
= '';
|
178 |
|
$t
r_class =
'odd';
|
|
177 |
|
$t
r_class =
'odd';
|
179 |
|
wh
ile( $aMem
ber = mysq
l_fetch_as
soc( $rMem
bers ) )
|
|
178 |
|
wh
ile( $aMem
ber = mysq
l_fetch_as
soc( $rMem
bers ) )
|
180 |
|
{
|
|
179 |
|
{
|
181 |
|
$aReplac
e = array(
);
|
|
180 |
|
$aReplac
e = array(
);
|
182 |
|
|
|
181 |
|
|
183 |
|
$aReplac
e['ID']
=
$aMember[
$sqlWhom];
|
|
182 |
|
$aReplac
e['ID']
=
$aMember[
$sqlWhom];
|
184 |
|
$aReplac
e['CheckBo
xName'] =
"mem[{$aM
ember[$sql
Whom]}]";
|
|
183 |
|
$aReplac
e['CheckBo
xName'] =
"mem[{$aM
ember[$sql
Whom]}]";
|
185 |
|
|
|
184 |
|
|
186 |
|
if( $aMe
mber[$sqlW
hom] > 0 )
|
|
185 |
|
if( $aMe
mber[$sqlW
hom] > 0 )
|
187 |
|
{
|
|
186 |
|
{
|
188 |
|
$aRe
place['Thu
mbnail']
= get_m
ember_icon
( $aMember
[$sqlWhom]
, 'left' )
;
|
|
187 |
|
$aRe
place['Thu
mbnail']
= get_m
ember_icon
( $aMember
[$sqlWhom]
, 'left' )
;
|
189 |
|
$aRe
place['Nic
kName']
= "<a h
ref=\"".ge
tProfileLi
nk($aMembe
r[$sqlWhom
])."\">{$a
Member['Ni
ckName']}<
/a>";
|
|
188 |
|
$aRe
place['Nic
kName']
= "<a h
ref=\"".ge
tProfileLi
nk($aMembe
r[$sqlWhom
])."\">{$a
Member['Ni
ckName']}<
/a>";
|
190 |
|
$aRe
place['Sen
dGreet']
= sendK
issPopUp(
$aMember[$
sqlWhom] )
;
|
|
189 |
|
$aRe
place['Sen
dGreet']
= sendK
issPopUp(
$aMember[$
sqlWhom] )
;
|
191 |
|
|
|
190 |
|
|
192 |
|
$aRe
place['Sen
dMsg']
= "
|
|
191 |
|
$aRe
place['Sen
dMsg']
= "
|
193 |
|
<a
href=\"{$
site['url'
]}compose.
php?ID={$a
Member[$sq
lWhom]}\"
title=\"".
_t('_Send
Message').
"\">
|
|
192 |
|
<a
href=\"{$
site['url'
]}compose.
php?ID={$a
Member[$sq
lWhom]}\"
title=\"".
_t('_Send
Message').
"\">
|
194 |
|
<img src=\
"".getTemp
lateIcon(
'compose.p
ng' )."\"
alt=\""._t
('_Send Me
ssage')."\
" />
|
|
193 |
|
<img src=\
"".getTemp
lateIcon(
'compose.p
ng' )."\"
alt=\""._t
('_Send Me
ssage')."\
" />
|
195 |
|
</
a>";
|
|
194 |
|
</
a>";
|
196 |
|
|
|
195 |
|
|
197 |
|
}
|
|
196 |
|
}
|
198 |
|
else
|
|
197 |
|
else
|
199 |
|
{
|
|
198 |
|
{
|
200 |
|
$aRe
place['Thu
mbnail']
= '' ;
|
|
199 |
|
$aRe
place['Thu
mbnail']
= '' ;
|
201 |
|
$aRe
place['Nic
kName']
= _t( '
_Visitor'
);
|
|
200 |
|
$aRe
place['Nic
kName']
= _t( '
_Visitor'
);
|
202 |
|
$aRe
place['Sen
dGreet']
= '';
|
|
201 |
|
$aRe
place['Sen
dGreet']
= '';
|
203 |
|
$aRe
place['Sen
dMsg']
= '';
|
|
202 |
|
$aRe
place['Sen
dMsg']
= '';
|
204 |
|
}
|
|
203 |
|
}
|
205 |
|
|
|
204 |
|
|
206 |
|
$aReplac
e['Times']
=
$aMember[
'Number']
? _t( "_N
times", $a
Member['Nu
mber'] ) :
' ';
|
|
205 |
|
$aReplac
e['Times']
=
$aMember[
'Number']
? _t( "_N
times", $a
Member['Nu
mber'] ) :
' ';
|
207 |
|
$aReplac
e['PicNew'
] =
$aMember[
'New'] ? '
<img src="
'.getTempl
ateIcon('n
ew.gif').'
" class="p
ic_new" />
' : '';
|
|
206 |
|
$aReplac
e['PicNew'
] =
$aMember[
'New'] ? '
<img src="
'.getTempl
ateIcon('n
ew.gif').'
" class="p
ic_new" />
' : '';
|
208 |
|
$aReplac
e['Date']
=
$aMember[
'Arrived']
? $aMembe
r['Arrived
'] : '&nbs
p;';
|
|
207 |
|
$aReplac
e['Date']
=
$aMember[
'Arrived']
? $aMembe
r['Arrived
'] : '&nbs
p;';
|
209 |
|
$aReplac
e['tr_clas
s'] =
$tr_class
;
|
|
208 |
|
$aReplac
e['tr_clas
s'] =
$tr_class
;
|
210 |
|
|
|
209 |
|
|
211 |
|
$sInsert
Row = $tmp
lRow;
|
|
210 |
|
$sInsert
Row = $tmp
lRow;
|
212 |
|
foreach(
$aReplace
as $key =
> $val )
|
|
211 |
|
foreach(
$aReplace
as $key =
> $val )
|
213 |
|
$sIn
sertRow =
str_replac
e( "{{$key
}}", $val,
$sInsertR
ow );
|
|
212 |
|
$sIn
sertRow =
str_replac
e( "{{$key
}}", $val,
$sInsertR
ow );
|
214 |
|
|
|
213 |
|
|
215 |
|
$sInsert
Rows .= $s
InsertRow;
|
|
214 |
|
$sInsert
Rows .= $s
InsertRow;
|
216 |
|
$tr_clas
s = ( $tr_
class == '
odd' ? 'ev
en' : 'odd
' );
|
|
215 |
|
$tr_clas
s = ( $tr_
class == '
odd' ? 'ev
en' : 'odd
' );
|
217 |
|
}
|
|
216 |
|
}
|
218 |
|
|
|
217 |
|
|
219 |
|
|
|
218 |
|
|
220 |
|
$a
Replace =
array();
|
|
219 |
|
$a
Replace =
array();
|
221 |
|
|
|
220 |
|
|
222 |
|
$a
Replace['I
nsertRows
/'] = $sIn
sertRows;
|
|
221 |
|
$a
Replace['I
nsertRows
/'] = $sIn
sertRows;
|
223 |
|
$a
Replace['S
elf']
= $_SE
RVER['PHP_
SELF'] . '
?show=' .
$_GET['sho
w'] . '&am
p;list=' .
$_GET['li
st'];
|
|
222 |
|
$a
Replace['S
elf']
= $_SE
RVER['PHP_
SELF'] . '
?show=' .
$_GET['sho
w'] . '&am
p;list=' .
$_GET['li
st'];
|
224 |
|
$a
Replace['F
ormName']
= "{$f
orm}_form"
;
|
|
223 |
|
$a
Replace['F
ormName']
= "{$f
orm}_form"
;
|
225 |
|
$a
Replace['C
heckAll']
= _t('
_Check all
');
|
|
224 |
|
$a
Replace['C
heckAll']
= _t('
_Check all
');
|
226 |
|
$a
Replace['U
ncheckAll'
] = _t('
_Uncheck a
ll');
|
|
225 |
|
$a
Replace['U
ncheckAll'
] = _t('
_Uncheck a
ll');
|
227 |
|
$a
Replace['A
ctions']
= getB
uttons( $f
orm );
|
|
226 |
|
$a
Replace['A
ctions']
= getB
uttons( $f
orm );
|
228 |
|
|
|
227 |
|
|
229 |
|
fo
reach( $aR
eplace as
$key => $v
al )
|
|
228 |
|
fo
reach( $aR
eplace as
$key => $v
al )
|
230 |
|
$sWhole
= str_repl
ace( "{{$k
ey}}", $va
l, $sWhole
);
|
|
229 |
|
$sWhole
= str_repl
ace( "{{$k
ey}}", $va
l, $sWhole
);
|
231 |
|
|
|
230 |
|
|
232 |
|
//
unset "ne
w" flag fo
r kisses
|
|
231 |
|
//
unset "ne
w" flag fo
r kisses
|
233 |
|
if
( $table =
= 'VKisses
' and $lis
t == 'me'
)
|
|
232 |
|
if
( $table =
= 'VKisses
' and $lis
t == 'me'
)
|
234 |
|
db_res(
"UPDATE `V
Kisses` SE
T `New`='0
' WHERE `M
ember`=$me
mberID AND
`New`='1'
" );
|
|
233 |
|
db_res(
"UPDATE `V
Kisses` SE
T `New`='0
' WHERE `M
ember`=$me
mberID AND
`New`='1'
" );
|
235 |
|
}
|
|
234 |
|
}
|
236 |
|
else
|
|
235 |
|
else
|
237 |
|
{
|
|
236 |
|
{
|
238 |
|
$sWhole
=
file_get_c
ontents(
"
{$dir['roo
t']}
templates/
tmpl_{$tmp
l}/contact
s_tmpl_nor
es.html"
);
|
|
237 |
|
$sWhole
=
file_get_c
ontents(
BX_DIRECTO
RY_PATH_RO
OT
.
"
templates/
tmpl_{$tmp
l}/contact
s_tmpl_nor
es.html"
);
|
239 |
|
$a
Replace =
array();
|
|
238 |
|
$a
Replace =
array();
|
240 |
|
|
|
239 |
|
|
241 |
|
$a
Replace['N
oResults']
= _t('_No
members f
ound here'
);
|
|
240 |
|
$a
Replace['N
oResults']
= _t('_No
members f
ound here'
);
|
242 |
|
|
|
241 |
|
|
243 |
|
fo
reach( $aR
eplace as
$key => $v
al )
|
|
242 |
|
fo
reach( $aR
eplace as
$key => $v
al )
|
244 |
|
$sWhole
= str_repl
ace( "{{$k
ey}}", $va
l, $sWhole
);
|
|
243 |
|
$sWhole
= str_repl
ace( "{{$k
ey}}", $va
l, $sWhole
);
|
245 |
|
}
|
|
244 |
|
}
|
246 |
|
|
|
245 |
|
|
247 |
|
$sWhol
e = str_re
place( '{T
ableCaptio
n}', getTa
bleName( $
form, $num
_res ), $s
Whole );
|
|
246 |
|
$sWhol
e = str_re
place( '{T
ableCaptio
n}', getTa
bleName( $
form, $num
_res ), $s
Whole );
|
248 |
|
return
$sWhole;
|
|
247 |
|
return
$sWhole;
|
249 |
|
}
|
|
248 |
|
}
|
250 |
|
|
|
249 |
|
|
251 |
|
function g
etTableNam
e( $form,
$num_res )
|
|
250 |
|
function g
etTableNam
e( $form,
$num_res )
|
252 |
|
{
|
|
251 |
|
{
|
253 |
|
switch
( $form )
|
|
252 |
|
switch
( $form )
|
254 |
|
{
|
|
253 |
|
{
|
255 |
|
ca
se 'HotLis
t_i':
$ret =
_t( '_MEMB
ERS_YOU_HO
TLISTED' )
; break;
|
|
254 |
|
ca
se 'HotLis
t_i':
$ret =
_t( '_MEMB
ERS_YOU_HO
TLISTED' )
; break;
|
256 |
|
ca
se 'Friend
List_i':
$ret =
_t( '_MEMB
ERS_INVITE
_YOU_FRIEN
DLIST' );
break;
|
|
255 |
|
ca
se 'Friend
List_i':
$ret =
_t( '_MEMB
ERS_INVITE
_YOU_FRIEN
DLIST' );
break;
|
257 |
|
ca
se 'BlockL
ist_i':
$ret =
_t( '_MEMB
ERS_YOU_BL
OCKLISTED'
); break;
|
|
256 |
|
ca
se 'BlockL
ist_i':
$ret =
_t( '_MEMB
ERS_YOU_BL
OCKLISTED'
); break;
|
258 |
|
ca
se 'VKisse
s_i':
$ret =
_t( '_MEMB
ERS_YOU_KI
SSED' ); b
reak;
|
|
257 |
|
ca
se 'VKisse
s_i':
$ret =
_t( '_MEMB
ERS_YOU_KI
SSED' ); b
reak;
|
259 |
|
ca
se 'Profil
esTrack_i'
: $ret =
_t( '_MEMB
ERS_YOU_VI
EWED' ); b
reak;
|
|
258 |
|
ca
se 'Profil
esTrack_i'
: $ret =
_t( '_MEMB
ERS_YOU_VI
EWED' ); b
reak;
|
260 |
|
|
|
259 |
|
|
261 |
|
ca
se 'HotLis
t_me':
$ret =
_t( '_MEMB
ERS_YOU_HO
TLISTED_BY
' ); break
;
|
|
260 |
|
ca
se 'HotLis
t_me':
$ret =
_t( '_MEMB
ERS_YOU_HO
TLISTED_BY
' ); break
;
|
262 |
|
ca
se 'Friend
List_me':
$ret =
_t( '_MEMB
ERS_YOU_IN
VITED_FRIE
NDLIST' );
break;
|
|
261 |
|
ca
se 'Friend
List_me':
$ret =
_t( '_MEMB
ERS_YOU_IN
VITED_FRIE
NDLIST' );
break;
|
263 |
|
ca
se 'BlockL
ist_me':
$ret =
_t( '_MEMB
ERS_YOU_BL
OCKLISTED_
BY' ); bre
ak;
|
|
262 |
|
ca
se 'BlockL
ist_me':
$ret =
_t( '_MEMB
ERS_YOU_BL
OCKLISTED_
BY' ); bre
ak;
|
264 |
|
ca
se 'VKisse
s_me':
$ret =
_t( '_MEMB
ERS_YOU_KI
SSED_BY' )
; break;
|
|
263 |
|
ca
se 'VKisse
s_me':
$ret =
_t( '_MEMB
ERS_YOU_KI
SSED_BY' )
; break;
|
265 |
|
ca
se 'Profil
esTrack_me
': $ret =
_t( '_MEMB
ERS_YOU_VI
EWED_BY' )
; break;
|
|
264 |
|
ca
se 'Profil
esTrack_me
': $ret =
_t( '_MEMB
ERS_YOU_VI
EWED_BY' )
; break;
|
266 |
|
|
|
265 |
|
|
267 |
|
ca
se 'Friend
List_':
$ret =
_t( '_Frie
nd list' )
; break;
|
|
266 |
|
ca
se 'Friend
List_':
$ret =
_t( '_Frie
nd list' )
; break;
|
268 |
|
}
|
|
267 |
|
}
|
269 |
|
|
|
268 |
|
|
270 |
|
if( $n
um_res )
|
|
269 |
|
if( $n
um_res )
|
271 |
|
$r
et .= ": $
num_res";
|
|
270 |
|
$r
et .= ": $
num_res";
|
272 |
|
|
|
271 |
|
|
273 |
|
return
$ret;
|
|
272 |
|
return
$ret;
|
274 |
|
}
|
|
273 |
|
}
|
275 |
|
|
|
274 |
|
|
276 |
|
function g
etButtons(
$form )
|
|
275 |
|
function g
etButtons(
$form )
|
277 |
|
{
|
|
276 |
|
{
|
278 |
|
$aButt
on = array
();
|
|
277 |
|
$aButt
on = array
();
|
279 |
|
|
|
278 |
|
|
280 |
|
switch
( $form )
|
|
279 |
|
switch
( $form )
|
281 |
|
{
|
|
280 |
|
{
|
282 |
|
ca
se 'HotLis
t_i':
$aButto
n['del'] =
_t('_Dele
te');
break;
|
|
281 |
|
ca
se 'HotLis
t_i':
$aButto
n['del'] =
_t('_Dele
te');
break;
|
283 |
|
ca
se 'Friend
List_i':
$aButto
n['del'] =
_t("_Back
Invite");
break;
|
|
282 |
|
ca
se 'Friend
List_i':
$aButto
n['del'] =
_t("_Back
Invite");
break;
|
284 |
|
ca
se 'BlockL
ist_i':
$aButto
n['del'] =
_t("_Unbl
ock");
break;
|
|
283 |
|
ca
se 'BlockL
ist_i':
$aButto
n['del'] =
_t("_Unbl
ock");
break;
|
285 |
|
ca
se 'VKisse
s_i':
$aButto
n['del'] =
_t('_Dele
te');
break;
|
|
284 |
|
ca
se 'VKisse
s_i':
$aButto
n['del'] =
_t('_Dele
te');
break;
|
286 |
|
ca
se 'Profil
esTrack_i'
: $aButto
n['del'] =
_t('_Dele
te');
break;
|
|
285 |
|
ca
se 'Profil
esTrack_i'
: $aButto
n['del'] =
_t('_Dele
te');
break;
|
287 |
|
|
|
286 |
|
|
288 |
|
ca
se 'HotLis
t_me':
$aButto
n['add'] =
_t("_Add
to Hot Lis
t"); break
;
|
|
287 |
|
ca
se 'HotLis
t_me':
$aButto
n['add'] =
_t("_Add
to Hot Lis
t"); break
;
|
289 |
|
ca
se 'Friend
List_me':
$aButto
n['add'] =
_t("_Add
to Friend
List");
|
|
288 |
|
ca
se 'Friend
List_me':
$aButto
n['add'] =
_t("_Add
to Friend
List");
|
290 |
|
$aButto
n['del'] =
_t("_Reje
ct Invite"
); break
;
|
|
289 |
|
$aButto
n['del'] =
_t("_Reje
ct Invite"
); break
;
|
291 |
|
ca
se 'BlockL
ist_me':
$aButto
n['add'] =
_t("_Bloc
k");
break
;
|
|
290 |
|
ca
se 'BlockL
ist_me':
$aButto
n['add'] =
_t("_Bloc
k");
break
;
|
292 |
|
ca
se 'VKisse
s_me':
$aButto
n['del'] =
_t('_Dele
te');
break
;
|
|
291 |
|
ca
se 'VKisse
s_me':
$aButto
n['del'] =
_t('_Dele
te');
break
;
|
293 |
|
ca
se 'Profil
esTrack_me
': $aButto
n['del'] =
_t('_Dele
te');
break
;
|
|
292 |
|
ca
se 'Profil
esTrack_me
': $aButto
n['del'] =
_t('_Dele
te');
break
;
|
294 |
|
|
|
293 |
|
|
295 |
|
ca
se 'Friend
List_':
$aButto
n['del'] =
_t("_Dele
te from Fr
iend List"
); break;
|
|
294 |
|
ca
se 'Friend
List_':
$aButto
n['del'] =
_t("_Dele
te from Fr
iend List"
); break;
|
296 |
|
}
|
|
295 |
|
}
|
297 |
|
|
|
296 |
|
|
298 |
|
$ret =
'';
|
|
297 |
|
$ret =
'';
|
299 |
|
|
|
298 |
|
|
300 |
|
foreac
h( $aButto
n as $sAct
=> $sTitl
e )
|
|
299 |
|
foreac
h( $aButto
n as $sAct
=> $sTitl
e )
|
301 |
|
$r
et .= " <i
nput type=
\"submit\"
name=\"{$
form}_{$sA
ct}\" valu
e=\"$sTitl
e\" disabl
ed=\"disab
led\" clas
s=\"submit
_button\"
/> ";
|
|
300 |
|
$r
et .= " <i
nput type=
\"submit\"
name=\"{$
form}_{$sA
ct}\" valu
e=\"$sTitl
e\" disabl
ed=\"disab
led\" clas
s=\"submit
_button\"
/> ";
|
302 |
|
|
|
301 |
|
|
303 |
|
return
$ret;
|
|
302 |
|
return
$ret;
|
304 |
|
}
|
|
303 |
|
}
|
305 |
|
|
|
304 |
|
|
306 |
|
function d
elFromList
( $table,
$sqlWho, $
sqlWhom, $
two_way =
false )
|
|
305 |
|
function d
elFromList
( $table,
$sqlWho, $
sqlWhom, $
two_way =
false )
|
307 |
|
{
|
|
306 |
|
{
|
308 |
|
global
$memberID
;
|
|
307 |
|
global
$memberID
;
|
309 |
|
|
|
308 |
|
|
310 |
|
if( $a
Mem = $_PO
ST['mem']
and is_arr
ay( $aMem
) and !emp
ty( $aMem
) )
|
|
309 |
|
if( $a
Mem = $_PO
ST['mem']
and is_arr
ay( $aMem
) and !emp
ty( $aMem
) )
|
311 |
|
{
|
|
310 |
|
{
|
312 |
|
fo
reach( $aM
em as $ID
=> $val )
|
|
311 |
|
fo
reach( $aM
em as $ID
=> $val )
|
313 |
|
{
|
|
312 |
|
{
|
314 |
|
$ID = (i
nt)$ID;
|
|
313 |
|
$ID = (i
nt)$ID;
|
315 |
|
/*if( !$
ID or $val
!= 'on' )
|
|
314 |
|
/*if( !$
ID or $val
!= 'on' )
|
316 |
|
cont
inue;*/
|
|
315 |
|
cont
inue;*/
|
317 |
|
|
|
316 |
|
|
318 |
|
$query =
"DELETE F
ROM `$tabl
e` WHERE `
$sqlWho`=$
memberID A
ND `$sqlWh
om`=$ID";
|
|
317 |
|
$query =
"DELETE F
ROM `$tabl
e` WHERE `
$sqlWho`=$
memberID A
ND `$sqlWh
om`=$ID";
|
319 |
|
db_res(
$query );
|
|
318 |
|
db_res(
$query );
|
320 |
|
|
|
319 |
|
|
321 |
|
if( $two
_way )
|
|
320 |
|
if( $two
_way )
|
322 |
|
{
|
|
321 |
|
{
|
323 |
|
$que
ry1 = "DEL
ETE FROM `
$table` WH
ERE `$sqlW
hom`=$memb
erID AND `
$sqlWho`=$
ID";
|
|
322 |
|
$que
ry1 = "DEL
ETE FROM `
$table` WH
ERE `$sqlW
hom`=$memb
erID AND `
$sqlWho`=$
ID";
|
324 |
|
db_r
es( $query
1 );
|
|
323 |
|
db_r
es( $query
1 );
|
325 |
|
}
|
|
324 |
|
}
|
326 |
|
}
|
|
325 |
|
}
|
327 |
|
}
|
|
326 |
|
}
|
328 |
|
}
|
|
327 |
|
}
|
329 |
|
|
|
328 |
|
|
330 |
|
function a
ddToList(
$table, $s
qlWho, $sq
lWhom )
|
|
329 |
|
function a
ddToList(
$table, $s
qlWho, $sq
lWhom )
|
331 |
|
{
|
|
330 |
|
{
|
332 |
|
global
$memberID
;
|
|
331 |
|
global
$memberID
;
|
333 |
|
|
|
332 |
|
|
334 |
|
if( $a
Mem = $_PO
ST['mem']
and is_arr
ay( $aMem
) and !emp
ty( $aMem
) )
|
|
333 |
|
if( $a
Mem = $_PO
ST['mem']
and is_arr
ay( $aMem
) and !emp
ty( $aMem
) )
|
335 |
|
{
|
|
334 |
|
{
|
336 |
|
fo
reach( $aM
em as $ID
=> $val )
|
|
335 |
|
fo
reach( $aM
em as $ID
=> $val )
|
337 |
|
{
|
|
336 |
|
{
|
338 |
|
$ID = (i
nt)$ID;
|
|
337 |
|
$ID = (i
nt)$ID;
|
339 |
|
if( !$ID
or $val !
= 'on' )
|
|
338 |
|
if( !$ID
or $val !
= 'on' )
|
340 |
|
cont
inue;
|
|
339 |
|
cont
inue;
|
341 |
|
|
|
340 |
|
|
342 |
|
$tmpArr
= db_arr(
"SELECT CO
UNT(*) FRO
M `$table`
WHERE `$s
qlWho`=$me
mberID AND
`$sqlWhom
`=$ID" );
|
|
341 |
|
$tmpArr
= db_arr(
"SELECT CO
UNT(*) FRO
M `$table`
WHERE `$s
qlWho`=$me
mberID AND
`$sqlWhom
`=$ID" );
|
343 |
|
|
|
342 |
|
|
344 |
|
if( (int
)$tmpArr[0
] == 0 )
|
|
343 |
|
if( (int
)$tmpArr[0
] == 0 )
|
345 |
|
{
|
|
344 |
|
{
|
346 |
|
$que
ry = "INSE
RT INTO `$
table` SET
`$sqlWho`
=$memberID
, `$sqlWho
m`=$ID";
|
|
345 |
|
$que
ry = "INSE
RT INTO `$
table` SET
`$sqlWho`
=$memberID
, `$sqlWho
m`=$ID";
|
347 |
|
db_r
es( $query
);
|
|
346 |
|
db_r
es( $query
);
|
348 |
|
}
|
|
347 |
|
}
|
349 |
|
}
|
|
348 |
|
}
|
350 |
|
}
|
|
349 |
|
}
|
351 |
|
}
|
|
350 |
|
}
|
352 |
|
|
|
351 |
|
|
353 |
|
function a
pproveFrie
ndInvites(
) {
|
|
352 |
|
function a
pproveFrie
ndInvites(
) {
|
354 |
|
global
$memberID
;
|
|
353 |
|
global
$memberID
;
|
355 |
|
global
$site;
|
|
354 |
|
global
$site;
|
356 |
|
|
|
355 |
|
|
357 |
|
if( $a
Mem = $_PO
ST['mem']
and is_arr
ay( $aMem
) and !emp
ty( $aMem
) ) {
|
|
356 |
|
if( $a
Mem = $_PO
ST['mem']
and is_arr
ay( $aMem
) and !emp
ty( $aMem
) ) {
|
358 |
|
fo
reach( $aM
em as $ID
=> $val )
{
|
|
357 |
|
fo
reach( $aM
em as $ID
=> $val )
{
|
359 |
|
$ID = (i
nt)$ID;
|
|
358 |
|
$ID = (i
nt)$ID;
|
360 |
|
if( !$ID
or $val !
= 'on' )
|
|
359 |
|
if( !$ID
or $val !
= 'on' )
|
361 |
|
cont
inue;
|
|
360 |
|
cont
inue;
|
362 |
|
|
|
361 |
|
|
363 |
|
$query =
"UPDATE `
FriendList
` SET `Che
ck`='1' WH
ERE `Profi
le`=$membe
rID AND `I
D`=$ID";
|
|
362 |
|
$query =
"UPDATE `
FriendList
` SET `Che
ck`='1' WH
ERE `Profi
le`=$membe
rID AND `I
D`=$ID";
|
364 |
|
db_res(
$query );
|
|
363 |
|
db_res(
$query );
|
365 |
|
}
|
|
364 |
|
}
|
366 |
|
}
|
|
365 |
|
}
|
367 |
|
header
( "Locatio
n:{$site['
url']}view
Friends.ph
p?iUser={$
memberID}"
);
|
|
366 |
|
header
( "Locatio
n:{$site['
url']}view
Friends.ph
p?iUser={$
memberID}"
);
|
368 |
|
}
|
|
367 |
|
}
|
369 |
|
|
|
368 |
|
|
370 |
|
?>
|
|
369 |
|
?>
|