-1

According How do I use PHP in "Rewrite results" for a field in a view? with the Views Custom Field module you can use PHP code in the rewriting section. I installed the module, but it consider my custom PHP code HTML (I use <?php ?>).

Where is the problem, and what is my mistake?

1
  • Showing the code you are using would probably help in answering your question, especially if there is an error in your code. Differently, how can we know what your mistake is (if you made any mistake)? – kiamlaluno Aug 23 '12 at 14:35
1

You should tell which version of Drupal you're using.

Also, consider that embeding PHP via the UI is considered bad practice, for very good reasons.

You'd better use a field template for your field. This comment explains the basics for doing this.

5
  • i use drupal 6.25. i don't want use themplate, unless i have to use it at last. i found views_php module for handle some of my requests. – Yuseferi Jun 9 '12 at 9:47
  • Do as you see fit, of course. For the record, here is the link to the module. – Countzero Jun 9 '12 at 11:17
  • i use it, but have problem with sort section of it, how can i add sortable feature to my field?(i have integer field and i select numerical sorting but nothing happen) – Yuseferi Jun 9 '12 at 11:57
  • It seems to be a serious issue as there are many threads in the module queue about it. – Countzero Jun 11 '12 at 6:10
  • i saw them, resolve my probem with use views_php module and some change in my ideas about project – Yuseferi Jun 11 '12 at 7:28

Not the answer you're looking for? Browse other questions tagged or ask your own question.