Jump to content

benbyf

Members
  • Posts

    811
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by benbyf

  1. @Christophe thats madness, not seen this issue before. Seems Opera and Chromium (though only tested on Opera), is having a problem with css column-count. Any experience with this as can't rectify on quick test.
  2. Thanks gang, this is why i love this forum. @maxf5 not really a bug, but maybe could be improved (peril of only testing on a laptop ). @dragan totally right, i might kill the twitter on mobile and thanks for the php spot.
  3. Yep fully aware. Client's dragging their feet to add content.
  4. http://artistblacksmith.org.uk/ Portfolio site for Blacksmith working in Gloucesterhire, UK. Design and build. http://stellardebating.nicegrp.com/ Not yet live site for school debating courses across UK. Custom payment system for booking and managing courses and teachers at multiple schools. Design, logo design, build. Illustrtion by http://torritaylored.com/ http://store.benbyford.com/ Not yet live store fo premium modules. Started working on this and got lots of client work so haven't got back to it yet to finish and release modules. Fingers crossed will have the time soon. Design and build.
  5. Cant actually see why this is the case, works fine on desktop browserss, but on iOS safari it disregards the right hand menu items <a> events ...
  6. Awesome work! Keep it up! quick note, the logo looks abit crunchy on my macbook pro, would suggest hi res image or svg.
  7. benbyf

    DropboxAPI

    Hi everyone. I've made a tiny module for adding a folder select input in the admin, this allows you to select a folder path from the dropbox account associated with the DropboxAPI module. This module requires the above DropboxAPI module to work. I made this with a lot of great advice from @abdus though much simpler than I think they would have done it. TBH I got totally confused about how to implement fieldtypes and inputfield modules and I hope that there could be an effort for tutorials or docs on this - e.g. requirements to register a inputfield, setting and using config options, interacting with the input on a page, creating a fieldtype and requirements, schema best practise.. etc. https://github.com/benbyford/InputfieldDropbox install / setup: DropboxAPI module download and install DropboxAPI module, adding to your site/modules folder install in modules section of admin goto: https://www.dropbox.com/developers/apps add new app choose dropbox api, folder access, then name the folder which will appear in your dropbox /apps/ copy api codes and add to DropboxAPI settings. InputfieldDropbox module download and install InputfieldDropbox module, adding to your site/modules folder install in modules section of admin add new textarea field in processwire admin, save within Details tab, select Dropbox on Input type select box. This gif shows me selecting from options found within my dropbox account within folder /apps/theNameOfTheRegisteredFolder.
  8. Pithy comment alert: If its not broke. Give it ago a report back (this harps back to simply making your own admin using the API). and Age over beauty (there's probably more where those come from
  9. Vanilllllllllla js for the win. Although for me its the right tool for the job. Jquery is mostly a sugar to make browsers play nice, and a toolkit of repeatable actions (fade, move, etc). Vue and React are MV* for two way data binding... so basically doing mostly a different job (altough like angular your find front end animation helpers too). Soooo, frameworks go out of fashion (remember when everyone was using Backbone?!), but vanilla won't and right tool for the job.
  10. benbyf

    DropboxAPI

    Still doesnt make sense to me, anyone else got a tutorial or good examples of how inputfields and field types can be implemented? Or maybe can even pay someone for an hours english tutorial over hangout or skype, as would like to get to gribs with this for future modules. Thanks
  11. 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.
  12. benbyf

    DropboxAPI

    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... ?
  13. benbyf

    DropboxAPI

    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.
  14. benbyf

    DropboxAPI

    Sorry, im super dumb obviously, but dont know need the fieldtype module to implement the new inputfield? how do you choose the inputfield otherwise?
  15. benbyf

    DropboxAPI

    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.
  16. benbyf

    DropboxAPI

    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.
  17. seem to be getting a number "1" added to the first custom field for some reason.
  18. 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 :/
  19. 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?
  20. benbyf

    DropboxAPI

    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);
  21. benbyf

    DropboxAPI

    WORKED!!!!! WHHHHOOOOPPPP. Thank you! Obvioulsy a bit of a n00b still for "proper" dev stuff. any good articles about composer best practises? Thanks
×
×
  • Create New...