Possible to set user privileges on part of the text? In my node I have embeded a view using php snippet in body field. When regular user edits it I don't want him to accidently delete the snippet, is there a way to hide or lock that part of the text from that user so no matter what he does the snippet will remain there? Should I add a custom field just for it or are there a better options?
Also note, that the snipped could be placed in the middle of the body field content.

Thanks!
No, there are no ways to do this. And there shouldn't be. First of all, read PHP in database: bad practice but - this addresses exactly the situation you have here. Long story short: don't do it. Turn off PHP module if you don't need it.

And why you don't need it? Because there is Viewfield module.


  Viewfield provides a field that holds a reference to a View and renders it whenever the entity containing the field is displayed.


Exactly what you want to do, but without any snippets in user editable texts.