Re: [PHP] Parse error help.., thanks..

2007-03-30 Thread Ian
Thanks very much for the help, Davi,, no more such errors.. :)

Ian
"Davi" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]
Em Sexta 30 Março 2007 18:55, Ian escreveu:
> Parse error: syntax error, unexpected ';' in
> /hxxx/x/domains/x.com/public_html/blog/labels.php on line 15
>
> 
 http://.x.com/labels');
2
define('SEARCH_DIR','//x/domains/x.com/public_html/blog/labels');
3 define('THIS_FILE', 'cloud.php');
4 if(file_exists(SEARCH_DIR.'_cloud_include_cache.html') &&
5 filemtime(SEARCH_DIR.'_cloud_include_cache.html')>(time()-(60*60)))
6 echo file_get_contents(SEARCH_DIR.'_cloud_include_cache.html');
7 else
8 {
9 $output = '';
10 $files = array();
11 $dir = opendir(SEARCH_DIR);
12 while($file = readdir($dir))
13 if($file != '.' && $file != '..' && $file != THIS_FILE
14 
&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;am
15 p;amp;amp;& $file != CACHE_FILE)
16 {
17 $files[] = $file;
18 }

Try remove the "&"s...

[]s


-- 
Davi Vidal
[EMAIL PROTECTED]
[EMAIL PROTECTED]
--

Agora com fortune:
"Toothpaste never hurts the taste of good scotch." 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Parse error help.., thanks..

2007-03-30 Thread Ian
Hehe.., didn't i told i am poor in this, actually, never learn PHP before.. 
:)

No more such errors anymore thank you Tijnema! =)

Ian
""Tijnema !"" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]
> On 3/30/07, Ian <[EMAIL PROTECTED]> wrote:
>> Hi everyone, i am new to PHP, but not a programmer..,
>> i got this php code to workout on something on my blog, but it seems that 
>> it
>> gives me the following error:
>>
>> Parse error: syntax error, unexpected ';' in
>> /hxxx/x/domains/x.com/public_html/blog/labels.php on line 15
>>
>> 
>> > define('PREFIX', 'http://.x.com/labels');
>> define('SEARCH_DIR','//x/domains/x.com/public_html/blog/labels');
>> define('THIS_FILE', 'cloud.php');
>> if(file_exists(SEARCH_DIR.'_cloud_include_cache.html') &&
>> filemtime(SEARCH_DIR.'_cloud_include_cache.html')>(time()-(60*60)))
>> echo file_get_contents(SEARCH_DIR.'_cloud_include_cache.html');
>> else
>> {
>> $output = '';
>> $files = array();
>> $dir = opendir(SEARCH_DIR);
>> while($file = readdir($dir))
>> if($file != '.' && $file != '..' && $file != THIS_FILE
>> &amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;&
>
> How can above string be ever correct
>> $file != CACHE_FILE)
>> {
>> $files[] = $file;
>> }
>>
>> 
>> Anyhelp on this will ve be very much appreciated, thanks..
>>
>> Ian
> Try this code:
> 
>  define('PREFIX', 'http://.x.com/labels');
> define('SEARCH_DIR','//x/domains/x.com/public_html/blog/labels');
> define('THIS_FILE', 'cloud.php');
> if(file_exists(SEARCH_DIR.'_cloud_include_cache.html') &&
> filemtime(SEARCH_DIR.'_cloud_include_cache.html')>(time()-(60*60)))
> echo file_get_contents(SEARCH_DIR.'_cloud_include_cache.html');
> else
> {
> $output = '';
> $files = array();
> $dir = opendir(SEARCH_DIR);
> while($file = readdir($dir))
> if($file != '.' && $file != '..' && $file != THIS_FILE && $file != 
> CACHE_FILE)
> {
> $files[] = $file;
> }
>
> It should work, if not, come back here :)
>
> Tijnema
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>> 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Parse error help.., thanks..

2007-03-30 Thread Tijnema !

On 3/30/07, Ian <[EMAIL PROTECTED]> wrote:

Hi everyone, i am new to PHP, but not a programmer..,
i got this php code to workout on something on my blog, but it seems that it
gives me the following error:

Parse error: syntax error, unexpected ';' in
/hxxx/x/domains/x.com/public_html/blog/labels.php on line 15


http://.x.com/labels');
define('SEARCH_DIR','//x/domains/x.com/public_html/blog/labels');
define('THIS_FILE', 'cloud.php');
if(file_exists(SEARCH_DIR.'_cloud_include_cache.html') &&
filemtime(SEARCH_DIR.'_cloud_include_cache.html')>(time()-(60*60)))
echo file_get_contents(SEARCH_DIR.'_cloud_include_cache.html');
else
{
$output = '';
$files = array();
$dir = opendir(SEARCH_DIR);
while($file = readdir($dir))
if($file != '.' && $file != '..' && $file != THIS_FILE
&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;&


How can above string be ever correct

$file != CACHE_FILE)
{
$files[] = $file;
}


Anyhelp on this will ve be very much appreciated, thanks..

Ian

Try this code:

http://.x.com/labels');
define('SEARCH_DIR','//x/domains/x.com/public_html/blog/labels');
define('THIS_FILE', 'cloud.php');
if(file_exists(SEARCH_DIR.'_cloud_include_cache.html') &&
filemtime(SEARCH_DIR.'_cloud_include_cache.html')>(time()-(60*60)))
echo file_get_contents(SEARCH_DIR.'_cloud_include_cache.html');
else
{
$output = '';
$files = array();
$dir = opendir(SEARCH_DIR);
while($file = readdir($dir))
if($file != '.' && $file != '..' && $file != THIS_FILE && $file != CACHE_FILE)
{
$files[] = $file;
}

It should work, if not, come back here :)

Tijnema


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Parse error help.., thanks..

2007-03-30 Thread Davi
Em Sexta 30 Março 2007 18:55, Ian escreveu:
> Parse error: syntax error, unexpected ';' in
> /hxxx/x/domains/x.com/public_html/blog/labels.php on line 15
>
> 
 http://.x.com/labels');
2 
define('SEARCH_DIR','//x/domains/x.com/public_html/blog/labels');
3 define('THIS_FILE', 'cloud.php');
4 if(file_exists(SEARCH_DIR.'_cloud_include_cache.html') &&
5 filemtime(SEARCH_DIR.'_cloud_include_cache.html')>(time()-(60*60)))
6 echo file_get_contents(SEARCH_DIR.'_cloud_include_cache.html');
7 else
8 {
9 $output = '';
10 $files = array();
11 $dir = opendir(SEARCH_DIR);
12 while($file = readdir($dir))
13 if($file != '.' && $file != '..' && $file != THIS_FILE
14 &amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;am
15 p;amp;amp;& $file != CACHE_FILE)
16 {
17 $files[] = $file;
18 }

Try remove the "&"s...

[]s


-- 
Davi Vidal
[EMAIL PROTECTED]
[EMAIL PROTECTED]
--

Agora com fortune:
"Toothpaste never hurts the taste of good scotch."

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Parse error help.., thanks..

2007-03-30 Thread Ian
Hi everyone, i am new to PHP, but not a programmer..,
i got this php code to workout on something on my blog, but it seems that it 
gives me the following error:

Parse error: syntax error, unexpected ';' in 
/hxxx/x/domains/x.com/public_html/blog/labels.php on line 15


http://.x.com/labels');
define('SEARCH_DIR','//x/domains/x.com/public_html/blog/labels');
define('THIS_FILE', 'cloud.php');
if(file_exists(SEARCH_DIR.'_cloud_include_cache.html') &&
filemtime(SEARCH_DIR.'_cloud_include_cache.html')>(time()-(60*60)))
echo file_get_contents(SEARCH_DIR.'_cloud_include_cache.html');
else
{
$output = '';
$files = array();
$dir = opendir(SEARCH_DIR);
while($file = readdir($dir))
if($file != '.' && $file != '..' && $file != THIS_FILE 
&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;&
 
$file != CACHE_FILE)
{
$files[] = $file;
}


Anyhelp on this will ve be very much appreciated, thanks..

Ian 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php