You are here: Re: include problem. « PHP Programming Language « IT news, forums, messages
Re: include problem.

Posted by Noodle on 04/01/07 09:36

On Apr 1, 6:49 pm, cmk...@hotmail.com wrote:
> Hi
> I have this file in submain:
> <?
> $a='a';
> ?>
>
> In another domain, when i do:
> <?
> require('sub.domain.com/a.php');
> echo $a;
> ?>
>
> But the echo $a print our nothing, i understand the problem, but how
> to work arround?
> thanks
> from Peter (cmk...@hotmail.com)

Try this:

Sub domain page:
<?php
$a = 'a';

echo $a;
?>

Another domain:
<?
$a = file_get_contents('sub.domain.com/a.php');
echo $a;
?>

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация