Recently Browsing 0 members
No registered users viewing this page.
I was looking for a module that allows the execution of long-running tasks (working with tens of thousands of pages) and could not find a suitable solution.
It started with the import problem. I have lots of data in XML form (20k+ complex entries) that I want to import into ProcessWire.
XMLReader() works fine but it takes a very long time to import all data so a simple "upload + process data on page save" would not work.
So I've created a new module for this. Meet my first (well, third) PW module: Tasker.
It's a simple module that executes long tasks in the background (using Cron or LazyCron) and reports their status to the user using a JQuery progressbar.
Any suggestions are welcome. How do you solve similar problems?
E.g. which is the best way to delete large number of pages? (max_exec_time will expire so I check it before the delete() call.)
$children = $page->children('template='.$this->template.',include=all'); // creates lot of page objects, may not have time to delete all + ...->delete() OR $childIDs = $this->pages->findIDs('parent='.$page->id.',template='.$this->template.',include=all'); // will create page objects later + $pages->get(..id..)->delete() Be nice (I know you're always), I'm a PW-newbie, just started working with ProcessWire. I was developing sites with Drupal for a very long time but their non-existent module upgrade path finally has driven me away from it.
i'm new to processwire, please cut me some slack if the answer is already out there..
i am "processwiring" a non-cms page that i made, containing many repeating so called "station"-elements with fields such as date, location, miles, optional links, photo upload etc. they were listed and created via php and stored in an xml file until now:
<stations> <station> <date>17.8.2017</date> <location>Exil, Zurich</location> <miles>1234</miles> ... </station> <station> ... </station> </stations> i already created a working repeater field with the needed fields and successfully created the first two elements... but there are many more!
what is the easiest and quickest way to batch create new repeater fields with the node element content of my xml file?
otherwise i would just have to type the whole sh..t again which i am too damn lazy to do
thanks in advance
Hello for all,
these days finishing project what is combination of e-commerce and portal website. Problem is "Products" page-tree because content need to be divided inside 48 categories. Also the client gave me content divided in 68 categories, but at the end they accepted my proposal about reducing that number. But problem is that and with 48 categories in backend, "Products" page tree is very large, long list, and very hard for administration. On front-end mega-menu with labels (menu group headings) solved that problem for vistors. And, at the end, I decided to test variant with additional categories to group categories, and result is good (now it's easy for adminsitration to find what they want very easy).
Problem: now urls are longer, and in some parts (categories) not sure how that's can affect on SEO (eg. before: "products/showers/some-product", now: "products/showers-and-bathtubs/showers/some-product"). There are few more examples like that. And another thing is that urls are now longer (more characters, and deeper).
For better administration I added new level of categorisation - I think - that is not a way to go. What is your opinion or suggestion about that? Maybe different, custom admin template, with custom navigation, or some folders? or ...?
By Peter Knight
Had a question about trailing slashes and forcing one or other.
I've a site where most pages can be accessed with AND without a trailing slash
are both accessible and being indexed by Google. It's obviously bad for SEO but I can't seem to make PW respect one and redirect etc.
There is a setting in templates>template>URLs
I must be overlooking something as I have 'yes' selected and both URLs are still reachable with no redirect.
What do you guys do to counter this?
Hi all, I am new to PW and building up a website for a customer and have some problems with structuring my project:
On my main.php file I have a main-tag where I wan't to echo the region called 'content'. But the problem is that the markup inside this wrapper should be variable.Example: I have a page where all the news previews are outputed like in a normal news app--> no additional markup is needed. But on "home" I want to have different sections with content -->
<section> <div class="slider"> <!--here i want to have some filtered news articles--> </div> </section> <section> <div class="news"> <!--here i want to have some news articles but with another filter--> </div> </section>
How can I realise that? It has to be like that for responsive purposes.
Is it maybe possible to create and echo regions inside the "parent region"?
Cheers and thank you for your help