# Exported blocks not visible in WordPress (solved)

**URL:** <https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750>\
**Category:** Bug Reports\
**Tags:** bug, blocks\
**Created:** [August 2, 2022, 6:33pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750 "2022-08-02T18:33:14Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 2, 2022, 6:33pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/1 "2022-08-02T18:33:14Z")

</div>

I’m new to Pinegrow. Overall…I find it amazing. Having said that I also find it a bit buggy. Most of the work I’m doing is with Wordpress and Tailwind CSS. To learn Pinegrow, I did the recent Flex tutorial…which is wonderful. But I’ve found bugs along the way. I decided I should start posting them.

First one: Pinegrow inconsistently registers the Blocks. They show up in the Blocks folder, with the register php file, but don’t show up in Wordpress. I’ve traced this to functions.php. It seems to be hit or miss whether Pinegrow adds the new block to functions.php. Manually adding the include, doesn’t fix it. When you reload in Pinegrow it reverts to the original functions.php (have had this same issue with a custom header.php always being overwritten. - but guess that is issue #2 😉

I’ve tried clearing the cache in both Pinegrow and the browser, but it doesn’t work. I believe the answer IS having it registered in functions.php…but because Pinegrow keeps deleting any customization to functions.php. it does not resolve the issue.

---

<div class="post-metadata">

**Author:** ![adamslowe](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/adamslowe/32/4590_2.png) [@adamslowe](https://forum.pinegrow.com/u/adamslowe)\
**Post date:** [August 2, 2022, 6:36pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/2 "2022-08-02T18:36:50Z")

</div>

@iHuman Most of my work is also with blocks and Tailwind and I haven’t run into either of those issues. Can you post a loom video (or similar) and/or a sample of your project showing us what is happening?

---

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 2, 2022, 6:43pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/3 "2022-08-02T18:43:02Z")

</div>

It would be really complex to do a video of…  
I am wondering if some of the bugginess I’m experiencing with Pinegrow is related to working on an M1 processor?

I’ve done a lot of Tailwind CSS with php manually (Sublime)…without issues. So I’m fairly confident in my coding skills.

Here’s the issue:

1. create a block
2. save all
3. export theme
4. block appears in block folder under correct name, with all component files.
5. hit or miss whether block appears in \_pgexport folder
6. functions.php shows the require file in the block init
7. functions.php in \_pgexport does not.

So in summary, for whatever reason…the two don’t seem to sync. The frustrating part is that it is inconsistent. I created four blocks that worked like a charm. The last one…just won’t work. Have deleted and retried, but no luck. I even thought it was a naming issue - deleting a block and creating a new one with the same name. If so, seems that clearing the cache would resolve that.

---

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 2, 2022, 6:45pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/4 "2022-08-02T18:45:24Z")

</div>

Also…if I manually register the block in functions.php - it DOES show up in Wordpress…but with the error that the site doesn’t support it. Catch 22…

---

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 2, 2022, 6:53pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/5 "2022-08-02T18:53:57Z")

</div>

Decided to try deleting the block and rebuild it…this time watching the blocks folder to see what happens. It seems to me…if you delete a block in Pinegrow, when you save all, it should delete the old block in both Blocks folder locations. It doesn’t.

---

<div class="post-metadata">

**Author:** ![Wolfgang.Hartl](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/wolfgang.hartl/32/4621_2.png) [@Wolfgang.Hartl](https://forum.pinegrow.com/u/Wolfgang.Hartl)\
**Post date:** [August 2, 2022, 6:56pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/6 "2022-08-02T18:56:36Z")

</div>

Didn’t do much with themes yet. I’m doing a plugin right now with a lot of custom blocks and everything works like a charm. Also on a M1 Mac here, so that can’t be a problem in my opinion!

Cheers!

---

<div class="post-metadata">

**Author:** ![matjaz](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/matjaz/32/5_2.png) [@matjaz](https://forum.pinegrow.com/u/matjaz)\
**Post date:** [August 2, 2022, 7:00pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/7 "2022-08-02T19:00:59Z")

</div>

@iHuman thanks for posting details of the issue and helping with troubleshooting.

> [@iHuman](#):
>
> Decided to try deleting the block and rebuild it…this time watching the blocks folder to see what happens. It seems to me…if you delete a block in Pinegrow, when you save all, it should delete the old block in both Blocks folder locations. It doesn’t.

PG doesn’t delete any files in the export folder, as a safety precaution. Would not want to delete any manual customization. In such cases it is recommended to do “WordPress → Clear the export folder” to delete the folder and then do Theme export.

M1 should play no role here, I’m using it as well. The problem seems to be related with exporting the functions.php.

---

<div class="post-metadata">

**Author:** ![adamslowe](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/adamslowe/32/4590_2.png) [@adamslowe](https://forum.pinegrow.com/u/adamslowe)\
**Post date:** [August 2, 2022, 7:20pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/8 "2022-08-02T19:20:47Z")

</div>

@iHuman I just set up a sample project and ran through the steps you outlined. Everything is working as expected. (I’m also on an M1 Mac). Here is a Loom video of the start to finish process.

[  
iHuman Pinegrow Test - Watch Video  
  ![](https://cdn.loom.com/sessions/thumbnails/5ce9db019d4e40baaaeba5cbc558bddb-with-play.gif)](https://www.loom.com/share/5ce9db019d4e40baaaeba5cbc558bddb)

Maybe you can link to a copy of your project so we can take a better look?

---

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 2, 2022, 8:25pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/9 "2022-08-02T20:25:18Z")

</div>

“WordPress → Clear theme folder” ? I don’t see an option for “WordPress → Clear the export folder”

---

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 2, 2022, 8:30pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/10 "2022-08-02T20:30:01Z")

</div>

I should have noted… this is specifically an issue with interactions. The other blocks that worked like a charm - did not have interactions activated. This is block is a slider.

---

<div class="post-metadata">

**Author:** ![adamslowe](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/adamslowe/32/4590_2.png) [@adamslowe](https://forum.pinegrow.com/u/adamslowe)\
**Post date:** [August 2, 2022, 8:54pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/11 "2022-08-02T20:54:11Z")

</div>

@iHuman Okay, I seem to be able to reproduce your issue. Here is a video of what I did to reproduce it and the troubleshooting steps I took.

@matjaz This does appear to be a real bug.

Steps to reproduce:

1. Export theme with a block.
2. Delete the block you exported
3. Recreate the block you exported with the same name
4. Note that the newly recreated block is not exported
5. Rename the recreated block
6. Note that the previously deleted, recreated, and renamed block is still not exported.

I tried all the usual stuff… clearing cache, regenerating functions.php, clearing and recreating the export folder. Nothing seemed to make the theme exporter pick up on that block.

Other things I’ve tried/checked/noted

- The “bad” block now shows up as part of the template even though it’s marked as a block in PG.
- I can successfully create NEW blocks after making a “bad” block, as long as I don’t re-use any old unique Block IDs.
- Renaming the cms-block-title has no effect
- Renaming the WordPress Block Title has no effect
- Closing & reopening Pinegrow has no effect
- Deleting my Pinegrow application support folder has no effect

Workaround:  
Be careful not to re-use any block IDs, regardless of whether or not they have been deleted. If you are experiencing this problem, delete the offending blocks and sections and re-create them with a unique block ID.

[  
iHuman Pinegrow Test - Part 2 - Watch Video  
  ![](https://cdn.loom.com/sessions/thumbnails/43c7ecb38fe44328ba467738080346b7-with-play.gif)](https://www.loom.com/share/43c7ecb38fe44328ba467738080346b7)

And here is a repository with my test project

> **[GitHub - adamslowe/iHuman-test](https://github.com/adamslowe/iHuman-test)**
>
> Contribute to adamslowe/iHuman-test development by creating an account on GitHub.

---

<div class="post-metadata">

**Author:** ![matjaz](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/matjaz/32/5_2.png) [@matjaz](https://forum.pinegrow.com/u/matjaz)\
**Post date:** [August 3, 2022, 12:38pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/12 "2022-08-03T12:38:38Z")

</div>

@adamslowe great debugging skill, thank you for this!

I managed to discover and fix the issue, the fix will be soon out with PG Live.

For now, **a workaround is to check if Block type setting on the Block action is set correctly.**

**More about the issue**

In the following workflow, the Block type gets incorrectly set to “[Object object]”:

1. Add an component from the Page Library to the page (such as the Slider blueprint)
2. Add Block action to the element
3. Export the theme
4. Add another slider from the Page Library to the page
5. Add Block action to that element. Block type gets corrupted.

In addition, the Register Pinegrow Blocks section didn’t get cleared if there were no blocks in the project. This is fixed as well.

@adamslowe, @iHuman & @Wolfgang.Hartl keep posting your reports of any issues you encounter, they are super helpful!

---

<div class="post-metadata">

**Author:** ![adamslowe](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/adamslowe/32/4590_2.png) [@adamslowe](https://forum.pinegrow.com/u/adamslowe)\
**Post date:** [August 3, 2022, 12:44pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/13 "2022-08-03T12:44:06Z")

</div>

Thank you so much for the quick update!

Since it isn’t obvious where to download Pinegrow Live, here is a link:

> **[Pinegrow Live | Pinegrow Web Editor](https://pinegrow.com/download/pinegrow-live/)**
>
> Pinegrow Live is a special Pinegrow Web Editor installation that loads most of its code from our servers and thus contains the latest (not yet released) features and bug fixes.

---

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 3, 2022, 1:49pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/14 "2022-08-03T13:49:06Z")

</div>

Great work @adamslowe ! That pretty much sums it up exactly!

From a software dev viewpoint, it makes sense the chain of events would be user delete block → app removes specific block folder from parent block folder (all of its files) → app removes from functions.php …and if there is a dB that tracks the unique ID, run a DELETE from for the specific ID. Might be part of projectdb.pgml.

---

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 3, 2022, 1:52pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/15 "2022-08-03T13:52:49Z")

</div>

That’s doesn’t appear on my version (6.7) Are you using a beta version @adamslowe ?  
 ![update](https://canada1.discourse-cdn.com/flex036/uploads/pinegrow/original/2X/2/2de490efbb6964664ea1c2f8d963e6b793d87aac.png)

---

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 3, 2022, 1:55pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/16 "2022-08-03T13:55:01Z")

</div>

I see now…it’s a latest builds version. Downloading now!

---

<div class="post-metadata">

**Author:** ![adamslowe](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/adamslowe/32/4590_2.png) [@adamslowe](https://forum.pinegrow.com/u/adamslowe)\
**Post date:** [August 3, 2022, 2:02pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/17 "2022-08-03T14:02:16Z")

</div>

The production releases have the question mark and the coffee cup. Pinegrow Live, which is the bleeding edge version, replaces the coffee cup with a radio signal icon.

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/pinegrow/original/2X/d/dda0e247727d56f051d56064e147f713ba740b41.jpeg)

---

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 3, 2022, 2:06pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/18 "2022-08-03T14:06:02Z")

</div>

Just installed the Live version. Looks like theme settings don’t work in that version.

Also… @matjaz why do custom header.php files always get overwritten in Pinegrow?

---

<div class="post-metadata">

**Author:** ![matjaz](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/matjaz/32/5_2.png) [@matjaz](https://forum.pinegrow.com/u/matjaz)\
**Post date:** [August 3, 2022, 2:29pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/19 "2022-08-03T14:29:59Z")

</div>

> [@iHuman](#):
>
> Looks like theme settings don’t work in that version.

It should work in PG Live. What happens?

> [@iHuman](#):
>
> why do custom header.php files always get overwritten in Pinegrow?

At the moment, that’s how PG works. header.php is always generated, even if header.php exists in the source project. One solution would be for PG not to generate PHP files that already exist in the source project.

But let’s step back first. Why do you need custom header.php as opposed to adding custom code in the master page so that PG would export the correct functionality?

---

<div class="post-metadata">

**Author:** ![iHuman](https://avatars.discourse-cdn.com/v4/letter/i/b38774/32.png) [@iHuman](https://forum.pinegrow.com/u/iHuman)\
**Post date:** [August 3, 2022, 5:46pm UTC](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750/20 "2022-08-03T17:46:09Z")

</div>

**theme settings in live**  
what happens? No matter what you set the theme on it stays on the default dark.

**custom header.php**  
I used custom headers quite often. For example, I do an include header-meta - where I can add the specific metadata, twitter card, og, etc for a client. Definitely would like the option to not have header.php not overwritten…without having to disable it for all files.

Suggetion: Why not do something like a gitignore? We could set which files we don’t want Pinegrow to auto generate. Or add it as an option similar to do not export. add do not auto generate.

[Next page](https://forum.pinegrow.com/t/exported-blocks-not-visible-in-wordpress-solved/6750.md?page=2)
