Jump to content

Break in Smarty


mbavio

Recommended Posts

Hello, guys, I´m trying to implement the php function break in my smarty code, to go out of a {foreach}

 

With old version of WHMCS, I managed to do it using a compile plugin, so I locate a file in libs/plugins with the following content:

 

<?php

// compiler.break.php

function smarty_compiler_break($contents, &$smarty)

{

return 'break;';

}

 

So I was able to use {break} in my code.

 

 

But this is not working in the new version of WHMCS, which should be caused by an upgrading of smarty version.

 

So, my questions are:

 

1. What version of Smarty are we using for the new WHMCS version?

2. How do I fix the problem and continue using {break} within my code?

 

 

Thanks you very much!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated