Web Analytics Made Easy -
StatCounter Killing hyperlinks from include files - CodingForum

Announcement

Collapse
No announcement yet.

Killing hyperlinks from include files

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Killing hyperlinks from include files

    Ok...here goes.

    Quite simply I need to be able to break hyperlinks from include files that are to be loaded into a frame.

    The complicated bit - The pages that are going into the frame are retieved from the web (absolute links) therefore I cannot edit any of the pages. These pages have their own header and nav bar which I need to leave out. I am able to retrieve just the include file, which is pure text, into the frame. So everything seems hunky dorky.

    Not quite

    The include file that I have loaded into the frame from the external site contains hyperlinks. When clicked, they load the new page into the frame with it's header, nav bar etc , which is what I'm am trying to avoid. The result is that I have a whole site loaded into 1 small frame when all I need is the text include within the page.

    Please please please someone tell me there is a way to disable these hyperlinks within the include file.

  • #2
    What language you using to include the files? it'll help us out a bit. But I really dont thing you can do this.

    Comment


    • #3
      The includes are writen in html I believe. Not quite sure if this is possible either but I had to check with you all. If there is no solution I ill have to set to work getting the whole external site replicated onto my server so that I can 'cherrypick' its content.

      Comment


      • #4
        This is a completely random shot in the dark, but have you considered chucking the includes into some client-side script? I haven't thought it through at all, but something like:

        <script>
        var strContent="<!--#include file="stuff.htm"-->"
        </script>

        Then you could run your replace / split functions on it and cut it down to the bits you want. I dunno. Might work. Probably won't. Sorry

        Comment


        • #5
          yeah I thought about that. Store the html in a variable, modify it and rewrite the html to a file without hyperlinks etc. If only I had more experience I may be able to do it.

          Comment

          Working...
          X