문제

i need to replace the u=2 in

$banuserurl = $vbulletin->options['bburl'].'/misc.php?'.$vbulletin->session->vars['sessionurl'].'do=ccb_banuser&u=2';exec_header_redirect($banuserurl);

with u=$vbulletin->GPC['ccb_newmessage']

but doing it just like that doesnt work =/ what am i doing wrong =(

full code (not working):

$cybcb_checkban = strpos($vbulletin->GPC['ccb_newmessage'], '/ban');
                if($cybcb_checkban !== false AND $cybcb_candelall)
                {
                    $vbulletin->GPC['ccb_newmessage'] = str_replace('/ban ', ' ', $vbulletin->GPC['ccb_newmessage']);
                    $banuserurl = $vbulletin->options['bburl'].'/misc.php?'.$vbulletin->session->vars['sessionurl'].'do=ccb_banuser&u=$vbulletin->GPC['ccb_newmessage']';exec_header_redirect($banuserurl);
                }
도움이 되었습니까?

해결책

You need to put the string into '' while inserting it into other string.

Replace

$banuserurl = $vbulletin->options['bburl'].'/misc.php?'.$vbulletin->session->vars['sessionurl'].'do=ccb_banuser&u=$vbulletin->GPC['ccb_newmessage']';exec_header_redirect($banuserurl);

With

$banuserurl = $vbulletin->options['bburl'].'/misc.php?'.$vbulletin->session->vars['sessionurl'].'do=ccb_banuser&u='.$vbulletin->GPC['ccb_newmessage'];exec_header_redirect($banuserurl);
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top