I need some code that places the site url on the page...

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Jace
    FBOP Class Of 2013
    • Jan 2004
    • 35562

    #1

    I need some code that places the site url on the page...

    I am creating a parked page for my shit...just a generic page that has all the search shit and all that...similar to godaddy's parked page

    anyway, i need a piece of code that will place the www.domain.com on the page wherever I place the code, including the title

    so, it is dynamic, wherever I place the code the url of the site will show up
  • NickPapageorgio
    Confirmed User
    • Apr 2004
    • 8323

    #2
    Do an include there. ;)

    Comment

    • NickPapageorgio
      Confirmed User
      • Apr 2004
      • 8323

      #3
      I think the page has to be .shtml for includes and your server has to have SSI turned on also...I think...

      Comment

      • Jace
        FBOP Class Of 2013
        • Jan 2004
        • 35562

        #4
        Originally posted by NickPapageorgio
        I think the page has to be .shtml for includes and your server has to have SSI turned on also...I think...
        I have includes all over my .php pages

        but what type of include, how would it look?

        Comment

        • NickPapageorgio
          Confirmed User
          • Apr 2004
          • 8323

          #5
          I think it would be something like
          Code:
          <!--#include file="thisfile.txt" -->
          Then use a regular text file to update the actual code.

          Like if you had the text file in a folder called "misc" the code whereever you want to include it would look like
          Code:
          <!--#include file="/misc/thisfile.txt" -->
          You'd drop that code in wherever you wanted that to show up...
          Last edited by NickPapageorgio; 10-31-2005, 08:04 AM.

          Comment

          • Jace
            FBOP Class Of 2013
            • Jan 2004
            • 35562

            #6
            Originally posted by NickPapageorgio
            I think it would be something like
            Code:
            <!--#include file="thisfile.txt" -->
            The use a regular text file to update the actual code.
            so, if I have 100,000 parked pages, this code will dynamically place the url of whatever page is loaded in the place i put that code?

            doesn't seem right

            Comment

            • NickPapageorgio
              Confirmed User
              • Apr 2004
              • 8323

              #7
              Originally posted by Jace
              so, if I have 100,000 parked pages, this code will dynamically place the url of whatever page is loaded in the place i put that code?

              doesn't seem right
              Oh, you mean it's going to be changing with the actual URL of the page where it resides...I got ya.

              I thought you meant you wanted the same URL to appear on 100's of pages...my bad man.

              Comment

              • The Truth Hurts
                WINK WINK NUDGE NUDGE
                • Nov 2002
                • 15818

                #8
                Code:
                <SCRIPT language="JavaScript">
                <!--
                loc=location.href;
                document.write(loc)
                //-->
                </SCRIPT>

                Comment

                • Jace
                  FBOP Class Of 2013
                  • Jan 2004
                  • 35562

                  #9
                  <SCRIPT language="JavaScript">
                  <!--
                  loc=location.href;
                  document.write(loc)
                  //-->
                  </SCRIPT>


                  PERFECT!

                  Comment

                  • Jace
                    FBOP Class Of 2013
                    • Jan 2004
                    • 35562

                    #10
                    shit, that last one won't allow it in the title bar

                    Comment

                    • fuzebox
                      making it rain
                      • Oct 2003
                      • 22379

                      #11
                      <? print $_SERVER[SERVER_NAME]; ?>

                      Comment

                      • Jace
                        FBOP Class Of 2013
                        • Jan 2004
                        • 35562

                        #12
                        Originally posted by fuzebox
                        <? print $_SERVER[SERVER_NAME]; ?>
                        there we go, that is perfect

                        Comment

                        • grumpy
                          Too lazy to set a custom title
                          • Jan 2002
                          • 9870

                          #13
                          <SCRIPT language="JavaScript">
                          <!--
                          loc=location.href;
                          document.write(loc)
                          window.document.title=loc;
                          //-->
                          </SCRIPT>

                          that should do it.
                          Don't let greediness blur your vision | You gotta let some shit slide
                          icq - 441-456-888

                          Comment

                          • fuzebox
                            making it rain
                            • Oct 2003
                            • 22379

                            #14
                            Originally posted by Jace
                            there we go, that is perfect
                            Cheers

                            Comment

                            Working...