Jump to content

Search the Community

Showing results for tags 'image upload description'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to ProcessWire
    • News & Announcements
    • Showcase
    • Wishlist & Roadmap
  • Community Support
    • Getting Started
    • Tutorials
    • FAQs
    • General Support
    • API & Templates
    • Modules/Plugins
    • Themes and Profiles
    • Multi-Language Support
    • Security
    • Jobs
  • Off Topic
    • Pub
    • Dev Talk

Product Groups

  • Form Builder
  • ProFields
  • ProCache
  • ProMailer
  • Login Register Pro
  • ProDrafts
  • ListerPro
  • ProDevTools
  • Likes
  • Custom Development

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests

Found 1 result

  1. Hello, I don't know how to set the description when uploading multiple images through the api. So far images get uploaded nicely. // instantiate the class and give it the name of the HTML field $u = new WireUpload('uploads'); // tell it to only accept 5 files $u->setMaxFiles(5); // tell it to rename rather than overwrite existing files $u->setOverwrite(false); // have it put the files in their final destination. this should be okay since // the WireUpload class will only create PW compatible filenames $u->setDestinationPath($page->images->path); // tell it what extensions to expect $u->setValidExtensions(array('jpg', 'jpeg', 'gif', 'png')); // execute() returns an array, so we'll foreach() it. foreach($u->execute() as $filename) { $page->images->add($filename); } // save the page $page->save();
×
×
  • Create New...