Controller代码: Demo2Controller.class.php <?php namespace Home\Controller; use Think\Controller; use Think\Model; class Demo2Controller extends Controller { //insert 操作 public function test1(){ $Model = new Model(); $sql = "insert into city(cityname
一.跨控制器调用 UserController.class.php <?php namespace Home/Controller use Think/Controller class UserController extends Controller{ public function show(){ //TODO } } IndexController.class.php(方法一) <?php namespace Home/Controller use Think/Controller cl
C# 将字符串或表达式直接转为可执行代码的办法 反射类 using System; using System.Data; using System.Configuration; using System.Text; using System.CodeDom.Compiler; using Microsoft.CSharp; using System.Reflection; namespace SSEC.Math { /// <summary> /// 本类用来将字符串转为可执行文本并执行 //