Jump to content


  • Content Count

  • Joined

  • Last visited

  • Days Won


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

Profile Information

  • Gender
    Not Telling
  • Location
    Bristol, UK

Recent Profile Visitors

29,664 profile views
  1. Unable to install module (ProcessRedirects): Specified key was too long; max key length is 1000 bytes get this when installing ProcessRedirects on PW 3.0.139. It adds an empty admin page to Setup and dies before publishing. Any help would be appreciated.
  2. Great to hear its working for you. I have the same issue but its nothing that is wrong per say. Everytime a intent is created it creates an incomplete transaction on your account which is then followed by a completed transaction or failed depending on the user suceeding in the transaction. If you can work out how to get around this let me know, but I thought it was just a quirk of the new way of working.
  3. will this need a $p->save to make it work?
  4. Yes the PaymentStripeIntents module does implement their new Intents API and is therfore SCA ready.
  5. this would be ace. if I had more time I would look into it, but sort of scares me. 😕
  6. 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.
  7. Also as an aside... does anyone esle think the functionality in Pro fields: Table should be in core?? Seems too useful or basic requirement.
  8. 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
  9. 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.
  10. 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
  11. 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
  12. 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.
  13. 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
  14. Hey @MarcoPLY did you follow the readme? The render method currently doesn’t do anything in this module.
  15. 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
  • Create New...