Problem with <BASE> and <A href="#...">

Discussion in 'HTML' started by cipher, Mar 6, 2008.

  1. cipher

    cipher Guest

    Hi there,

    I ran into a problem using <a href="#some_anchor"> in combination with
    <base href="...">.

    I have a PHP-script which creates a report in HTML from a database.
    The script is called in two ways:
    1. directly via browser
    2. and by a cronjob with mails the report to a mailing list
    The report contains both links to anchors inside the same document and
    links to external resources. Calling the script by a browser works
    fine. The mailed report contains an additional <BASE> to get valid
    links to external resources, but the links to the anchors inside the
    report are now wrong. (Using such a link forces the browser to reload
    the HTML document from server before jumping to the anchor. This may
    lead to a wrong report, if some records in DB has changed since
    mailing the correct report)

    Do I have to rewrite all external links or is there a better solution?


    thx,

    Markus
     
    cipher, Mar 6, 2008
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. CRON
    Replies:
    24
    Views:
    200,816
    Adrienne Boswell
    Jun 20, 2006
  2. Soren Vejrum
    Replies:
    4
    Views:
    620
    Lasse Reichstein Nielsen
    Jul 5, 2003
  3. saiho.yuen
    Replies:
    3
    Views:
    434
    kaeli
    Sep 14, 2004
  4. Replies:
    2
    Views:
    479
  5. Vincent van Beveren

    BASE HREF and A HREF="#" onclick="..."

    Vincent van Beveren, Jul 6, 2006, in forum: Javascript
    Replies:
    2
    Views:
    327
    Vincent van Beveren
    Jul 6, 2006
Loading...

Share This Page