Please note that Form2Content is no longer being developed. All files from the latest version can be found on Github.

Form2Content Forum

Questions and answers for Form2Content, a Joomla CCK.
  1. Lars Renklint
  2. F2C field types
  3. Monday, 26 October 2015
  4.  Subscribe via email
Form2Content Lite version 5.5.0
Joomla! 3.4.4

Is it possible to use the F2C template parameters somewhere else, in some other module or article?

This is what I would like to do.
Create a F2C form with fields for "monday lunch", "tuesday lunch" etc
In a module or article use php to get the current day and if it's monday display "monday lunch" from the F2C article.
Responses (6)
Accepted Answer Pending Moderation
Hi Lars,

As is often the case, there is more than just one, single answer to your question :)

Is it possible to use the F2C template parameters somewhere else, in some other module or article?


Yes it is. Not just with F2C by itself, but by using Form2Content Anywhere, a content plugin I developed. As a content plugin, it can be used in regular Joomla! articles, Custom HTML modules that have the "Prepare Content" option set to "Yes" and any other extension that properly implements the required Content plugin events.

The plugin has not been published anywhere yet and has not been extensively tested. If you want I can send you a copy, but without any guarantees and no promises whatsoever. You can start by looking at some documentation I crafted in Google Docs. Then, if you are interested, drop me a line and I will send you a copy.

In a module or article use php to get the current day and if it's monday display "monday lunch" from the F2C article.


This is not possible out of the box. Neither with F2C itself, nor with the F2C Anywhere plugin. I see two possible solutions here:

  1. Use F2C Anywhere in combination with one or more extensions of NoNumber. The Advanced Module Manager is the first that comes to mind.
  2. Use F2C Anywhere in combination with the Obix Content Restriction plugin, another content plugin I created. It's even newer than F2C Anywhere and even less extensively tested. You can find some some premature and incomplete documentation on Google Docs. However, the problem is that the kind of filtering you need is not supported and not on the todo list. I guess I could implement it, but would have to come to some kind of commercial arrangement. Let me know if you are interested.


Kind regards,

Pieter-Jan de Vries
  1. more than a month ago
  2. F2C field types
  3. # 1
Accepted Answer Pending Moderation
Hi Pieter-Jan, that's great!

Reading your documentation it sounds exactly what I'm looking for,
especially the part about using an embedded template.

You provided a download link in the article, so I've installed F2C Anywhere and given it a try.
But I'm afraid I haven't been able to make it work yet.
The plugin is enabled.
Using syntax 1: {F2cAnywhere id=7|template=veckomatsedel.tpl/} in a joomla article
The id is the F2C article id and the template is located in /media/com_form2content/templates
But all that is shown in the article is the tag (which is why I've checked 5 times that I really have enabled the plugin).

Any thoughts? Or is this a bad place to discuss this plugin.
  1. more than a month ago
  2. F2C field types
  3. # 2
Accepted Answer Pending Moderation
Hi Lars,

It was not my intention to make the plugin available to the general public yet. Partly because I'm not at all prepared for the consequences that go along with it, like giving support etc. Not even sure if it is what I want. But I completely forgot about the download link in the documentation :) So here we are.

Plugins like this are tricky. The logic to recognize the plugin and it's parameters in the content, can be complex. It's very difficult to make that bullet proof. Because I developed the plugin primarily for myself. I hardly spent any time or effort on making it monkey proof, so to speak. This means the usage instructions must be read carefully and applied rigorously.

It appears that you did what it takes and at first glance I don't see any errors in the syntax you applied. So I can think of only two things:

  • The plugin is used in a Custom HTML module but the module's “Prepare Content” option is not set to “Yes”.
  • Side effects caused by a wysiwyg editor. It is not unusual that wysiwyg editors insert HTML tags without you knowing about it. If that happens anywhere in between the curly opening and closing brackets of the plugin invocation, it will cause these kind of problems.


Hope this helps.

Kind regards,

Pieter-Jan de Vries
  1. more than a month ago
  2. F2C field types
  3. # 3
Accepted Answer Pending Moderation
Hi again, I'm glad you wanted to publish it, even if I can fully understand your concerns about giving support.

You were right about the wysiwyg editor, that inserted a couple of tags.
After removing them now I instead get an Internal server error, which probably is better, because know I know it actually does something.

I'll read through the whole documentation and see if I can spot what's wrong.

Thanks again.

Lars
  1. more than a month ago
  2. F2C field types
  3. # 4
Accepted Answer Pending Moderation
Hmmm.... An internal server error could indicate a bug in the plugin code. Difficult for me to analyze and solve remotely. Maybe you can set debug mode for your site to maximum, reproduce the error and send me the error messages I hope it will produce.

Maybe it's better to continue this directly. You can send an e-mail with the debug results to This email address is being protected from spambots. You need JavaScript enabled to view it..

Regards,

Pieter-Jan
  1. more than a month ago
  2. F2C field types
  3. # 5
Accepted Answer Pending Moderation
For showing f2c content we are using modul Article EasySlideshow from Easy Software with special setting and selecting for F2C content (by element, content type or value).

We can show all different content types on one page -> etc look at the website TED.com

- we can show all video content type, articles content type, and other on one speaker home page
- we can show all content types by tag, speakers... on speakers home page (first 2 articles in left side and other on the bottom)

With Advanced Module manager together - that is amazing solution :)

Yes and we can show articles as slideshow or static articles (grupped or not)

Rudolf
Attachments (3)
  1. more than a month ago
  2. F2C field types
  3. # 6
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.