How to set the access path correctly when PHP is programmed in a wampserver environment

Source: Internet
Author: User
Tags php source code
Since the Wampserver upgrade to 2.2 (Apache 2.4.2; php 5.4.3; MySql 5.5.24) after running the previously written PHP program, always error, do not know how to solve, ask for your guidance. Thanks a lot. The problems encountered this time are:



The folder where the source code is located.
index.php saved in "www/artivisminventory/admin/";
function source global.inc.php and pic_functions.php saved in "www/artivisminventory/admin/includes/"
Class source such as UserTools.class.php and DB.class.php, etc. saved in "www/artivisminventory/admin/classes/"

Part index.php Source:

 
  Getpageid ($modul _name);? >Content Management System
 
  
 
  ········



Part global.inc.php Source code

 
  Connect ();//initialize usertools object$usertools = new Usertools ();? >



Part UserTools.class.php Source code

 
  


This group of programs, such as FTP to remote web host provided by a third party, works fine, but runs under local wampserver with the following error message:




Reply to discussion (solution)

Require_once '. /classes/user.class.php ';
The inclusion of the following classes is also changed to try this

Require_once '. /classes/user.class.php ';
The inclusion of the following classes is also changed to try this


This trial, the mistake becomes:

This diagram is a little clearer

I have also encountered this new version of this newspaper error, as if several functions were canceled in the latest release, after the change will be good
There is a reference to the variable when placed in the function () will also error, the first definition of a separate reference is OK

UserTools.class.php Source
UserTools.class.php

Isn't that obvious? Your program needs to turn on short tag support, while the PHP default configuration is off

Upstairs moderator Mighty. Thank you, knot stickers.

  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.