We've needed a file example for some time.

So far this one demonstrates the key D7 APIs.

Next step is to demonstrate a custom streamwrapper.

Comments

rfay’s picture

Component: Other » File Example
Status: Active » Needs review

Would appreciate review by anyone and everyone.

rfay’s picture

StatusFileSize
new30.76 KB

This patch extends the above example by adding support for a session:// scheme, where "files" are written to a subkey of the $_SESSION variable. It provides a nearly complete read/write stream wrapper example.

gdd’s picture

subscribe, will try and review later

dman’s picture

Thanks for this. I don't understand it all yet, but it's good to know that docs are there.

rfay’s picture

StatusFileSize
new44.65 KB

OK, now with significant tests and a pretty exhaustive streams demo implementation.

rfay’s picture

Status: Needs review » Fixed

Committed to CVS HEAD
http://drupal.org/cvs?commit=405304

Review is still welcomed!

rfay’s picture

Status: Fixed » Needs work

For some reason, despite the fact that the commit shows, this isn't in the release package, and it's also not being tested.

rfay’s picture

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, examples.file_example_874364_05.patch, failed testing.

rfay’s picture

Status: Needs work » Fixed

Tests are running and passing now.

bicherele’s picture

Status: Fixed » Needs review
rfay’s picture

Status: Needs review » Fixed

@bicherele, this has already been committed. See #6. Your review is still appreciated though.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.