Andreas Gohr | 1 Nov 04:00
Favicon
Gravatar

darcs changes 2007-11-01


Good Morning!

This are the darcs changes for DokuWiki committed
yesterday. Please test them and report bugs.

---------------------------------------------------------------------
Thu Nov  1 01:00:01 CET 2007  Andreas Gohr <andi[at]splitbrain.org>
  tagged develsnap 2007-11-01
---------------------------------------------------------------------

Single patches can be downloaded from
http://dev.splitbrain.org/darcs/index.cgi/dokuwiki/?c=patches

Bye,
your darcs changelog mailer

--

-- 
DokuWiki mailing list - more info at
http://wiki.splitbrain.org/wiki:mailinglist

Morten Lemvigh | 1 Nov 10:05
Picon

Re: PHP and global question

Myron Turner wrote:
> It sounds like a path problem.
> When you include the nested file in myclass.php, do you use an absolute 
> path name or a relative pathname?

What I have is something like:

in included.php:
----------------------
$myVar = "message";
----------------------

and in myclass.php:
----------------------
require_once "included.php";

echo $myVar

class MyClass {
   ...
   global $myVar
   echo $myVar
}
----------------------

Outside the class in myclass.php, there is no problem. But inside 
MyClass i cannot access $myVar. Both files are in the same directory, 
but in a different directory from doku.php. All inclusions are relative. 
    But I don't see, how entering a class definition should do anything 
to the path?
(Continue reading)

Chris Smith | 1 Nov 10:19
Picon

Re: PHP and global question

Is caching disabled for the page with the php?

Without it, its quite likely your php isn't being run at all.  For more
information read up on the parser and caching at splitbrain.org.

-- Chris
--

-- 
DokuWiki mailing list - more info at
http://wiki.splitbrain.org/wiki:mailinglist

Tux | 1 Nov 10:22
Picon
Gravatar

Link external to DW, but internal to the site

Hello,

Is it possible to do links which are internal to the site, but
external to Dokuwiki?
Here's an example :
Dokuwiki is installed on www.example.com/wiki/
I have a page on www.example.com/about.html
Currently, I do this to link to this page :
[[http://www.example.com/about.html|About us]]
But this is seen as an external link to Dokuwiki.
I tried this :
[[/about.html|About us]]
but it wants to create http://www.example.com/wiki/about.html

How can I do?

Thanks
Yann
--

-- 
DokuWiki mailing list - more info at
http://wiki.splitbrain.org/wiki:mailinglist

Todd Augsburger | 1 Nov 12:13

Re: Link external to DW, but internal to the site


The "baselink" plugin ( http://wiki.splitbrain.org/plugin:baselink ) will do 
what you want.
Description: Makes links beginning with "/" present as (always valid) 
internal links that point relative to your domain's root. Format is 
[[/pagename|optional title]]

Todd Augsburger
todd <at> rollerorgans.com
Roller Organs
www.rollerorgans.com

----- Original Message ----- 
From: "Tux" <cactux <at> gmail.com>
To: <dokuwiki <at> freelists.org>
Sent: Thursday, November 01, 2007 5:22 AM
Subject: [dokuwiki] Link external to DW, but internal to the site

Hello,

Is it possible to do links which are internal to the site, but
external to Dokuwiki?
Here's an example :
Dokuwiki is installed on www.example.com/wiki/
I have a page on www.example.com/about.html
Currently, I do this to link to this page :
[[http://www.example.com/about.html|About us]]
But this is seen as an external link to Dokuwiki.
I tried this :
[[/about.html|About us]]
(Continue reading)

Chris Smith | 1 Nov 12:52
Picon

Re: Link external to DW, but internal to the site

You can also set it up as an interwiki link.  See the
conf/interwiki.conf file for more details (also check
wiki.splitbrain.org). Local additions go in conf/interwiki.local.conf,
which you will need to create.  You can also create a specific icon to
go with the link.

-- Chris

Todd Augsburger wrote:
> The "baselink" plugin ( http://wiki.splitbrain.org/plugin:baselink ) will do 
> what you want.
> Description: Makes links beginning with "/" present as (always valid) 
> internal links that point relative to your domain's root. Format is 
> [[/pagename|optional title]]
>
> Todd Augsburger
> todd <at> rollerorgans.com
> Roller Organs
> www.rollerorgans.com
>
>
> ----- Original Message ----- 
> From: "Tux" <cactux <at> gmail.com>
> To: <dokuwiki <at> freelists.org>
> Sent: Thursday, November 01, 2007 5:22 AM
> Subject: [dokuwiki] Link external to DW, but internal to the site
>
>
> Hello,
>
(Continue reading)

Morten Lemvigh | 1 Nov 14:24
Picon

Re: PHP and global question

Chris Smith wrote:
> Is caching disabled for the page with the php?

I just tried to disable caching, but the problem persists.

--

-- 
DokuWiki mailing list - more info at
http://wiki.splitbrain.org/wiki:mailinglist

Andreas Gohr | 1 Nov 14:35
Favicon
Gravatar

Re: PHP and global question

Morten Lemvigh writes:

> Chris Smith wrote:
>> Is caching disabled for the page with the php?
> 
> I just tried to disable caching, but the problem persists.

Stuff inside <php></php> is passed to PHP's eval() function. PHP executed in 
an eval construct might behave different from a normal script context. 
Search the froum I think there was a similar question before.

For complex work I recommend to write a real plugin instead.

Andi

--

-- 
DokuWiki mailing list - more info at
http://wiki.splitbrain.org/wiki:mailinglist

Myron Turner | 1 Nov 15:22
Picon
Favicon
Gravatar

Re: PHP and global question

Morten Lemvigh wrote:
> Myron Turner wrote:
>> It sounds like a path problem.
>> When you include the nested file in myclass.php, do you use an 
>> absolute path name or a relative pathname?
>
> What I have is something like:
>
> in included.php:
> ----------------------
> $myVar = "message";
> ----------------------
>
> and in myclass.php:
> ----------------------
> require_once "included.php";
>
> echo $myVar
>
> class MyClass {
>   ...
>   global $myVar
>   echo $myVar
> }
> ----------------------
>
> Outside the class in myclass.php, there is no problem. But inside 
> MyClass i cannot access $myVar. Both files are in the same directory, 
> but in a different directory from doku.php. All inclusions are 
> relative.    But I don't see, how entering a class definition should 
(Continue reading)

Ged Byrne | 1 Nov 17:47
Picon

Re: PHP and global question

Have you tried adding some log statements to see what code gets run
when.  The order of execution may no be what you'd expect.

On 11/1/07, Morten Lemvigh <lemvigh <at> studentergaarden.dk> wrote:
> Myron Turner wrote:
> > It sounds like a path problem.
> > When you include the nested file in myclass.php, do you use an absolute
> > path name or a relative pathname?
>
> What I have is something like:
>
> in included.php:
> ----------------------
> $myVar = "message";
> ----------------------
>
> and in myclass.php:
> ----------------------
> require_once "included.php";
>
> echo $myVar
>
> class MyClass {
>    ...
>    global $myVar
>    echo $myVar
> }
> ----------------------
>
> Outside the class in myclass.php, there is no problem. But inside
(Continue reading)


Gmane