Jump to content

pwfans

Members
  • Content Count

    36
  • Joined

  • Last visited

Community Reputation

11 Good

About pwfans

  • Rank
    Jr. Member

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Site B get data from site A using : $items = $siteA->pages->find("parent=/productA/,limit=10"); foreach ($items as $item) { .... } $items->renderPager(); Pagination displayed correctly but they page number path also goes to siteA, which is off course not work when clicked. How to do this pagination properly in multi-instance ? thanks
  2. @bernhard sorry, i make you confuse by my bad english 😭 I mean, try to place this : <?php $pdf = $modules->get('RockPdf'); $pdf->write("pdf content"); $pdf->show(); ?> before any html content, at first line if possible.
  3. For anybody facing this problem which in my case invalid pdf will generate error "one or more XREF chunks were not found". Solved it by placing the rockpdf instance php code block on top of anything else.
  4. @kongondo Thanks a lot ! just knew functions API can be enabled by this way 👍
  5. I'm using 2 multi instance, both same version (3.0.148) with this state at config.php $config->useFunctionsAPI = false;
  6. I also thinking about how to "reset" page ID, in my case after web development finish, there are thousand pages used while at development stage for testing, database backup module from ryan give a very convenience way to "reset/back to safe point" but it s not bulletproof solution in my case, restoring database backup will also delete all pages, templates, fields that need to used after development finished. Now i use recycle way, i unpublished those redundant pages, and make API used them first whenever need new page until those redundant page all use up.
  7. @maddmac Never have a project using formbuilder yet but if it is about front end, I think you can implement what this module get inspired from: https://leaverou.github.io/awesomplete/ Quit simple to implement, thanks to creator.
  8. Maybe below code can help for simple group by date for example : $list = $pages->find("template=event"); $groups = array(); foreach ($list as $item) { $groups["$item->date"][] = $item->id; } foreach($groups as $key => $gr){ echo $key."<br>"; }
  9. @MoritzLost Thank you ! works like expected
  10. Hello all, Is there a way to find cookies that generated using dynamic name ? like "name_randomcode" eg: name_123z, name_321x, etc ..
  11. php code to create multiple pages : if ($input->post->submit) { $amount = count($input->post->field_1); for($i=0;$i<$amount;$i++) { $p = new Page(); $p->template = "template_1"; $p->parent = wire('pages')->get("/parent_1/"); $p->title = $input->post->field_1[$i]; $p->name = $input->post->field_1[$i]; foreach ($input->post->field_2 as $result) { $p->text.= $result." "; } $p->save(); } } html code : <tr> <td><input type="text" name="field_1"></td> <td> <select name="field_2[]" multiple="multiple"> <option value="opt_1">opt_1</option> <option value="opt_2">opt_2</option> <option value="opt_3">opt_3</option> </select> </td> </tr> <tr> <td><input type="text" name="field_1"></td> <td> <select name="field_2[]" multiple="multiple"> <option value="opt_1">opt_1</option> <option value="opt_2">opt_2</option> <option value="opt_3">opt_3</option> </select> </td> </tr> ... and another <tr>..</tr> addition using javascript There is off course incorrect value on field_2, they will contain same data get from field_2 on first row. Have try on google search and not found any solution yet, there are talk about multi-dimensional array but still not understand how to implement that.
  12. Thanks a lot @teppo and @adrian I ended up with @teppo's way using selector string, and using check_access=0 (just knew this) works like expected !
  13. Using page reference field to get some users under certain role: - At input tab, i select "Custom find" to query users under certain roles. Problem is: for user_1 which is not superuser, above field doesn't work, page reference content not displayed. However if i give superuser role to user_1, above field work like expected which of course, i don't want to give superuser role to user_1. I already tried check all permissions available to user_1 and add custom predefined system permissions (user-admin-all, user-admin-[role]), still doesn't work.
  14. On localhost, icon spinner not loading when using option D (dialog editor) in front-end edit, looks like below : This must be path problem to fontawesome css but i can't find which file need to edit.
  15. Yes !, it fixed in this update, Thanks 👍
×
×
  • Create New...