Jump to content

benbyf

Members
  • Content Count

    653
  • Joined

  • Last visited

  • Days Won

    3

benbyf last won the day on July 18 2016

benbyf had the most liked content!

Community Reputation

673 Excellent

About benbyf

  • Rank
    Hero Member

Contact Methods

  • Website URL
    http://www.benbyford.com

Profile Information

  • Gender
    Not Telling
  • Location
    Bristol, UK

Recent Profile Visitors

27,162 profile views
  1. Yes the PaymentStripeIntents module does implement their new Intents API and is therfore SCA ready.
  2. this would be ace. if I had more time I would look into it, but sort of scares me. 😕
  3. Want to save the col and row info in the db so i can use it for css grid in the frontend. This will allow the client to add content that spans the first row, has two on the send that goes across half the grid, has 4 on the third row and has 2 with a gap in the middle on the fourth.... basically given them power to making interesting layout with whitespace. Ideally your right I would have the grid power the input of the PW fields and hide the col and row inputs but this is what i have so far. admin.php $config->scripts->add($config->urls->templates . "admin.js"); $config->styles->add($config->urls->templates . "admin.css"); admin.cs .table-grid{ display: grid; grid-template-columns: 1fr 1fr 1fr 1fr 1fr; } .grid-item{ /* border: 1px solid £; */ padding: 0.5em; } .activeGridName{ background: rgb(197, 219, 226) !important; } admin.js $(function(){ // custom grid script for pages with applicable table // name of input field var inputFieldName = "#wrap_Inputfield_featured_grid"; if($(inputFieldName)){ // table found var table = "<br><div class='table-grid-container'><label class='uk-form-label'>Frontend representation</label><div class='table-grid Inputfield'>"; // setup table var rows = $(inputFieldName+" .InputfieldContent table tbody tr"); // UI has 1 hidden row for (var i = 1; i < rows.length; i++) { var director = $(rows).eq(i).find(".InputfieldPageAutocomplete input.ui-autocomplete-input"); var tds = $(rows).eq(i).find("td"); var colStart = $(tds).eq(2).find('input'); var colStartValue = $(colStart).attr("value"); var rowStart = $(tds).eq(3).find('input'); var rowStartValue = $(rowStart).attr("value"); var colEnd = $(tds).eq(4).find('input'); var colEndValue = $(colEnd).attr("value"); var rowEnd = $(tds).eq(5).find('input'); var rowEndValue = $(rowEnd).attr("value"); var name = $(director).attr("value"); $(colStart).addClass('table-value-input') .attr('data-table-type','colStart') .attr('data-name-data',name); $(rowStart).addClass('table-value-input') .attr('data-table-type','rowStart') .attr('data-name-data',name); $(colEnd).addClass('table-value-input') .attr('data-table-type','colEnd') .attr('data-name-data',name) $(rowEnd).addClass('table-value-input') .attr('data-table-type','rowEnd') .attr('data-name-data',name) $(rows).eq(i).attr("data-name",name); // console.log(colStart + " - " + rowStart + " - " + colEnd + " - " + rowEnd); var styles = "grid-row-start: "+rowStartValue+"; grid-column-start: "+colStartValue+"; grid-row-end: "+rowEndValue+"; grid-column-end: "+colEndValue+";"; table += "<div class='grid-item Inputfield' style='"+styles+"' data-name='"+name+"'>"+name+"</div>"; } table += "</div></div>"; // add table to UI $(inputFieldName+" .InputfieldContent").append(table) // value changes and event listening $(document).on("change", "input.table-value-input", function(){ var name = $(this).attr("data-name-data"); var data = $(this).attr("value"); var type = $(this).attr('data-table-type'); console.log(data); console.log(type); console.log(name); switch (type) { case "colStart": $(".grid-item[data-name='"+name+"']").css("grid-column-start", data); break; case "rowStart": $(".grid-item[data-name='"+name+"']").css("grid-row-start", data); break; case "colEnd": $(".grid-item[data-name='"+name+"']").css("grid-column-end", data); break; case "rowEnd": $(".grid-item[data-name='"+name+"']").css("grid-row-end", data); break; default: break; } }); $(document).on("mouseover", "[data-name]", function(){ var data = $(this).attr("data-name"); $("[data-name='"+data+"']").addClass("activeGridName"); }); $(document).on("mouseout", "[data-name]", function(){ var data = $(this).attr("data-name"); $("[data-name='"+data+"']").removeClass("activeGridName"); }); } }); Main problem at the moment is it isn't very portable–you have to know the field name for it to work.
  4. Also as an aside... does anyone esle think the functionality in Pro fields: Table should be in core?? Seems too useful or basic requirement.
  5. Tried to create a module for this and got into a hole of SQL schema and module doc spagetti so gave up. Instead I bought Pro fields: Tables as it looked like it was almost there and hacked some javascript and css ontop to get this. I'm going to use the row and column data in the frontend to assign my grid so they should be the same. processwire-pro-tables-hack.mov
  6. I did this as @psy mentioned using those two modules. In my implementation I allowed my client to upload to folders in dropbox and in Processwire assign users access to specific folders (and the files within). On the frontend I would present the logged in user on the site with thier folder and files the client was sharing with them -> this was for promotional materials but could be anything really.
  7. Thanks! Hugely usefull! Think my main issue is the grid editing element so I might implement most of the site and leave the editable image/link section till last and maybe look at building something. I would like it to mirror the frontend as much as possible, so i could just use css grid and do some limited js stuff pushing the page id's, item number and span columns and rows into the database..... mmmmmmmmmmmmm
  8. Is there any way to create an input grid within a edit page which allows the user to select a cell and assign a page to it, e.g. from a list of pages of template "x" select one and assing it so that in the templates the table can be created and cells refer to the page itself or its id? I'm working on a site where the clients wishes to have a grid layout that they can adhocly put different page images into that link to the pages about that project. However they want each cell to be assignable or not and be able to span 1 or more cells... making an expressive layout. Any thoughts would be appreciated
  9. Just had a quick look and they're very similar. I'm using: $intent = $payment->paymentCheckout($description); Instead of $payment->render(); The $intent variable then returns an array of the [0] Stripe form and [1] Intent Id. https://github.com/benbyford/PaymentStripeIntents/blob/master/PaymentStripeIntents.module#L138 This is because you may want to store only the Intent or just the form. Like to spend some more time with this module soon, so there will probably better Readme and additions soon.
  10. I can look at getting them more closely integrated when I’m back next week from holidays. I’ve not used the padloper module and tbh it might be better that they integrate it or do their own as I’m not selling this as a premium module, just my own version of the new Stripe Intents API
  11. Hey @MarcoPLY did you follow the readme? The render method currently doesn’t do anything in this module.
  12. Ah ok thanks, probably to do with the schema of the site profile I’m installing then. Will try starting from a default profile and overwriting to get where I was. Thanks
  13. Very confused about this, did an installation, wanted to change profiles so deleted EVERYTHING and reinstalled and getting this very strange error: Anyone come across this, not happened before. I use serverpilot.com and digitalocean with Ubuntu 14 boxes installing 3.0.123
  14. More implementations Ajax modal version: : New page version:
  15. Example implementation: Info: So this is very much an ALPHA version of what I hope turns into a swiss armory knife payment module. Currently you are able to take payments with the payments form or cross browser payments button (Apple Pay etc). Please read implementation details here and consider contributing https://github.com/benbyford/PaymentStripeIntents TODO: Add subscription functionality Add customer functionality More testing and code clean up More usage examples anything else?
×
×
  • Create New...