Script question: Code that pulls my galleries with descriptions from a file

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • justsexxx
    Too lazy to set a custom title
    • Aug 2001
    • 13723

    #1

    Script question: Code that pulls my galleries with descriptions from a file

    IS this possible?

    I already know a script which gets random galleries from a txt file. You add this into a php script, and everytime a surfer clicks the link, a random url is picked.

    But what I want now, is almost the same, but then WITH description...IS this possible? And not a random description, but one special made for THAt gallery.

    so to be clearer(I hope) I want this

    amateur.txt

    http://www.url1.com Horny biatch
    http://www.url2.com Drunk amateur sucking
    http://www.url3.com Quashe fucking an amateur

    etc

    Now when my page loads it displays

    Quashe fucking an amateur
    Drunk amateur sucking
    Horny biatch


    and when it is loaded again it displays for example

    Drunk amateur sucking
    Quashe fucking an amateur
    Horny biatch

    it doesn't have to be different every time when the page is loaded, it is also okay if it can be changed once a day by pressing a button or so by me

    Any idea where I have to look>?

    Andre


    __________________
    Questions?

    ICQ: 125184542
  • SimonBalk
    Confirmed User
    • Jul 2002
    • 197

    #2
    I can make it for you. contact me if you want more details

    Comment

    • AcidMax
      Confirmed User
      • May 2002
      • 1827

      #3
      That can be done in two minutes with PHP using simple file opening procedures and pulling a random line from the text file.

      If you need help contact me on ICQ: 70930467.

      Andy
      Latest MMA news. http://www.mmawrapup.com

      Comment

      • darksoul
        Confirmed User
        • Apr 2002
        • 4997

        #4
        just in case its not solved yet: 157717888
        1337 5y54|)m1n: 157717888
        BM-2cUBw4B2fgiYAfjkE7JvWaJMiUXD96n9tN
        Cambooth

        Comment

        • justsexxx
          Too lazy to set a custom title
          • Aug 2001
          • 13723

          #5
          used this one

          Code:
          <table border="0" cellspacing="0" cellpadding="0">
          <script language="JavaScript">
          var across = 1;
          var down   = 3;
          var before = '<td align="left"><a href="';
          var after  = '</a></td>';
          
          var pix = new Array(
          '/cgi-bin/ucj/c.cgi?url=http://www.url1.com">desc 1',
          '/cgi-bin/ucj/c.cgi?url=http://www.url2.com">desc 2',
          '/cgi-bin/ucj/c.cgi?url=http://www.url3.com">desc 3',
          '/cgi-bin/ucj/c.cgi?url=http://www.url4.com">desc 4'
          );
          for(var a=0; a<down; a++){
          document.write("<tr>");
          for(var i=0; i<across; i++){
          var cnum = Math.round((pix.length-1)*Math.random());
          
          document.write(before+pix[cnum]+after);
          
          size = pix.length;
          
          for (var j=0; j<=size; j++)
          pix[j] = ((j == cnum) ? "delete" : pix[j]);
          for (var k=cnum; k<size-1; k++)
          if (k != size) pix[k] = pix[k+1];
          pix.length = size-1;
          }
          document.write("</tr>");
          }
          </script>
          </table>
          Thnx all

          Andre
          Last edited by justsexxx; 11-24-2002, 05:37 AM.
          Questions?

          ICQ: 125184542

          Comment

          • justsexxx
            Too lazy to set a custom title
            • Aug 2001
            • 13723

            #6
            for seome reason even after adding [code ] before and the close tag after the code, it keeps displaying the output.

            www.thumbtgp.com/code.txt for the script

            Andre
            Questions?

            ICQ: 125184542

            Comment

            Working...