Skip to content

Commit 3879556

Browse files
committed
fix formatting
1 parent 5e7dce3 commit 3879556

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

docs/back-end/wordpress/wordpress.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ The [ACF documentation](https://www.advancedcustomfields.com/resources/getting-s
3131

3232
Timber provides a number of [functions](https://timber.github.io/docs/guides/functions/) that helps developers gain access to and manipulate data in ACF fields. In Timber, templates use the [Twig Template Engine](https://twig.symfony.com/) separate from PHP files, which helps organize and simplify code. The [Timber Starter Theme](https://timber.github.io/docs/getting-started/setup/#use-the-starter-theme) makes it easy for developers to build out templates for ACF Field Groups in Twig. Without Timber, fields are typically templated like this:
3333

34-
```
34+
```php
3535
<?php if( have_rows('event') ): ?>
3636
<ul>
3737
<?php while( have_rows('event') ): the_row(); ?>
@@ -42,9 +42,10 @@ Timber provides a number of [functions](https://timber.github.io/docs/guides/fun
4242
</ul>
4343
<?php endif; ?>
4444
```
45+
4546
Twig, through Timber, provides an object oriented approach with a suite of [filters](https://twig.symfony.com/doc/3.x/filters/index.html) and [functions](https://twig.symfony.com/doc/3.x/functions/index.html) for manipulating field data. Template code in Timber looks like this:
4647

47-
```
48+
```twig
4849
<h2>{{ post.title }}</h2>
4950
<div class="my-list">
5051
{% for item in post.meta('my_repeater') %}
@@ -56,13 +57,15 @@ Twig, through Timber, provides an object oriented approach with a suite of [filt
5657
{% endfor %}
5758
</div>
5859
```
60+
5961
### idfive Component Library
6062

6163
idfive marks up and styles components using the [idfive Component Libray](https://bitbucket.org/idfivellc/idfive-component-library)("ICL"). Typically in a project, the front end team members will build components in a copy of the ICL in the Timber starter theme directory, then build twig files for the markup and display of components made up ACF Field Groups, with the theme including CSS generated by the ICL in the main theme using the [wp_enqueue_style](https://developer.wordpress.org/reference/functions/wp_enqueue_style/) function.
6264

6365
## Alternate Tools and Methods
6466

6567
idfive may alternatively build out a site without Timber if Timber does not meet the client needs. In the past, idfive has used other tools such as:
68+
6669
- [Visual Composer](https://visualcomposer.com/)
6770
- [Divi Builder](https://www.elegantthemes.com/gallery/divi/)
6871
- [Elementor](https://elementor.com/)
@@ -82,15 +85,16 @@ idfive develops many sites, at least initially, on [Pantheon](https://pantheon.i
8285

8386
First, create a sandbox site on Pantheon. Once the site is created on Pantheon, you can initialize and download the site to your local machine using:
8487

85-
```
88+
```bash
8689
lando init
8790
```
8891

8992
This command will respond with a series of questions. Select the Pantheon recipe, log in with your Pantheon credentials. The repo will be downloaded and initilialize in the current directory. Once that is complete, cd into the new directory and type:
9093

91-
```
94+
```bash
9295
lando pull
9396
```
97+
9498
lando pull gives the option of pulling from any environment, code, database, and files. The init process only downloads the code. It is fine to skip pulling code at this point, but pulling the database and the fiels so that you have an exact match of the site on the server.
9599

96100
### A Few More Commands

0 commit comments

Comments
 (0)