Thread: Custom Hooks
View Single Post
  #5  
Old 29 Nov 2006, 07:15
timetunnel timetunnel is offline
 
Join Date: Sep 2005
Question

Hello.

What does this mean:

Fatal error: Cannot break/continue 1 level...


I've added a custom hook. It's located in a 'foreach' statement.

All I did was move a chunk of code that tested fine to a new plugin and added a custom hook location in its place. I used a custom 'Product' instead of vBulletin. That chunk of code started off with a conditional statement that pertained to a usergroup permission. For the usergroup that didn't meet the condition, that error message mentioned above appeared. The usergroup that met the condition had no error. This error did not exist before the custom hook-to-code replacement.

Any ideas? I love this thread's instructions.

Thanks in advance.


Edit: The answer is found at: http://www.vbulletin.com/forum/showthread.php?t=168513

It basically says that hooks can't be added to 'foreach'...
That thread does make a suggestion, though.

Last edited by timetunnel : 29 Nov 2006 at 20:16. Reason: UPDATE
Reply With Quote