Keyword
Please note that official support for commercial extensions & templates is provided in the Subscriber Help Desk.
Support requests should ONLY be directed there and require an active subscription plan.
This forum board is to be used for archive purposes and knowledge exchange ONLY.

Undefined Variable in Template

  • Jon Ward
  • Jon Ward's Avatar Topic Author
  • Offline
  • New Member
More
6 years 1 month ago #136884 by Jon Ward
Jon Ward created the topic: Undefined Variable in Template
Hi, I receive the following error when I use intro images in articles. The images ARE NOT floated correctly.

Notice: Undefined variable: imgfloat in /home1/public_html/7dw2/templates/numuzik/html/nucontent/default.php on line 21.

Thanks,
Jon

Please Log in or Create an account to join the conversation.

More
6 years 1 month ago #136885 by Yiota Ziaggou
Yiota Ziaggou replied the topic: Undefined Variable in Template
Hello Jon,

Please embed the following code to nucontent/default.php and to nucontent/list.php right under
<?php if(isset($item->image) && $item->image): ?>

For the default.php
<?php $imgfloat = (empty($item->image->float_fulltext)) ? $item->params->get('float_fulltext') : $item->image->float_fulltext; ?>

For the list.php
<?php $imgfloat = (empty($item->image->float_intro)) ? $item->params->get('float_intro') : $item->image->float_intro; ?>

This addition will be included in the template's update. Thank you for your feedback.

Note to new users: Please remember to search the forum before posting a question!

Please Log in or Create an account to join the conversation.

  • Jon Ward
  • Jon Ward's Avatar Topic Author
  • Offline
  • New Member
More
6 years 1 month ago #136886 by Jon Ward
Jon Ward replied the topic: Undefined Variable in Template
OK - That worked.

Thanks,
Jon

Please Log in or Create an account to join the conversation.

  • Jon Ward
  • Jon Ward's Avatar Topic Author
  • Offline
  • New Member
More
6 years 1 month ago #136887 by Jon Ward
Jon Ward replied the topic: Undefined Variable in Template
Note that the float override when editing the article does not work. Only the global float set in article options works.

Jon

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum