Jump to content

Search the Community

Showing results for tags 'loop'.

  • Search By Tags

    • loop ×
    Type tags separated by commas.
  • Search By Author

Content Type



Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Found 16 results

  1. I want to split my output of an image array, see my code here: <div class="row"> <?php foreach($page->umf_imgs as $image) {echo "<div class='one-fourth column refs'><img src='$image->url'></div>";} ?> </div> <div class="row"> <?php foreach($page->umf_imgs as $image) {echo "<div class='one-...
  2. hi everyone I am trying get a full width sub-menu on 3rd item in menu or navbar which is coming from a loop. i was hoping this can be done by using jquery by targeting 3rd element in navbar but jquery is blocked in some browser by default so is there any other method I can do this
  3. I have a page field on my home template with output set to multiple pages (PageArray). I can echo its value, 1111|2222, or foreach $nav as $p echo $p, 11112222. But when I do this that I need to, it doesn't work: foreach ($mainnav as $p) { if($page->rootParent->id == $p->id) $current =...
  4. Hi. I have a setup that sends an email to all users that have subscribed to a category. When a post i published in a category, emails needs to be sent to all those users. For instance, I have 3 user subscribed, so 3 emails should be sent. However, 6 emails are sent and some of the emails are sent t...
  5. I just happened upon something that I think is curious, and I'm wondering if this is default behavior. So help me because I know nothing. While writing a module, i logged something in wire('log') inside the module's init() function. I was surprised to see that the text was being logged multiple...
  6. Hello guys. I am almost on the final line of building my second complete website with ProcessWire and got stuck a bit on the recipe nutrition presentation. I am not sure if I would be able to explain it promptly, but will do my best. So I have the code in my HTML template: So to fill up the v...
  7. My brain is probably just tiring out on me right this moment, I'm hoping that by the time I write out my problem I'll see the way through it. If you're reading this, it didn't work. Structure in question is: Series Page Product pages Page Fields for each product page...
  8. Hello all. Yesterday working on my Cooking Recipes profile I stumbled across an interesting issue - how to show pages published/created on a specific time interval without the use of any plugins but just the default API of PW. Thanks to @abdus the sollution was implemented and was working perfectly...
  9. Hello, I am just started playing around with processwire and it looks very nice. I am not a real developer (hopefully start this education next year). I am working on a template where I took some javascript from aother template. For the front page I have created a repeating field blok wich hold...
  10. Hello Real Beginner here. I am trying to loop the children of a product ( Keramik ) I have. They should look as an image with text underneath ( Example with bicycle tires ). I create for each product an own child page . I can't get my head around this... Thanks for all the help...
  11. I want to create a basic breadcrumb menu on my site and i'm using this code <?php $parents = $page->parents(); ?> <?php foreach( $parents as $item): ?> <span><a href='<?php echo $item->url; ?>'><?php echo $item->title; ?></a></span> <?php endforeach; ?> <span><?php echo $page->title; ?></span>...
  12. Hey I'm stuck with a issue how to filter repeater results depending on content. I have a few Option fields where you can select "yes", "no" or then leave it blank "". I got my loop working and I'm able to skip content that has not been set. Now I just need a filter for the loop. <? foreach($page...
  13. i am trying to create a product carousel in PW from last few days but can't figure out what i am doing wrong. here is HTML of carousel which is working fine. <div class="box producttabs"> <div class="tab-nav"> <ul id="producttabs304244223" class="nav nav-tabs"> <li class="active"><a data-toggle="...
  14. I am finishing up my first processwire site (yay), and this last bit is giving me a bit of a headache: For a news slider, I want to output x number of posts, with three posts per slide. (for a theoretically unlimited number of slides) I figure in theory this should work something like the code belo...
  15. Hi there, for some reason I do not succeed in doing a simple iteration (in this case with images): <?php $number_of_images = count($pages->get(1012)->images); foreach($pages->get(1012)->images as $image) { $thumbnail = $image->size(118,112); echo "<a href='{$image->u...
  16. Was just wondering how feasible/complicated it would be to display 3 blog entries, followed by 3 images which will be stored in the blog-index page, followed by the next 3 blog entries, then the next 3 images and so on and so-forth? I'm currently converting a static site (where this was obviously s...
×
×
  • Create New...