All Activity

This stream auto-updates     

  1. Past hour
  2. Could be - but i don´t know, where to put the selector. do you have any code example?
  3. hi my friend i verify my language to fa but your code not working , i was test that i need a code when visitor choose persian language , site template wtich to rtl
  4. @itsberni For the issue, What I've done to solve this is that I basically build a button separate from the calendar and build the url accordingly. Will get back with code details later, just in a bit of a hurry now. For the question, Doesn't passing a selector in the renderCalendar options let you filter the events you need? So that you could could use p=1 in the query parameters?
  5. Today
  6. wbmnfktr

    Just yesterday I ran into a similar problem. Saving the page didn't work at all. Hat to update some content (15 000+ characters) on a page. All in a regular textarea field without any min/max content settings. The result of saving the page was... 1. console log error Resource interpreted as Document but transferred with MIME type application/x-httpd-php 2. file download of a file named Download with this in it. <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> <html><head> <title>503 Service Unavailable</title> </head><body> <h1>Service Unavailable</h1> <p>The server is temporarily unable to service your request due to maintenance downtime or capacity problems. Please try again later.</p> </body></html> Couldn't figure out why this happened and still happens. Tried the exact same on different servers/instances (Dev/Stage/Live) of that site with the result: Dev - a local Laragon instance: works Stage - US Shared Hosting: works Live - DE Shared Hosting: breaks Same ProcessWire and module versions across all instances. Seems to be a server/hosting thing.
  7. MarcoPLY

    Thank you @flydev! is it right do this: if($input->post->customerForm) { // It's the button ID, right? //instantiate variables taking in the form data // set other profile var... $invoice_CF = $sanitizer->text($input->post->Inputfield_invoice_CF); // update user details $user->of(false); $user->Inputfield_profile_invoice_CF = $invoice_CF; // is it correct? or use the field name? $user->save(); $user->of(true); } but, can I serialize all the data using the from ID and then update the user filed? or I need set all the variables ? (are not a lot I can do...) I see an error like this: at line // update user details syntax error, unexpected ' ' (T_STRING)
  8. tpr

    Hi, (1) I could reproduce, thanks. For a quick fix use this, or wait for a new version: html.pListShowActions .content .PageList .PageListItem { width: 100%; } (2) I'm aware of this, will try to fix with some CSS. I recommend using Reno or Uikit theme, most AOS features are targeted/tested in them.
  9. flydev

    Hi marco, to populate the profile, just set and save the user information page, eg : if($input->post->checkout_submit) { // the checkout form submit action //instantiate variables taking in the form data $cart = $sanitizer->text($input->post->cart); // set other profile var... // update user details $user->of(false); $user->cart = $cart; // update the "cart" field $user->save(); $user->of(true); } As you said, you will need to add the fields to the user profile.
  10. MarcoPLY

    Hi @flydev, Is it possible update the user data form other form? I mean, user make the registration with one form, that in the website there are other interaction, like the checkout form, is it possible with this checkout form integrate or update the user information ? So, I think first I need add all the field in the user page, in the way there are a place for put the data, but for to populate these fields how I do?
  11. ngrmm

    i was able to get it this was: $files = glob("../dir/*.*"); $files = array_combine($files, array_map("filemtime", $files)); arsort($files); $latest_file = key($files);
  12. horst

    You don't need the URL, you also can use the filename, as the images are all in your webspace filesystem. $imagedir = $config->paths->templates . "images/"; To grab the latest imagefile, you have to read and compare file timestamps, like last modified. Check PHP functions for that and directory iteration: https://secure.php.net/manual/en/function.filemtime.php https://secure.php.net/manual/en/function.dir.php
  13. i have jpegs inside a folder (images). the folder is located in the templates-folder of PW site > templates > images every 30 minutes a script generates and saves jpegs into the images-folder. the all have a unique filename. is it possible to save all those images into a image-field through API? if not, is it possible to add the newest one into the imagefield? i found this $p = $pages->get(1001); $p->of(true); // if in a template code, turn off output formatting $p->images->add("http://placehold.it/350x150.jpg"); $p->save(); $p->of(false); but i don't know how to grab the url automaticly of the newest file.
  14. Zeka

    https://processwire.com/apigen/class-Exception.html#___construct Example https://github.com/processwire/processwire/blob/48fe0769a4eb3d0f5b4732fd01b4b4ed8262d952/wire/core/Fields.php#L165
  15. ottogal

    Hi all, on a fresh PW 3.0.98 installation using Default Admin theme and site-default profile I have installed AOS 1.9.4 as the only site module. Two observations: (1) When in PageListTweaks I check Always show pagelist actions, in the page tree there are no line breaks any more between the entries - see attached screenshot. How do I get them back? (2) Having checked Sticky header in Admin tweaks, when on the settings page of the module I click the cog of a Submodule, the sticky header would overlay the top lines of the options of the chosen submodule. Not big problems - many thanks for this incredibly useful module!
  16. hberg539

    Oh, you are right. I really had an error of thought with my example of iteration over 100.000 posts. The unique identifier (email address) reduces the selection to only one entry, so the ->matches() method really is no problem here. It seems i had a dangerously low level of coffeine while writing this. Thanks for the explanation.
  17. single or multiple filefield? try $file->first()->url
  18. @joshuag perhaps, i could take at least a quick look at it, to go further with this....many thanks!
  19. Hi, Maybe a dumb question. Shouldn't $file->url works like $image->url that both of them return path with filename?? Gideoon
  20. elabx

    Hi! I'm working on a module, and doing some Ajax operations, for example, I am creating some fields and doing this while checking if field already exists: if($fieldExists){ throw new WireException('Field already exists with that name. Please choose another name'); }else{ ... } In the response, I'm heading a 200 response code and the following code: {"error":true,"message":"Field already exists with that name. Please choose another name"} Is there a way I could customize that error message? if($fieldExists){ throw new WireException(array("message" => "...", "existingFieldId" => 1)); }else{ ... } And expect the response to have the custom info I want? I'm very intrigued on how the exception ends up as a json object in the resopnse. Thanks for further answers!
  21. Yesterday
  22. elabx

    Hi! Is this a valid approach to creating fieldsets? Doing this inside a module: $field = new Field(); $field->type = new FieldtypeFieldsetOpen(); $field->name = $sanitizedName; $field->label = $fieldLabel; $field->save(); $closer = $field->type->getFieldsetCloseField($field, true); Taken from here: https://github.com/processwire/processwire/blob/48fe0769a4eb3d0f5b4732fd01b4b4ed8262d952/wire/modules/Fieldtype/FieldtypeFieldsetOpen.module#L131
  23. Flashmaster82

    Happy dance!!! yaaay!!! I think i looks awesome now and it works perfect! Thank you so much for the help you are the best!!
  24. @Robin S perfect solution thank you so much! @OLSA very good to know another way to tackle the issue, thank you.
  25. I am probably missing something, but https://gitlab.com/baumrock/RockFinder/blob/master/ProcessRockFinder.info.php shows: 'version' => 1, Sorry, I see that: https://gitlab.com/baumrock/RockFinder/blob/master/RockFinder.info.php is 103 BTW - I would recommend string version numbers.
  26. Damn the <div class="dropdown"> is missing. echo "<div class='dropdown'> <div class'gf-flags-wpr'> ... </div> </div>"; It should work now, if not, then rename the class .dropdown to .lang-dropdown and replace each occurrence in the CSS code I give you.
  27. Flashmaster82

    This is how it looks like now, when i go over with the mouse the cursor will show upp but when i click on it it wont open?
  1. Load more activity