Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.php > #14526

Re: can one link reference two seperate files?

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!news.swapon.de!eternal-september.org!feeder.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail
From Ben Bacarisse <ben.usenet@bsb.me.uk>
Newsgroups comp.lang.php
Subject Re: can one link reference two seperate files?
Date Mon, 10 Nov 2014 19:07:58 +0000
Organization A noiseless patient Spider
Lines 26
Message-ID <87ioim7u29.fsf@bsb.me.uk> (permalink)
References <mn1jm36vp2n5.bryfbmjsjuzb$.dlg@40tude.net>
Mime-Version 1.0
Content-Type text/plain
Injection-Info mx02.eternal-september.org; posting-host="017616aa25f81ec581c44d76d61ba2f3"; logging-data="14741"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18kpuMInoSexvdGEjuQaDnIpS9O/wQV5Zo="
Cancel-Lock sha1:zFj96i8Vb9t7UMKuxY2ZRVQ2KC0= sha1:F6Dvygmwul1Wa+azVLkk/b7wX6g=
X-BSB-Auth 1.f6ec69d6443cb6b9a9b4.20141110190758GMT.87ioim7u29.fsf@bsb.me.uk
Xref csiph.com comp.lang.php:14526

Show key headers only | View raw


richard <noreply@example.com> writes:

> <A href="page1.php">
> Is the normal way of linking.
> What if I need to send a value to page1 and another value to page2?
> With just one click.
> Or can they be nested?
> <a href="page1.php"><a href="page2.php">link</a></a>

As has been explained (and you've also concluded yourself) they can't be
nested.  But if what you really want is for some action to be performed
on the server before loading page1.php, you can make page2.php perform
the action and reply with an HTTP redirect header for page1.php.

Alternatively, if the order is not very important (maybe you are logging
actions of some sort), the PHP for page1.php can reply with the page as
normal but include within it something like an invisible image:

  <img src="page2.php">

or a link to a page2.php as a stylesheet in the header.  As always with
this sort of question, the best answer will depend on what you are
really trying to do.

-- 
Ben.

Back to comp.lang.php | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

can one link reference two seperate files? richard <noreply@example.com> - 2014-11-10 10:41 -0500
  Re: can one link reference two seperate files? richard <noreply@example.com> - 2014-11-10 10:45 -0500
  Re: can one link reference two seperate files? "J.O. Aho" <user@example.net> - 2014-11-10 18:05 +0100
    Re: can one link reference two seperate files? Matthew Carter <m@ahungry.com> - 2014-11-10 12:10 -0500
      Re: can one link reference two seperate files? "J.O. Aho" <user@example.net> - 2014-11-10 20:25 +0100
        Re: can one link reference two seperate files? Arno Welzel <usenet@arnowelzel.de> - 2014-11-17 13:40 +0100
  Re: can one link reference two seperate files? "Christoph M. Becker" <cmbecker69@arcor.de> - 2014-11-10 18:19 +0100
  Re: can one link reference two seperate files? Ben Bacarisse <ben.usenet@bsb.me.uk> - 2014-11-10 19:07 +0000
  Re: can one link reference two seperate files? Denis McMahon <denismfmcmahon@gmail.com> - 2014-11-10 21:24 +0000
  Re: can one link reference two seperate files? Norman Peelman <npeelman@cfl.rr.com> - 2014-11-18 06:42 -0500

csiph-web