Content plugin loads broken form

softforge

Member
I have tried to load a form into an article and it breaks the HTML layout of the whole page. The form loads fine using a menu link.

Looking at the HTML output, I can see the problem. Here is the working version from the menu link:

HTML:
<img src="media/com_fabrik/images/notempty.png" class="fabrikTip" opts="{'position':'top'}" title="&lt;div&gt;&lt;ul class=&quot;validation-notices&quot; style=&quot;list-style:none&quot;&gt;&lt;li&gt;&lt;img src=&quot;media/com_fabrik/images/notempty.png&quot; class=&quot;notempty&quot; /&gt;This is a required field&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;" />
And here is the broken version loaded from the content plugin:

HTML:
<img src="media/com_fabrik/images/notempty.png" class="fabrikTip" opts="{'position':'top'}" title="<div><ul class="validation-notices" style="list-style:none"><li><img src="media/com_fabrik/images/notempty.png" class="notempty" />This is a required field</li></ul></div>" />
So the HTML within the title attribute is not being made safe and so is breaking the page rendering. I'm guessing this will be easy to solve.

Many thanks.
 
Sure, it is on the help diabetes site I have already sent you access details for.

This is the working version when loaded through a menu item:

/quizzes/my-medicine-quiz/test

And this is the version loaded through the content plugin:

/helping-myself-staying-healthy/taking-my-medicines/should-i-make-a-change/taking-my-medicine-quiz

This is the plugin code I'm using:

{fabrik view=form id=2 layout=labels-above}

Thanks for investigating :)
 
hi
Seems you had disabled the content plugin, and the credentials that worked for the htaccess access would not let me log in to the administration part of the site, could you double check those please?

thx
Rob
 
Hi, sorry, our content editor disabled the plugin because it was giving a 500 error on this page and she needed to edit it:

/helping-myself-staying-healthy/taking-my-medicines/should-i-make-a-change

I have re-enabled it and sure enough, it does give a 500 error with the message "Layout default not found" when logged out and "Layout labelsabove_row not found" when logged in.

The previous page I mentioned still has its problem. You can login with a super admin account with the username "fabrik" and the same password as the htaccess login.

Many thanks.
 
I have found a workaround for the 500 error for now so our content editor can carry on working but there is definitely something strange going on with finding the templates when you are not logged in, eg:

/power/session-1

I have carried on embedding forms using the content plugin in the places they need to go. There are now many examples of broken pages you can look at:

/power/session-1/1416-power-fooddiaryversion2
/power/session-1/1432-power-ifthenplans2-1

Also, code like {fabrik view=form id=2 layout=labels-above} does not seem to be loading the form, but rather the details view like the following. How do I get the form to load instead?

/helping-myself-staying-healthy/taking-my-medicines/should-i-make-a-change/taking-my-medicine-quiz
/power/session-1/2502-power-progresschart-lbs-kg

The super admin account has the username "fabrik" with the same password as the htaccess.

Many thanks
 
/power/session-1
I searched high and low for this - but couldn't find it, neither as a menu item name or a content article. Can you give me a clue as to how I can access this in the admin? e.g. what menu is it under and what menu id, etc.

/power/session-1/1416-power-fooddiaryversion2
/power/session-1/1432-power-ifthenplans2-1
I don't see any fabrik placeholder text, just this:

{article power_template_ifthenplans2_1}{text}{/article}

No idea what that is or what its meant to do!

I have a feeling you are doing more that described in the post so far?
 
Sorry, I forgot that we were loading an article within an article using a nonumbers plugin which loads it via the alias. This is because that same article needs to be used in other places and we don't want to have multiple versions of the same article.

I have moved the Fabrik code out of the template articles and directly into the power articles and the problem still occurs. If you have a look now, you will be able to see the Fabrik placeholder code.

Many thanks
 
Sorry about the delay, I'm busy playing catch-up from my 3 weeks in Europe. Thank you for your patience.

I'll have a look at this now.

-- hugh
 
Can you try this ...

In ./components/com_fabrik/models/element.php, around like 1332 is this code:

PHP:
					$validationHovers = array('<div><ul class="validation-notices" style="list-style:none">');

Try changing that to:

PHP:
					$validationHovers = array("<div><ul class='validation-notices' style='list-style:none'>");

-- hugh
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top