I've been using the PHP code text format on my Drupal website and I have been encountering a frustrating issue with the Lexicon Module. I bet the answer is dead obvious, but I haven't been able to figure it out.
After I write my PHP code in the appropriate text format (php code) in the Lexicon modules "optional introductory text field", I hit save, and everything displays as it should on the page (great!). Problem is when I go back to make changes, "Full HTML" is selected as the text format and the PHP code has been replaced with HTML. When I then choose PHP Code as the text format, I can see some of the code I wrote (not all) but it's commented out with HTML comments. I know that my PHP code has been converted and replace with HTML not only in the input field because if I hit save again, then there is no PHP script saved - just garbled HTML gets displayed on the page.
Does anyone know how to use the PHP text format and make sure their PHP code actually sticks around if the content type is revisited? The reason I need to put PHP code in this field is because I want to do a language check of the current user and display text in either English or French.