The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Stumped on passing a string - SOLVED
I've been able to pass form variables between different scripts within admincp with no problem, however I am trying to use different branches within the same script (as I should), but this has really got me stumped and I can't see what i'm doing wrong here. If anyone can help, i'll do a little dance or something...
Data is submitted through a form with multiple events on each line and each line has a checkbox: Code:
<input type=\"checkbox\" name=\"idsforaction[]\" value=\"" . $event['eventid'] . "\"> PHP Code:
Location:scst_eventsmanager.php?do=remove&eventids =6,3,4,5 But when the remove branch is executed, the eventids never seem to pass. Here's my remove branch: PHP Code:
If I ever get past the remove branch, my kill branch looks like this: PHP Code:
|
#2
|
||||
|
||||
I'm pretty sure it's working but your query is incorrect... I think it's taking the whole list and interpreting it as a string, rather than a list. Instead of this
Code:
WHERE eventid IN '" . $vbulletin->GPC['eventids'] . "' Code:
WHERE eventid IN (" . $vbulletin->GPC['eventids'] . ") |
#3
|
||||
|
||||
Sir you rock, u always answer my questions so quickly . I actually just got it to work, that's correct, i needed the eventids surrounded by () after IN in the sql... also other thing i noticed was the following (which i am kickin myself in the butt for):
Code:
header("Location:scst_eventsmanager.php?" . $vbulletin->session->vars['sessionurl'] . "do=remove&eventids=".$strIDs); Code:
header("Location:scst_eventsmanager.php?" . $vbulletin->session->vars['sessionurl'] . "do=remove&eventids=".$strIDs); Thanks for yourhelp! |
#4
|
||||
|
||||
No problem.
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|