By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,064 Members | 1,388 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,064 IT Pros & Developers. It's quick & easy.

Not sure how to finish this zap statement/conditional...

P: 8
I am trying to make this statement say to delete the deleted folder if you click that zap...or the inbox if it is that zap or the sent box if it is that zap. I started a new one for each and it didn't work so either I missed something in the others or I need to make this one refer to them all in some way. Do I need an or somewher ebetween them or in this code?? How do you do that if so?

Expand|Select|Wrap|Line Numbers
  1.  else if ($HTTP_GET_VARS["zap"])
  2.          zap_deleted_items($HTTP_GET_VARS);
  3.  
[Please use CODE tags when posting source code. Thanks! --pbmods]
Jun 2 '07 #1
Share this Question
Share on Google+
3 Replies


pbmods
Expert 5K+
P: 5,821
Changed thread title to better match contents.

I started a new one for each and it didn't work so either I missed something in the others or I need to make this one refer to them all in some way. Do I need an or somewher ebetween them or in this code??
What is your code doing?
What is it supposed to do?
Jun 3 '07 #2

P: 8
Thank you. I'm so PHP stupid I wasn't even sure how to name it.

The code is to allow me to be able to permanenly delete all the messages in teh dleted folder. I want to make it also delete all the messages in the Inbox and Sent folder instead of having to move them to the delted folder to do so. If I change the delted_items to inbox it workd for that but I need to know how I make it work for all three folders.
Jun 4 '07 #3

P: 8
Here is the other code that goes with it.

Code PHP:

[PHP]if (key($folders) == 102) // if deleted items
$folder_list1 = substr($folder_list1, 0, strlen($folder_list1) - 5) .
sprintf(' &nbsp; <A HREF="pm.php?zap=1&ref=%s">.:%s:.</A><BR>' . "\n",
$vars["folder_id"], lg("pm_zap"));[/PHP]

I made one of these for each folder. Then this is the actual function code.

[PHP]function zap_deleted_items($vars)
// Permanently deletes the contents of the deleted items folder
{
pm_zap_deleted_items(USER_ID);
$folder_id = $vars["ref"];
redirect("/pm.php?folder_id=$folder_id");[/PHP]
Jun 4 '07 #4

Post your reply

Sign in to post your reply or Sign up for a free account.