Excellent tip. Thanks so much.
I added to the config:
$BOLTvar['$port']=$_SERVER["SERVER_PORT"];
And on my site I can now use:
[if equal {port} 80][[http://{domain}/field]][else][[http://{domain}:
{port}/field]][if]
Which links to the field independently of the server, domain and port.
I would add this to the docs but it's already there. It just didn't
occur to me to look for config settings. My mental BoltWire map is
composed of bits and pieces. I wonder if I can't come up with a one-
page diagram or mind-map that will give new users (and myself) a what-
is-what, where-is-what and where-do-I-look-when reference.
On Mar 10, 12:28 pm, The Editor <[email protected]> wrote:
> Not all servers include the port number like that. But you should be
> able to redefine it by setting $BOLTvar['$domain'] to anything you
> want in a config file...
>
> Cheers,
> Dan
>
>
>
> On Wed, Mar 10, 2010 at 2:41 AM, Markus <[email protected]> wrote:
> > Thinking more about this it's a bad idea to return localhost:8888.
> > That would make {domain} worse. Rather a markup would be useful that
> > gives you the part of the address before the field. Like:
>
> >http://localhost/
> >http://localhost:1234/
> >http://boltwire.com/
> >http://www.boltwire.com/
> > ...
>
> > This would for example allow dynamic linking to another field.
>
> > Markus
>
> > PS: My brain seems to be thinking in waves which could explain the
> > split posts in the same threads lately.
>
> > On Mar 10, 8:21 am, Markus <[email protected]> wrote:
> >> Hi,
>
> >> {domain} should include a trailing port number. If the domain is like
> >> “http://localhost:8888/field" it should return "localhost:8888"
> >> instead of just "localhost". The resulting link might be in conflict
> >> with interwiki markup.
>
> >> Markus
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "BoltWire" group.
> > To post to this group, send email to [email protected].
> > To unsubscribe from this group, send email to
> > [email protected].
> > For more options, visit this group
> > athttp://groups.google.com/group/boltwire?hl=en.
--
You received this message because you are subscribed to the Google Groups
"BoltWire" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/boltwire?hl=en.