473,394 Members | 1,724 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Very Simple Problem in include

Hi All-
(complete beginner in PHP, using example code written by Rasmus from
Cool Toys blog)

I have copied a script into a working directory (unix), it includes
another script (verbatum from Rasmus).
Q. Why is the included script called xxx.phps instead of xxx.php?

In the original, Rasmus placed his included script in the PHP lib
directory. I placed it in my working directory instead, changing the
include path.
The included script IS FOUND. But when the included script is called
in, the first line is a call to apc_fetch(), and PHP complains 'Call to
undefined function apc_fetch()'. Something is obviously broken.

I don't know enough basics to spot the construct error. Anyone?

==
included file - unchanged, but a local copy in my working dir
== http://lerdorf.com/php/simple_rss.phps

==
script under construction
== mapTest.php

<html><head>
<script type="text/javascript" src="http://api.maps.yahoo.com/v2.0/fl/javascript/apiloader.js"></script>
<style type="text/css">
#mapContainer {
height: 600px;
width: 800px;
}
</style>
<?php
include './simple_rss.phps';

$url = 'http://aSite.com/map_testQ/myTest.xml';
$feed = rss_request($url, $timeout=3600);

echo <<<EOB
<title>FAKE</title>
</head><body>
<h1>header</h1>
<p><font size="+2">Name<br />
subject</font></p>
EOB;

echo 'feed=';
echo $feed;
?>

<div id="mapContainer"></div>
</body></html>
Dec 20 '05 #1
2 6393
Hi One Man,
I guess that "Call to undefined function apc_fetch()" its due to the
following reasson.

APC is a PECL Extension
Rasmus has used in the simple_rss.php

Try Getting the package and install
for more info on apc Extension
http://pecl.php.net/package/APC

and surf thru this site , u will know more info on how to install and
more...

Prince of Code

Dec 20 '05 #2
In article <11**********************@g47g2000cwa.googlegroups .com>,
"Prince of Code" <pr**********@gmail.com> wrote:
APC is a PECL Extension
....
http://pecl.php.net/package/APC

aha. My sysadmin will have to authorize this, methinks. Also, are
there any _other_ extensions I will need ot use this. DOM stuff or
whatever. Its all greek to me (so far)

thanks much
Dec 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

20
by: Sam | last post by:
Hi I'm learning to code with C++ and wrote some very simple code. I think it's consistent with every rule but always got compiling errors that I don't understand. The code include 5 files as...
3
by: Winston Smith | last post by:
Hi, I have question about compiling multiple source files with templates using gcc. It's probably obvious but I'm new to C++. I've tried to isolate my problem and it came down to this. Lets...
4
by: Jürgen Devlieghere | last post by:
We encounter a crash every now and then at a client, and now I'm starting to doubt the fundamentals of life :-) We have a list of structs. struct SContactProperty { public:...
14
by: Peter | last post by:
#include <stdio.h> #include <stdlib.h> #include <string.h> int main(void) { char input_string; printf("Please enter conversion: "); scanf("%s", input_string);
7
by: Aris | last post by:
Hi all! this is the code: #include <iostream.h> #include <stdlib.h> #include <stdio.h> #include <string.h> void MyFunction(char *B) { cout<<sizeof(B)<<endl; //(1)
22
by: tricard | last post by:
Good evening, I was thinking about making a very simple DOS based (console) menu for a project that i am working on, but I have no idea where to start for something like this. Does anyone have...
7
by: pedagani | last post by:
Dear comp.lang.c++, I'm trying to read a file with very long filename using ifstream. Although, the file exists the file open for read fails. Is there a restriction on the size? I'm using winXP...
5
by: Michael | last post by:
Hi All, I have three very simple files as below. When I try and compile these with g++ -ansi -Wall -pedantic -o crap Base.h Other.h I get an error: Base.h:7: internal compiler error:...
11
by: VijaKhara | last post by:
Hi all, I just write a very simple codes in C and vthere is a very strange bug which I cannot figure out why. The first loop is for v, and the second for k. There is no relationship between v...
10
by: Chris Thomasson | last post by:
Here is the example code: - http://appcore.home.comcast.net/vzoom/example/interface.zip which is an analog of the following technique: -...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.