Displaying the content of two or more articles
Displaying the content of two or more articles
Currently phpWCMS allows you to display one article or a listing of two or more articles. Is it possible to display the entirety of two or more articles?
- Oliver Georgi
- Site Admin
- Posts: 9905
- Joined: Fri 3. Oct 2003, 22:22
- Contact:
Re: Displaying the content of two or more articles
It depends on how you build your system and how you define "article".
It's possible to load full articles like for one-pagers using Ajax or frontend render which based on special comments in the template.
Try inside your template:
Then call one page in the browser:
With this in mind it's relatively easy.
I have projects where such elements are loaded and cached.
It's possible to load full articles like for one-pagers using Ajax or frontend render which based on special comments in the template.
Try inside your template:
Code: Select all
<!--ONEPAGE_START//-->
{CONTENT}
<!--ONEPAGE_END//-->
index.php?mypagealias&phpwcms_output_action=F-trim--S-ONEPAGE
With this in mind it's relatively easy.
I have projects where such elements are loaded and cached.
Re: Displaying the content of two or more articles
I mean the ability to display all articles with the content in the category:
https://wiki.phpwcms.org/lib/exe/detail ... %3Aarticle
I am looking for a simple option to create a one-page page with a menu for articles.
https://wiki.phpwcms.org/lib/exe/detail ... %3Aarticle
I am looking for a simple option to create a one-page page with a menu for articles.
- Oliver Georgi
- Site Admin
- Posts: 9905
- Joined: Fri 3. Oct 2003, 22:22
- Contact:
Re: Displaying the content of two or more articles
I understand what you mean, and as described above this is how it can work.
There is no built-in mechanism to catch multiple articles in once. You need to write a wrapper to fulfill this.
Check the onepager checkbox under structure level and see what happens to the menu links.
Check this https://www.dr-plank-kelheim.de/ it's built on the above concept.
There is no built-in mechanism to catch multiple articles in once. You need to write a wrapper to fulfill this.
Check the onepager checkbox under structure level and see what happens to the menu links.
Check this https://www.dr-plank-kelheim.de/ it's built on the above concept.
Re: Displaying the content of two or more articles
I checked:
"OnePage ID (#anchor) support " in the "site structure"
and
"treat as OnePage template" in the template
but no work.
/localhost/test/index.php?home&phpwcms_output_action=F-trim--S-ONEPAGE
shows only one article.
Maybe I'm doing something wrong
"OnePage ID (#anchor) support " in the "site structure"
and
"treat as OnePage template" in the template
but no work.
/localhost/test/index.php?home&phpwcms_output_action=F-trim--S-ONEPAGE
shows only one article.
Maybe I'm doing something wrong
- Oliver Georgi
- Site Admin
- Posts: 9905
- Joined: Fri 3. Oct 2003, 22:22
- Contact:
Re: Displaying the content of two or more articles
This is a bit more complex. You just need to take the code I posted above and place it in a template to understand the concept behind – accessing then a page extended by parameters
Menu and everything else is based on your site structure and what you really wan to do. I have no time to explain it in detail here.
phpwcms_output_action=F-trim--S-ONEPAGE
.Menu and everything else is based on your site structure and what you really wan to do. I have no time to explain it in detail here.