• Content count

  • Joined

  • Last visited

  • Days Won


benbyf last won the day on July 18 2016

benbyf had the most liked content!

Community Reputation

510 Excellent

About benbyf

  • Rank
    Hero Member

Contact Methods

  • Website URL

Profile Information

  • Gender
    Not Telling
  • Location
    London / Bristol, UK

Recent Profile Visitors

12,351 profile views
  1. Hi @cleanboy I think i'm right in saying that the payment modules are wrappers for the Stripe and Paypal libraries, therefore you can access the Stripe methods in Processwire. That said, I think you were asking how to use it, the example shows how you can pass amounts and basic customer information to Stripe, if a successful request is made Stripe pass you back a payment button which enables the customer to click and add their card details. The module does not store any information on the purchase, what was purchased, who by or anything infact, its just a way of interacting with Stripe or Paypal. If you need to track payments or are selling physical items you will need someway of keeping track of transactions and items like a store e.g. padloper or create your own tracking (which I've done several times mainly because I've been selling digital goods like subscriptions so have little need for item tracking or postage variables). Hope that helps.
  2. Cool thanks @abdus but again how the hell was I supposed to know that??? seems an old choice to have somethings just turn up in the admin (Process modules for example), and other types to be hookable without much reference. Think maybe a config, or function call would do the job... ?
  3. like poking a bear, how we supposed to know any of this?! I don't get any inputfields for text, but i do for textarea. How would i add one for text, or any other fieldtype , and is there any docs on this would be the actually question i guess... super infuriating.
  4. Sorry, im super dumb obviously, but dont know need the fieldtype module to implement the new inputfield? how do you choose the inputfield otherwise?
  5. Thanks @abdus (also nice website!), I'm justing working on the module now and finding i need both inputfield and fieldtypes modules to get things going. Think I'm having trouble still on what both of their relationship is together and what functions are required. I now have them both shoing up (i.e. as a fieldtype to select and showing something on page edit), but can't currently save the info not ideal - I was went back to the MApMaker module for reference which helped abit but couldnt instruct me on how these two modules working toegther.
  6. try really quickly to start writing a folder select fieldtype module to be used with the DropboxAPI module. However, I didnt get very far as the fieldtype inputfield module structure is super confusing to me, is there any documentation about creting a simple field type - and yes I've looked at the mapmaker module, i bascially want a list saying you need XYZ functions to make it appear (as I tried implementing from info in Fieldtype.php and wouldnt show up as an option when creating a new field). Any help would be grateful.
  7. seem to be getting a number "1" added to the first custom field for some reason.
  8. Thanks thats the one
  9. Sorry this has been on hiatus as i've had lots of work on and had to build a shop from the ground up in order to sell it :/
  10. HI! I think I saw a little while ago a image field module that added loads of features including adding more fields to a specific image in a image field, I can't find it googling anyone point me in the right direction?
  11. Just in case its useful for anyone, this is my function for creating a folder list with public links to files: <?php namespace ProcessWire; use Kunnu\Dropbox\Dropbox; use Kunnu\Dropbox\DropboxApp; use Kunnu\Dropbox\DropboxFile; $drop = $modules->get('DropboxAPI'); //Configure Dropbox Application $app = new DropboxApp($drop->app_key, $drop->app_secret, $drop->authorization_code); //Configure Dropbox service $dropbox = new Dropbox($app); // get folder from user $folder_path = ""; $folder_path = $user->folder; // get items from dropbox folder $listFolderContents = $dropbox->listFolder($folder_path); //root folder is the folder you nominated in the Dropbox App config. Refer doco $items = $listFolderContents->getItems(); function listItems($items, $dropbox, $depth = 0){ $out = "<ul class='depth-{$depth}'>"; foreach ($items as $item){ // get file name $name = $item->getName(); // getPathLower $path = $item->getpathLower(); $thumbPath = "no thumb"; $thumbHasExt = strpos($path, '.'); // file if($thumbHasExt && $path){ $file = $dropbox->getTemporaryLink($path); $link = $file->getLink(); $ext = substr($path, $thumbHasExt+1); // fontawesome file name icons $icon = "fa-file-o"; switch ($ext) { case 'png': case 'jpg': case 'gif': case 'psd': case 'tiff': $icon = 'fa-file-image-o'; break; case 'pdf': $icon = 'fa-file-pdf-o'; break; case 'mp3': case 'wav': $icon = 'fa-file-audio-o'; break; case 'mov': case 'mp4': case 'm4a': $icon = 'fa-file-video-o'; break; case 'doc': case 'docx': $icon = 'fa-file-word-o'; break; case 'xls': case 'xlsx': $icon = 'fa-file-excel-o'; break; case 'ppt': case 'pptx': $icon = 'fa-file-powerpoint-o'; break; case 'zip': case 'rar': $icon = 'fa-file-archive-o'; break; } $out .= "<li><span class='{$icon} fa'></span><a title='click to download' href='{$link}'>{$name} {$ext}</a></li>"; // folder }else{ ++$depth; $out .= "<li><span class='fa-folder-open-o fa'></span>{$name}"; $listSubFolderContents = $dropbox->listFolder($path); $items = $listSubFolderContents->getItems(); // get list of files in subfolder $out .= listItems($items, $dropbox, $depth); $out .= "</li>"; } } $out .= "</ul>"; return $out; } // get depth 0 folder items $out = listItems($items, $dropbox, $depth);
  12. WORKED!!!!! WHHHHOOOOPPPP. Thank you! Obvioulsy a bit of a n00b still for "proper" dev stuff. any good articles about composer best practises? Thanks
  13. Good point, not needed to use composer with Processwire yet, so didnt reach for it this time. I'm guess thats the problem then? Also no mention in teh installation notes either but might because i dont know what to look for maybe? Am i right in saying using composer also makes a module incompatible with the PW admin module installer?
  14. yep, updated. But like i mentioned there is simply no file called autoload in the repo... let allow a folder called vendor