PHP文件调用的有关问题
Jun 13, 2016 pm 01:23 PM
PHP文件调用的问题
再不同目录下用到同一类文件,
思路一是建立快捷方式,Linux下有个link,windows下没办法解决。这个有谁有经验的告诉我下,网上查了下,这方面没什么进度。
思路二是通过include加载。我目前试了2种,一种是直接将整个文件内容加载,但是调用类的时候,报‘您所请求的方法不存在’,而如果写class,在里面直接写include,include报错(只能写在class外面或function里),问下怎么做好呢?
------解决方案--------------------
怎么都要改东西的,要不你就把php的系统的包含目录中添加你这个类文件,虽然这样不合理。

Hot Article

Hot tools Tags

Hot Article

Hot Article Tags

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

PHP 8.4 Installation and Upgrade guide for Ubuntu and Debian

How to update the latest version of Bybit Exchange? Will there be any impact if it is not updated?

deepseek web version entrance deepseek official website entrance

Pi Node Teaching: What is a Pi Node? How to install and set up Pi Node?

How To Set Up Visual Studio Code (VS Code) for PHP Development

How do you parse and process HTML/XML in PHP?

Coinsuper exchange software channel official website entrance
