Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6692393
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T05:51:46+00:00 2026-05-26T05:51:46+00:00

So, I have xampp. I tested this code on ZendServer, result the same. <?php

  • 0

So, I have xampp. I tested this code on ZendServer, result the same.

<?php
error_reporting(E_ALL);

define ("ABS_PATH", 'C:\xampp\htdocs\oopHotLine\\');

function __autoload($class_name) {
    echo 'gg';
    require_once (ABS_PATH.'classes\\'.$class_name.'.php');
}

$process=new Main('1');
?>

after php.exe -a index.php i have this:

Interactive mode enabled
Fatal error: Class 'Main' not found in C:\xampp\htdocs\oopHotLine\index.php on line 10
[Finished]

so, it doesn shows ‘gg’ output. If i manually do __autoload(‘Main’); – all OK. The same for the manual require_once or include. All permissions in windows folder set to full access. Php version – PHP Version => 5.3.8;

Please, help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T05:51:46+00:00Added an answer on May 26, 2026 at 5:51 am

    As DaveRandom pointed:

    Autoloading is not available if using PHP in CLI interactive mode.
    

    So, instead of using php.exe -a index.php, cut the -a off and try running the script with php.exe index.php instead.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this line in php.ini include_path = .;C:\xampp\htdocs\zend\library;C:\xampp\php\PEAR What exactly is the .
I a xampp setup for php. I have created a new repository at D:/xampp/htdocs/cart
We have various php projects developed on windows (xampp) that need to be deployed
I have a PHP script running on XAMPP in Windows XP that will open
after installing XAMPP on linux i have seen the folder htdocs belongs to nobody.
Here's what I have: <VirtualHost 127.0.0.1> DocumentRoot D:\XAMPP\xampp\htdocs\mysites\tupega.com ServerName tupega.tld <IfModule mod_rewrite.c> RewriteEngine on
I have XAMPP with PHP 5.2, but my new projects need PHP 5.3 How
I currently have PHP 5.3 in XAMPP. I need to run PHP 5.2 to
I have changed the php.ini file in the location (C:\xampp\apache\bin\php.ini) for Xampp and restart
I have XAMPP on my local machine and am able to run PHP scripts

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.