Jump to content

flavy

Members
  • Posts

    8
  • Joined

  • Last visited

Everything posted by flavy

  1. Are you using cloudflare cdn or any other cdn ? I'm not sure what was the issue on my website as it fixed by itself. I am sure they are related to some minify/cache of the js files on the backend as the frontend was not affected at all.
  2. It seems I have a similar problem. They just stopped working, and the content of the tabs is shown under the first tab content. On the console I get the following error : JqueryWireTabs.js?v=105:13 Uncaught SyntaxError: Unexpected token ) I don't know what module is compressing the files in the admin so I can delete the cache of this file or see what's wrong. Edit : because of this the modules page is not working at all. I also tried in different browsers, deleted browser cache etc and no change. Edit 2: it has been fixed by itself, not sure why and how.
  3. Great responses so far, thank you! Diogo, I was more interested into comparing two or more specific products that user choose, not to get the bigest of all. I am concerned about the number of queries that are needed for this because I will need 100 fields x the number of products to compare. Are there ways to get all fields at the same time using a single database query (or do the api do exactly this)? I think I will set a maximum of 5 products to compare at a time (even 3 if there will be a performance hit), but I am still unsure how processwire works under the hood and if for 3 pages with 100 fields each it will query the db for each field or how it works (it gets all fields with one query or how) . Also is there any way to easily see what queries are run and how much memory they use (also the time needed) when using the api? If someone can explain those things a bit I think it will be easier to decide exactly which is the better way for my needs. Thanks
  4. Thank you for your reply. I didn't completly understood how profields works and how it whould help but will try to look some more at the videos. Another problem is that I can't buy the module now, I am getting this error always:[#30X117] Could not locate invoice. Tried to pay with both, CC and paypal, same error for both.
  5. Hi, I need to build a website where I will have different product details like size, color etc. The problem is that I am not sure what is the best way to do this because there will be arround 50 different fields needed for each product and I'm trying to get best of both worlds, to have a good backend (to be easy to complete all the fields by the editors), and to be good from the performance point of view. I think about some ways : 1. Regular fields, one for each thing ? The problem is that there will be at least 50 fields for each product and when I need them all it will probably have an impact on the performance, even more when I'll want to filter based on some values (like a specific color and a size smaller than X) 2. Page refferance ? As some of them will have just few options like the category the product is part of I am thinking I can do this for almost all fields (just not for the ones like size etc) 3. Repeater field ? The problem might be that it is hard for editors to complete both the "label" and the value for example and seems like repeater fields are for different things. 4. The pro fields table module ? Is this what it is meant for ? Did any of you had to build something similar ? How does processwire handle pages with more than 50 fields (or probably to be sure in future it might have more, something arround 100 fields), keeping in mind that there might be a total of 2000-3000 pages of products. Also I need almost all of them to be search-able and to be able to compare any 2 (or a bigger number) of products and show which one has a bigger size for example, so the values have to be somehow separated from the labels. Any idea is welcome. Thanks
  6. Thanks! It's a pleasure to work PW once you understand you are not forced to do things 'the CMS way'. Seems like this is the hardest part when coming from another cms.
  7. Oh now I see where the issue was. Thanks for pointing it out. Sorry for asking so stupid question, i'm still learning how processwire works
  8. Hi, I just started using processwire this week and I have some troubles with the api's. I'm trying to create multiple parent->children pages but it gets stuck at the 2nd child; I want to create those pages with the api's: Category --Subcategory ----Sub-Subcategory --------Some page --------Another page Here is a small part of code that I made to test and It doesn't seem to be possible right now, or am I doing something wrong ? $pgs = array("1","2","3","4","5"); foreach ($pgs as $key => $value) { if ($value == "1") { $parent = "/"; }else{ $v = $value - 1; $parent = "/test$v/"; } $p = new Page(); $p->of(false); $p->template = "basic-page"; $p->parent = wire("pages")->get("$parent"); $p->title = "test".$value; $p->save(); } Basically this should create 5 pages, with each page to be the child of the previous one. It gets stuck at the test2 page, for page3 it says Fatal error: Exception: Can't save page 0: /test3/: It has no parent assigned I think pages are not available right after they are created from api ? Is there any method to do this with processwire right now ? Thanks ! //Edit: I even tried this code to take out any possible issue with the code $p = new Page(); $p->of(false); $p->template = "basic-page"; $p->parent = wire("pages")->get("/"); $p->title = "test1"; $p->save(); $p = new Page(); $p->of(false); $p->template = "basic-page"; $p->parent = wire("pages")->get("/test1/"); $p->title = "test2"; $p->save(); $p = new Page(); $p->of(false); $p->template = "basic-page"; $p->parent = wire("pages")->get("/test2/"); $p->title = "test3"; $p->save(); $p = new Page(); $p->of(false); $p->template = "basic-page"; $p->parent = wire("pages")->get("/test3/"); $p->title = "test4"; $p->save(); So the pages are not available to the api after creating them ? How to get arround this ?
×
×
  • Create New...