Fields['fieldname']"."/> Fields['fieldname']".">

Home  >  Article  >  CMS Tutorial  >  How to call other field values ​​in the DreamWeaver runphp=yes tag

How to call other field values ​​in the DreamWeaver runphp=yes tag

藏色散人
藏色散人Original
2020-01-07 09:46:272324browse

How to call other field values ​​in the DreamWeaver runphp=yes tag

How to call other field values ​​in the runphp=yes tag?

Methods for calling other field values ​​in the DreamWeaver runphp=yes tag

Recommended learning:梦Weavercms

DreamWeaver’s tag You can execute php code through runphp=yes, but sometimes we need to call other field values ​​​​in a label's runphp=yes as a condition, so how to do it?

After searching online, the following method can be achieved:

Use global variables to solve

{dede:php}$GLOBALS['xxoo']=$refObj->Fields['fieldname']{/dede:php} 
{dede:field.xxxx runphp="yes"}@me="test".@me."-test".$GLOBALS['xxoo'];{/dede:field.xxxx}

That is, first open a PHP tag and replace the value you want to assign to global variables. Then assign the field value to him in another run.

The above is the detailed content of How to call other field values ​​in the DreamWeaver runphp=yes tag. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn