Re: [PHP] delete S3 bucket with AWS PHP SDK

2013-10-01 Thread Aziz Saleh
Hey Tim, It seems that deleteObject takes in 2 params, and you are sending it 1 param. I would recommend you look at the documentation and make sure you are sending the right params. Aziz On Sun, Sep 29, 2013 at 10:29 PM, Tim Dunphy bluethu...@gmail.com wrote: Hi Aziz, Thank you for

[PHP] delete S3 bucket with AWS PHP SDK

2013-09-29 Thread Tim Dunphy
Hi All, I am attempting to delete an empty S3 bucket using the AWS PHP SDK. Here's how they describe the process in the docs: $result = $client-deleteBucket(array( // Bucket is required 'Bucket' = 'string', )); You can find the full entry here: AWS PHP SDK Delete Bucket

Re: [PHP] delete S3 bucket with AWS PHP SDK

2013-09-29 Thread Ashley Sheridan
On Sun, 2013-09-29 at 12:30 -0400, Tim Dunphy wrote: Hi All, I am attempting to delete an empty S3 bucket using the AWS PHP SDK. Here's how they describe the process in the docs: $result = $client-deleteBucket(array( // Bucket is required 'Bucket' = 'string', )); You

Re: [PHP] delete S3 bucket with AWS PHP SDK

2013-09-29 Thread Aziz Saleh
Hi Tim, Is the call working? Does it actually get deleted? This could just be an issue (which I see alot) where developers do not check for variables or preset them before usage, causing those notices to come up (pretty harmless most of the times). Aziz On Sun, Sep 29, 2013 at 12:30 PM, Tim

Re: [PHP] delete S3 bucket with AWS PHP SDK

2013-09-29 Thread Tim Dunphy
Hey guys, Sorry about that i should have posted the full code to give you some idea of context. Anyway, here it is: ?php require_once 'sdk.class.php'; if (isset($_POST['submit'])) { * $bucket_name = $_POST['$bucket_name'];* // Create the S3 Object from the SDK *$s3 = new AmazonS3();* *

Re: [PHP] delete S3 bucket with AWS PHP SDK

2013-09-29 Thread Aziz Saleh
No Problem, the issue is that you referring to the invalid post element $bucket_name as opposed to the correct on bucket_name. *$bucket_name = $_POST['$bucket_name'];* Should be *$bucket_name = $_POST['bucket_name'];* Aziz On Sun, Sep 29, 2013 at 3:28 PM, Tim Dunphy bluethu...@gmail.com

Re: [PHP] delete S3 bucket with AWS PHP SDK

2013-09-29 Thread Tim Dunphy
Hi Aziz, Thank you for getting back to me! I appreciate you spotting that error. So I corrected that ?php require_once 'sdk.class.php'; if (isset($_POST['submit'])) { * $bucket_name = $_POST['bucket_name'];* // Create the S3 Object from the SDK $s3 = new AmazonS3(); * $result =

Fwd: [PHP] delete and recreate

2011-11-10 Thread tamouse mailing lists
Hoisted on me own petard, as it were. Meant this to go to OP and list, not Jim. -- Forwarded message -- From: tamouse mailing lists tamouse.li...@gmail.com Date: Thu, Nov 10, 2011 at 3:25 AM Subject: Re: [PHP] delete and recreate To: Jim Lucas li...@cmsws.com On Wed, Nov 9

[PHP] delete and recreate

2011-11-09 Thread Kirk Bailey
So, I want to create a script to delete an old file and create a new one which is empty. The script receives a password via query string. The obvious methods give me back a very useless 500 error. Any suggestions on how to accomplish what I seek? -- end Very Truly yours, -

Re: [PHP] delete and recreate

2011-11-09 Thread Stuart Dallas
On 9 Nov 2011, at 15:35, Kirk Bailey wrote: So, I want to create a script to delete an old file and create a new one which is empty. The script receives a password via query string. The obvious methods give me back a very useless 500 error. Any suggestions on how to accomplish what I seek?

Re: [PHP] delete and recreate

2011-11-09 Thread Adam Richardson
On Wed, Nov 9, 2011 at 10:35 AM, Kirk Bailey kbai...@howlermonkey.netwrote: So, I want to create a script to delete an old file and create a new one which is empty. The script receives a password via query string. The obvious methods give me back a very useless 500 error. Any suggestions on

Re: [PHP] delete and recreate

2011-11-09 Thread Jim Giner
Is anyone concerned about the OP's original statement about receives a password via query string. Perhaps that is his problem since he did mention it? I didn't attempt to answer it because I didn't know what/why he was prompting for a password. -- PHP General Mailing List

Re: [PHP] delete and recreate

2011-11-09 Thread Jim Lucas
On 11/9/2011 7:35 AM, Kirk Bailey wrote: So, I want to create a script to delete an old file and create a new one which is empty. The script receives a password via query string. The obvious methods give me back a very useless 500 error. Any suggestions on how to accomplish what I seek?

Re: [PHP] PHP delete confirmation

2011-04-29 Thread Sharl.Jimh.Tsin
...@gmail.com] Sent: Friday, April 29, 2011 12:33 AM To: php-general@lists.php.net Subject: [PHP] PHP delete confirmation I have been trying to figure out how to add delete confirmation for the bellow snippet of code. I would prefer not to use javascript. Can anyone offer any advise on how to right

[PHP] Re: PHP delete confirmation

2011-04-29 Thread Geoff Lane
On Friday, April 29, 2011, ad...@buskirkgraphics.com wrote: Personally I would use the javascript page navigation is senseless if they miss click. Javascript: Small and simple javascript. onclick=return confirm('Are you sure you want to delete?') Personally, I'd use Javascript and also

Re: [PHP] Re: PHP delete confirmation

2011-04-29 Thread Jim Lucas
On 4/29/2011 12:06 AM, Geoff Lane wrote: On Friday, April 29, 2011, ad...@buskirkgraphics.com wrote: Personally I would use the javascript page navigation is senseless if they miss click. Javascript: Small and simple javascript. onclick=return confirm('Are you sure you want to

Re: [PHP] Re: PHP delete confirmation

2011-04-29 Thread Ashley Sheridan
Jim Lucas li...@cmsws.com wrote: On 4/29/2011 12:06 AM, Geoff Lane wrote: On Friday, April 29, 2011, ad...@buskirkgraphics.com wrote: Personally I would use the javascript page navigation is senseless if they miss click. Javascript: Small and simple javascript. onclick=return confirm('Are

[PHP] PHP delete confirmation

2011-04-28 Thread Chris Stinemetz
I have been trying to figure out how to add delete confirmation for the bellow snippet of code. I would prefer not to use javascript. Can anyone offer any advise on how to right the delete confirmation in PHP? Thank you in advance. P.S. I apologize for the indention. For some reason gmail messes

RE: [PHP] PHP delete confirmation

2011-04-28 Thread admin
: Chris Stinemetz [mailto:chrisstinem...@gmail.com] Sent: Friday, April 29, 2011 12:33 AM To: php-general@lists.php.net Subject: [PHP] PHP delete confirmation I have been trying to figure out how to add delete confirmation for the bellow snippet of code. I would prefer not to use javascript. Can

[PHP] Delete File With Any File Extension

2010-06-15 Thread Shaun Thornburgh
Hi, I need to delete a file with any file extension where i know the name of the file, is it possible to use regular expressions with the unlink function? Thanks _

Re: [PHP] Delete File With Any File Extension

2010-06-15 Thread Adrian
Use glob() to get a list of matching afiles nd then unlink() them separately. I need to delete a file with any file extension where i know the name of the file, is it possible to use regular expressions with the unlink function? -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Delete File With Any File Extension

2010-06-15 Thread cheran krishnamoorthy
You can't use regular expression with unlink directly. have a look on this http://www.phpfreaks.com/forums/index.php?topic=256367.0 http://www.phpfreaks.com/forums/index.php?topic=256367.0Regards Cherankrish On Tue, Jun 15, 2010 at 4:17 PM, Shaun Thornburgh shaunthornbu...@hotmail.com wrote:

Re: [PHP] Delete File With Any File Extension

2010-06-15 Thread Ashley Sheridan
On Tue, 2010-06-15 at 16:23 +0530, cheran krishnamoorthy wrote: You can't use regular expression with unlink directly. have a look on this http://www.phpfreaks.com/forums/index.php?topic=256367.0 http://www.phpfreaks.com/forums/index.php?topic=256367.0Regards Cherankrish On Tue, Jun 15,

[PHP] delete insert ?

2009-06-23 Thread PJ
I just had a bright idea ??? Am doing editing file for book entries; it occurs to me (now that I am practically finished) that it might be much simpler to delete entries and just insert rather than going through the rigamarole of checking if the new entries exist and if and if and if... just

Re: [PHP] delete insert ?

2009-06-23 Thread Bastien Koert
On Tue, Jun 23, 2009 at 4:20 PM, PJaf.gour...@videotron.ca wrote: I just had a bright idea ??? Am doing editing file for book entries; it occurs to me (now that I am practically finished) that it might be much simpler to delete entries and just insert rather than going through the rigamarole

[PHP] Delete a document from lotus domino with CURL

2008-02-06 Thread Fnutt
I am working on a script that log in, look for messages, download them (including any attached files) and then deletes the message from a lotus domino server. What I have access to is a simple web-gui that I access throu CURL. So far I have been able to do the following: Log in and save a

Re: [PHP] Delete rows from database

2008-01-07 Thread Jim Lucas
Balasubramanyam A wrote: Hi all, I'm searching names from MySQL and printing it on a browser. Also, I've provided checkbox for all the rows and a delete button for a page. I want to delete the selected rows from MySQL when I click on the Delete button. How do I do that? Here is the code which

[PHP] Delete rows from database

2008-01-05 Thread Balasubramanyam A
Hi all, I'm searching names from MySQL and printing it on a browser. Also, I've provided checkbox for all the rows and a delete button for a page. I want to delete the selected rows from MySQL when I click on the Delete button. How do I do that? Here is the code which I used to print the rows

Re: [PHP] Delete rows from database

2008-01-05 Thread Per Jessen
Balasubramanyam A wrote: Hi all, I'm searching names from MySQL and printing it on a browser. Also, I've provided checkbox for all the rows and a delete button for a page. I want to delete the selected rows from MySQL when I click on the Delete button. How do I do that? You process the

Re: [PHP] Delete rows from database

2008-01-05 Thread Daniel Brown
On Jan 5, 2008 9:03 AM, Balasubramanyam A [EMAIL PROTECTED] wrote: Hi all, Hi! [snip] while ($line = mysql_fetch_array($resultset, MYSQL_ASSOC)) { [snip] Just a side note: wouldn't it be easier to just use mysql_fetch_assoc() ? It does the exact same thing, with less typing. --

Re: [PHP] Delete row in a lookup table

2007-08-27 Thread nitrox .
Wow, I actually managed to get this working now. Thanks to Richard and stut I realized I was on the right track but had my code screwed up. Richard your right, a primary key column was silly but was a temporary fix. It allowed me to delete with one column and not have to reference a second. So

Re: [PHP] Delete row in a lookup table

2007-08-26 Thread Richard Lynch
On Sat, August 18, 2007 6:31 pm, nitrox . wrote: Is it not considered good practice to have a primary key on a lookup table for a database? I have 3 tables setup, games, memberleagues and members. The memberleagues table holds the id of the games table and members table. The problem I have is

[PHP] Delete row in a lookup table

2007-08-18 Thread nitrox .
Hi all, Is it not considered good practice to have a primary key on a lookup table for a database? I have 3 tables setup, games, memberleagues and members. The memberleagues table holds the id of the games table and members table. The problem I have is that Im not sure how to delete a row

Re: [PHP] Delete row in a lookup table

2007-08-18 Thread Larry Garfield
Whether or not it's good practice depends on who you ask. :-) Every table should have a primary key. Primary keys, however, may span multiple columns. That's perfectly legal. In some cases that primary key may span every column, but generally that's a sign of bad design unless you're

Re: [PHP] Delete first line of a csv file if it is the headers

2007-05-02 Thread Richard Lynch
Do one, and only one, fgetcsv() before you entere the loop? Or, if only SOME people add the header lines to their CSV file, check if one of the numeric fields is actually numeric, and skip any bad lines. You could even keep a counter going of which line you are on, and give an error message if

[PHP] Delete first line of a csv file if it is the headers

2007-04-29 Thread Richard Kurth
The below script will parse a csv file to a database I need to remove the first line because it is the header files and I don't need them. How can I test for that and remove them. $file = fopen($_POST['copy'], 'r') or $message .= Could not open . $_POST[copy] . for reading.BR\n;

Re: [PHP] Delete first line of a csv file if it is the headers

2007-04-29 Thread Chris
Richard Kurth wrote: The below script will parse a csv file to a database I need to remove the first line because it is the header files and I don't need them. How can I test for that and remove them. $file = fopen($_POST['copy'], 'r') or $message .= Could not open . $_POST[copy] . for

[PHP] Delete an upload

2006-07-17 Thread Benjamin Adams
I created a form where users can upload. I'm working on the section where admins can delete entries. When I have a user delete an entery, I have it taking out of MySQL (working fine) But how do I delete the file that was uploaded? Thanks for any help Ben -- PHP General

RE: [PHP] Delete an upload

2006-07-17 Thread Jay Blanchard
[snip] I created a form where users can upload. I'm working on the section where admins can delete entries. When I have a user delete an entery, I have it taking out of MySQL (working fine) But how do I delete the file that was uploaded? Thanks for any help [/snip] http://www.php.net/unlink

RE: [PHP] Delete an upload

2006-07-17 Thread mike bellerby
You unlink it. Mike Message Received: Jul 17 2006, 04:26 PM From: Benjamin Adams [EMAIL PROTECTED] To: php php php-general@lists.php.net Cc: Subject: [PHP] Delete an upload I created a form where users can upload. I'm working on the section

Re: [PHP] Delete

2006-06-05 Thread Richard Lynch
On Sat, June 3, 2006 8:40 pm, George Babichev wrote: Hello everyone! I wrote a blog application, but now for the admin panel, i am trying to add a feature to delete blog posts. It would show the title of the post next to it, and have a delete link which would delete it. How would I do this?

Re: [PHP] Delete

2006-06-05 Thread Richard Lynch
On Sun, June 4, 2006 3:11 am, Rabin Vincent wrote: You may find it easier to generate links of the form delete.php?id=1, etc. Then you won't have to use a seperate form for each link. The id will be available in delete.php in $_GET. The same sanity checking applies in this case too. Gah!

Re: [PHP] Delete

2006-06-05 Thread Chris Boget
On Sun, June 4, 2006 3:11 am, Rabin Vincent wrote: You may find it easier to generate links of the form delete.php?id=1, etc. Then you won't have to use a seperate form for each link. The id will be available in delete.php in $_GET. The same sanity checking applies in this case too. Gah! That

Re: [PHP] Delete

2006-06-05 Thread Richard Lynch
On Mon, June 5, 2006 12:41 am, Rabin Vincent wrote: I don't see how POST is better/more secure for a delete action. If you don't see how it's better, then READ THE HTTP SPECS!!! -- Like Music? http://l-i-e.com/artists.htm -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

Re: [PHP] Delete

2006-06-05 Thread Richard Lynch
On Mon, June 5, 2006 11:52 am, Chris Boget wrote: On Sun, June 4, 2006 3:11 am, Rabin Vincent wrote: You may find it easier to generate links of the form delete.php?id=1, etc. Then you won't have to use a seperate form for each link. The id will be available in delete.php in $_GET. The same

Re: [PHP] Delete

2006-06-04 Thread Larry Garfield
General list php-general@lists.php.net Sent: Saturday, June 03, 2006 6:40 PM Subject: [PHP] Delete Hello everyone! I wrote a blog application, but now for the admin panel, i am trying to add a feature to delete blog posts. It would show the title of the post next

Re: [PHP] Delete

2006-06-04 Thread Rabin Vincent
On 6/4/06, Larry Garfield [EMAIL PROTECTED] wrote: Make each button a separate form, with the id as a hidden value. Like so: div form method='post' pMy first entry/p input type='hidden' name='id' value='1' / input type='submit' value='Delete' / /form /div [snip] You may find it easier to

Re: [PHP] Delete

2006-06-04 Thread tedd
At 10:53 PM -0700 6/3/06, George Babichev wrote: Thank you for the help guys, but the I guess I kinda have another question. So I do assign an id to each blog post, and it is auto_increment, so in my blog delete page, it would display all the blog title's and a delete button nex to it. So lets say

Re: [PHP] Delete

2006-06-04 Thread Larry Garfield
On Sunday 04 June 2006 03:11, Rabin Vincent wrote: On 6/4/06, Larry Garfield [EMAIL PROTECTED] wrote: Make each button a separate form, with the id as a hidden value. Like so: div form method='post' pMy first entry/p input type='hidden' name='id' value='1' / input type='submit'

Re: [PHP] Delete

2006-06-04 Thread George Babichev
Yes, that checkbox idea is exactly what I was thinking about. Exept I have no idea how my program would tell one checkbox from the other, and delete the wrong thing... On 6/4/06, tedd [EMAIL PROTECTED] wrote: At 10:53 PM -0700 6/3/06, George Babichev wrote: Thank you for the help guys, but the

Re: [PHP] Delete

2006-06-04 Thread tedd
At 10:30 AM -0700 6/4/06, George Babichev wrote: Yes, that checkbox idea is exactly what I was thinking about. Exept I have no idea how my program would tell one checkbox from the other, and delete the wrong thing... George: You're going to have to play around with forms and find out how

Re: [PHP] Delete

2006-06-04 Thread Rabin Vincent
On 6/4/06, Larry Garfield [EMAIL PROTECTED] wrote: Only if delete.php is a confirmation page. Never ever ever have a delete function that operates solely by GET. Here's why: http://thedailywtf.com/forums/thread/66166.aspx Yes, I've seen that one before. IMO the main problem there is the

Re: [PHP] Delete

2006-06-04 Thread Larry Garfield
On Monday 05 June 2006 00:41, Rabin Vincent wrote: On 6/4/06, Larry Garfield [EMAIL PROTECTED] wrote: Only if delete.php is a confirmation page. Never ever ever have a delete function that operates solely by GET. Here's why: http://thedailywtf.com/forums/thread/66166.aspx Yes, I've

[PHP] Delete

2006-06-03 Thread George Babichev
Hello everyone! I wrote a blog application, but now for the admin panel, i am trying to add a feature to delete blog posts. It would show the title of the post next to it, and have a delete link which would delete it. How would I do this? I mean if I have multiple blog entry's, how would I delete

Re: [PHP] Delete

2006-06-03 Thread benifactor
-general@lists.php.net Sent: Saturday, June 03, 2006 6:40 PM Subject: [PHP] Delete Hello everyone! I wrote a blog application, but now for the admin panel, i am trying to add a feature to delete blog posts. It would show the title of the post next to it, and have a delete link which would delete

Re: [PHP] Delete

2006-06-03 Thread Rabin Vincent
On 6/4/06, George Babichev [EMAIL PROTECTED] wrote: Hello everyone! I wrote a blog application, but now for the admin panel, i am trying to add a feature to delete blog posts. It would show the title of the post next to it, and have a delete link which would delete it. How would I do this? I

Re: [PHP] Delete

2006-06-03 Thread George Babichev
the database. - Original Message - From: George Babichev [EMAIL PROTECTED] To: PHP General list php-general@lists.php.net Sent: Saturday, June 03, 2006 6:40 PM Subject: [PHP] Delete Hello everyone! I wrote a blog application, but now for the admin panel, i am trying to add a feature to delete

[PHP] delete duplicates from array and insert statement

2005-09-17 Thread Ryan A
Hi, I have a movie database with this structure: flick_name text part_url text part_size varchar(50) time_length varchar(50) part_format varchar(10) and my select statement is something like this: insert into table values (abba,http://...abba1.wmv,3 mb,3

Re: [PHP] delete duplicates from array and insert statement

2005-09-17 Thread Jasper Bryant-Greene
Ryan A wrote: want i want to do is, do a select and get the data that is already in the db, compare it, and if its in the insert statement delete those rows... am getting screwed up in the logic for this...so far I have exploaded the insert statement so its in a neat array, now i need to check

Re: [PHP] delete session cookie?

2005-04-21 Thread William Stokes
Thanks. That's what I was looking for... Burhan Khalid [EMAIL PROTECTED] kirjoitti viestissä:[EMAIL PROTECTED] William Stokes wrote: Hello, Is it possible to delete a session cookie from browser? If so how? http://www.php.net/manual/en/function.session-destroy.php See the example. --

[PHP] delete session cookie?

2005-04-20 Thread William Stokes
Hello, Is it possible to delete a session cookie from browser? If so how? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] delete session cookie?

2005-04-20 Thread Petar Nedyalkov
On Wednesday 20 April 2005 14:51, William Stokes wrote: Hello, Is it possible to delete a session cookie from browser? If so how? Just unset it. Thanks -Will -- Cyberly yours, Petar Nedyalkov Devoted Orbitel Fan :-) PGP ID: 7AE45436 PGP Public Key: http://bu.orbitel.bg/pgp/bu.asc PGP

Re: [PHP] delete session cookie?

2005-04-20 Thread Burhan Khalid
William Stokes wrote: Hello, Is it possible to delete a session cookie from browser? If so how? http://www.php.net/manual/en/function.session-destroy.php See the example. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] delete file

2005-03-24 Thread William Stokes
Hello, How can I let user delete a uploaded image file in the server's directory? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] delete file

2005-03-24 Thread Jay Blanchard
[snip] How can I let user delete a uploaded image file in the server's directory? [/snip] http://www.php.net/unlink -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] delete file

2005-03-24 Thread Richard Davey
Hello William, Thursday, March 24, 2005, 2:08:13 PM, you wrote: WS How can I let user delete a uploaded image file in the server's WS directory? unlink() Best regards, Richard Davey -- http://www.launchcode.co.uk - PHP Development Services I do not fear computers. I fear the lack of them.

[PHP] Delete last 15 chars from a file

2005-03-02 Thread Shaun
Hi, I am trying to create an XML file, it will be done in stages so if the file isn't present I will add the line: ?xml version=1.0 ? root_element Then for each line I add I add the following child_elementdatachild_element But for various reasons the application won't know when

Re: [PHP] Delete last 15 chars from a file

2005-03-02 Thread Burhan Khalid
Shaun wrote: Hi, I am trying to create an XML file, it will be done in stages so if the file isn't present I will add the line: ?xml version=1.0 ? root_element Then for each line I add I add the following child_elementdatachild_element But for various reasons the application won't

[PHP] Delete a file immediately after download

2005-02-15 Thread Shaun
Hi, I have a database that contains encrypted data using Mysql function ENCODE(). Certain users will be allowed to view this data and I will allow them to download a CSV file contain the decrypted data using the Mysql DECODE() function. However I don't want this file to be left on the server,

Re: [PHP] Delete a file immediately after download

2005-02-15 Thread Matt M.
I have a database that contains encrypted data using Mysql function ENCODE(). Certain users will be allowed to view this data and I will allow them to download a CSV file contain the decrypted data using the Mysql DECODE() function. However I don't want this file to be left on the server, is

Re: [PHP] Delete a file immediately after download

2005-02-15 Thread Shaun
Hi Matt, Thanks for the reply, I know how to delete a file I just wanted to know if its possible to ensure that its deleted automatically as soon as the user has downloaded it. Thanks... Matt M. [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I have a database that contains

Re: [PHP] Delete a file immediately after download

2005-02-15 Thread Richard Lynch
Shaun wrote: Thanks for the reply, I know how to delete a file I just wanted to know if its possible to ensure that its deleted automatically as soon as the user has downloaded it. Yes. You don't even put the file into your web tree DocumentRoot directory, and you write a PHP script that

Re: [PHP] Delete a file immediately after download

2005-02-15 Thread Richard Lynch
Matt M. wrote: I have a database that contains encrypted data using Mysql function ENCODE(). Certain users will be allowed to view this data and I will allow them to download a CSV file contain the decrypted data using the Mysql DECODE() function. However I don't want this file to be left on

Re: [PHP] Delete a file immediately after download

2005-02-15 Thread Bret Hughes
On Tue, 2005-02-15 at 14:00, Richard Lynch wrote: Matt M. wrote: I have a database that contains encrypted data using Mysql function ENCODE(). Certain users will be allowed to view this data and I will allow them to download a CSV file contain the decrypted data using the Mysql DECODE()

Re: [PHP] Delete a file immediately after download

2005-02-15 Thread Marek Kilimajer
Shaun wrote: Hi, I have a database that contains encrypted data using Mysql function ENCODE(). Certain users will be allowed to view this data and I will allow them to download a CSV file contain the decrypted data using the Mysql DECODE() function. However I don't want this file to be left on

Re: [PHP] Delete a file immediately after download

2005-02-15 Thread Shaun
Hi Marek, Thanks for your reply, could you tell me how I would go about this please? Marek Kilimajer [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Shaun wrote: Hi, I have a database that contains encrypted data using Mysql function ENCODE(). Certain users will be allowed to

Re: [PHP] Delete a file immediately after download

2005-02-15 Thread Marek Kilimajer
Shaun wrote: Hi Marek, Thanks for your reply, could you tell me how I would go about this please? Marek Kilimajer [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Shaun wrote: Hi, I have a database that contains encrypted data using Mysql function ENCODE(). Certain users will be

Re: [PHP] Delete a file immediately after download

2005-02-15 Thread Jason Barnett
Shaun wrote: Hi Marek, Thanks for your reply, could you tell me how I would go about this please? ?php header('Content-type: text/csv'); header('Content-Disposition: attachment; filename=download.csv'); /** Now you perform the MySQL query, DECODE the information and echo it to the screen.

Re: [PHP] Delete a file immediately after download

2005-02-15 Thread Richard Lynch
Shaun wrote: Hi Marek, Thanks for your reply, could you tell me how I would go about this please? ?php require 'connect.inc'; $query = select * from whatever; $data = mysql_query($query); while ($row = mysql_fetch_row($data)){ echo implode(\t, $data), \n; } ? You can muck

[PHP] Delete all files in DIR every 20 days

2005-02-14 Thread Tim Burgan
Hello, How can I delete ALL files within a specified directory every 20 days? Does anyone know of any code-snippets that are around at the moment that are able to do this? (And where I can find them?) Thanks Tim -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

[PHP] Delete all files in DIR every 20 days

2005-02-14 Thread Tim Burgan
Hello, How can I delete ALL files within a specified directory every 20 days? Does anyone know of any code-snippets that are around at the moment that are able to do this? (And where I can find them?) Thanks Tim -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

RE: [PHP] Delete all files in DIR every 20 days

2005-02-14 Thread Jay Blanchard
[snip] How can I delete ALL files within a specified directory every 20 days? Does anyone know of any code-snippets that are around at the moment that are able to do this? (And where I can find them?) [/snip] Create a script that deletes files in the directory and then CRON it.

RE: [PHP] Delete all files in DIR every 20 days

2005-02-14 Thread Mikey
How can I delete ALL files within a specified directory every 20 days? Does anyone know of any code-snippets that are around at the moment that are able to do this? (And where I can find them?) Thanks Tim Sounds more like a job for cron than for PHP - man crontab should set you up...

Re: [PHP] Delete all files in DIR every 20 days

2005-02-14 Thread Greg Donald
On Tue, 15 Feb 2005 01:22:42 +1030, Tim Burgan [EMAIL PROTECTED] wrote: How can I delete ALL files within a specified directory every 20 days? Does anyone know of any code-snippets that are around at the moment that are able to do this? (And where I can find them?) You can put a tmp file in

Re: [PHP] Delete all files in DIR every 20 days

2005-02-14 Thread Robby Russell
On Tue, 2005-02-15 at 02:12 +1030, Tim Burgan wrote: Hello, How can I delete ALL files within a specified directory every 20 days? Does anyone know of any code-snippets that are around at the moment that are able to do this? (And where I can find them?) Thanks Tim What operating

Re: [PHP] Delete all files in DIR every 20 days

2005-02-14 Thread John Nichel
Tim Burgan wrote: Hello, How can I delete ALL files within a specified directory every 20 days? Does anyone know of any code-snippets that are around at the moment that are able to do this? (And where I can find them?) Thanks Tim Write a script that will delete them, and set the script to run on

RE: [PHP] Delete all files in DIR every 20 days

2005-02-14 Thread Torsten Rosenberger
Hello take a look a the Pear File_Find class require_once 'File/Find.php'; $fs = new File_Find; $data = $fs-maptree('my_dir'); $data[0] contains all directorys $data[1] all files $ok = 0; $err = 0; foreach ($data[1] as $key) { if

Re: [PHP] delete part of array

2005-01-13 Thread Leif Gregory
Hello Jochem, Wednesday, January 12, 2005, 8:08:09 PM, you wrote: JM read the manual entry first (see below) - and understand what the JM function actually does - never just assume because its giving you JM the result you want now that it will always work the way you JM expect. Don't be a

Re: [PHP] delete part of array

2005-01-13 Thread Matthew Fonda
use the unset() function. for ($i = 0; $i count($array); $i++) { if (empty($array[$i]) { unset($array[$i]); } } On Wed, 2005-01-12 at 16:22, Sebastian wrote: how do i delete keys from an array if it has no values? eg, this: [name] = Array ( [0] =

Re: [PHP] delete part of array

2005-01-13 Thread M. Sokolewicz
that only works for numerical indices. However, if you're sure that neither null values, nor false values are supposed to be present in the array, (that means, they MIGHT be, but should be removed anyway; or just not be there at all,) then you could try array_filter with no callback-argument :)

Re: [PHP] delete part of array

2005-01-13 Thread Sebastian
coder would go for help FIRST, but it doesn't always solve a problem thats why there is a thing called MAILING LIST. :) cheers. - Original Message - From: Leif Gregory [EMAIL PROTECTED] To: php-general@lists.php.net Sent: Thursday, January 13, 2005 7:39 AM Subject: Re: [PHP] delete part

RE: [PHP] delete part of array

2005-01-13 Thread Ford, Mike
To view the terms under which this email is distributed, please go to http://disclaimer.leedsmet.ac.uk/email.htm On 13 January 2005 05:28, Matthew Fonda wrote: use the unset() function. for ($i = 0; $i count($array); $i++) { if (empty($array[$i]) {

Re: [PHP] delete part of array

2005-01-13 Thread Jochem Maas
crap - hit 'reply' by mistake. --- Leif Gregory wrote: Hello Jochem, Wednesday, January 12, 2005, 8:08:09 PM, you wrote: JM read the manual entry first (see below) - and understand what the JM function actually does - never just assume because its giving you JM the result you want now that

Re: [PHP] delete part of array

2005-01-13 Thread John Nichel
Ford, Mike wrote: snip Without actually running it (I'm too lazy!), I'm pretty sure this won't work correctly -- the count($array) is being recalculated each time round the loop, so each time you do an unset() it will reduce by one, resulting in the last few elements never being checked. /snip Not

Re: [PHP] delete part of array

2005-01-13 Thread Leif Gregory
Hello Jochem, Thursday, January 13, 2005, 10:55:35 AM, you wrote: J heh but who says I'm not a bar steward ;-) grin I'll take a beer then! I need one after today. J sorry if it came accross a little harsh, but I stand by the point J that the onus is on the person asking the question to give an

[PHP] delete part of array

2005-01-12 Thread Sebastian
how do i delete keys from an array if it has no values? eg, this: [name] = Array ( [0] = grape [1] = apple [2] = [3] = orange [4] = [5] = cherry ) to: [name] = Array ( [0] = grape [1] = apple [2] = orange [3] = cherry ) --

Re: [PHP] delete part of array

2005-01-12 Thread Tatang Widyanto
Sebastian wrote: how do i delete keys from an array if it has no values? eg, this: [name] = Array ( [0] = grape [1] = apple [2] = [3] = orange [4] = [5] = cherry ) to: [name] = Array ( [0] = grape [1] = apple [2] = orange [3] =

Re: [PHP] delete part of array

2005-01-12 Thread Leif Gregory
Hello Sebastian, Wednesday, January 12, 2005, 5:22:20 PM, you wrote: S how do i delete keys from an array if it has no values? S eg, this: array_merge($name); Try it that way first. If not, $name = array_merge($name); But I think I remember the first way working for me. Cheers, Leif

Re: [PHP] delete part of array

2005-01-12 Thread Jochem Maas
Sebastian wrote: how do i delete keys from an array if it has no values? eg, this: what does the value have to do with it??? other than that you want to remove items where the value is 'empty'. also 'no value' is vague, do you mean an empty string or do you mean NULL? --- try the array_values()

Re: [PHP] delete part of array

2005-01-12 Thread Jochem Maas
Leif Gregory wrote: Hello Sebastian, Wednesday, January 12, 2005, 5:22:20 PM, you wrote: S how do i delete keys from an array if it has no values? S eg, this: array_merge($name); Try it that way first. If not, read the manual entry first (see below) - and understand what the function actually

  1   2   3   >