Skip to content

Commit c605f7e

Browse files
authored
Update README.md
1 parent 7012a72 commit c605f7e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -370,6 +370,11 @@ $orders = Order::options(['status' => 'processing', 'orderby' => 'id', 'order' =
370370
371371
// You can set options by passing an array when call `all` method
372372
$orders = Order::all(['status' => 'processing', 'orderby' => 'id', 'order' => 'asc']);
373+
374+
// Data with pagination
375+
$products = Product::paginate(25, 1); // first parameter means how much you want to display per_page, second parameter current page
376+
Or
377+
$products = (new Product)->paginate(25, 5); // first parameter means how much data you want to display per_page, second parameter current page
373378
```
374379
#Product Options: https://woocommerce.github.io/woocommerce-rest-api-docs/#products
375380

0 commit comments

Comments
 (0)