Skip Navigation

[Resolved] is it possible to use shortcode to add portfolio-type to a Page

This thread is resolved. Here is a description of the problem and solution.

Problem:

Display "portfolio-type" posts list in a WordPress page

Solution:

You can create a post view:

- Query portfolio-type posts

- display portfolio-type post information

Then insert the view shortcode [wpv-view] into your WordPress page

Relevant Documentation:

https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-view

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

This topic contains 8 replies, has 2 voices.

Last updated by BarryS9673 2 years, 4 months ago.

Assigned support staff: Luo Yang.

Author
Posts
#1253757

One more thing, is it possible to use shortcode to add portfolio-type to a Page?

#1253761

Luo Yang
Supporter

Languages: English (English ) Chinese (Simplified) (简体中文 )

Timezone: Asia/Hong_Kong (GMT+08:00)

Hello,

Please elaborate the question with more details.

I assume you are going to display "portfolio-type" posts list in a WordPress page.

You can create a post view:
- Query portfolio-type posts
- display portfolio-type post information

Then insert the view shortcode [wpv-view] into your WordPress page, see our documents:
https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-view

#1253863

Since that page does not work when I enable Oxygen, which is my page builder/theme, I am looking for another way to add types archive direct to a WP Page, I will try as you have suggested and then reply the outcome.

#1253865

I think I will call it a day on trying to create the page this way, it just seems like something that does not work and perhaps I should just do it the proper way.

I added this as shortcode and get the result below.

hidden link

#1253895

Luo Yang
Supporter

Languages: English (English ) Chinese (Simplified) (简体中文 )

Timezone: Asia/Hong_Kong (GMT+08:00)

The Views wordpress archive is for customizing WordPress archive page, there isn't shortcode for it.
See document:
https://toolset.com/documentation/user-guides/creating-wordpress-custom-post-archives/

I have tried the URL you mentioned above:
hidden link

I can see the view works in your website, but you will need to style/format the results with HTML/CSS codes according to your website settings.

And you can also add pagination to that post view by following our document:
https://toolset.com/documentation/user-guides/views-pagination/

#1253917

OK! So in your opinion, that is correct, I just need to get the styling to work, that I can do.

#1253943
Capture.JPG

If I can ask your advice, what do you make of that extra little square that seems to be appearing on the layout? I have added a border around the image, so this I can assume is some sort of hidden code.

hidden link

I can hide it with this, just wanted your opinion.
.tb-image-1 {display:none;}

#1253991

Luo Yang
Supporter

Languages: English (English ) Chinese (Simplified) (简体中文 )

Timezone: Asia/Hong_Kong (GMT+08:00)

That should be a problem in content template "Loop item in Portfolio Archive Page", you can find the extra image field and remove it.

See the solution in your previous thread:
https://toolset.com/forums/topic/my-blocks-are-not-looping/#post-1252845

I did not remove the image field you have done, jut added a new row below it, I suggest you find it and remove that row and image.

I have tried the credentials you provided in post:
https://toolset.com/forums/topic/my-blocks-are-not-looping/#post-1252805
It is not valid any more, I get this error message:
ERROR: invalid username

If you need more assistance for it, please make sure the credentials is valid, I can setup a demo for you.

#1254065

Thank you, sorry I removed access. I have fixed that additional image, thank you very much for your time and support