Looping through webpages


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 7 of 7

Thread: Looping through webpages

  1. #1
    Join Date
    Sep 2006
    Posts
    6

    Looping through webpages

    How do i loop through websites pages for example myspace the end of the url has numbers how would i loop through them?
    Thx

  2. #2
    Join Date
    Sep 2006
    Posts
    7
    Quote Originally Posted by Fry
    How do i loop through websites pages for example myspace the end of the url has numbers how would i loop through them?
    Thx
    please can u be more specific, cause it seems that ur question is a nice one , thank you ...

  3. #3
    Join Date
    Sep 2006
    Posts
    8
    Fry

    Are you referring to URL something like below, in which you wish to retrieve values after "?". E.g. in URL below, "t" has value 155678

    http://forums.devx.com/showthread.php?t=155678

  4. #4
    Join Date
    Sep 2006
    Posts
    6

  5. #5
    Join Date
    Mar 2005
    Location
    UK, London
    Posts
    150
    A bit more information, why do you want to loop it whats the pupose, I can have it loop, but wont do anything, whats the purpose? Do you want to see the pages for each number?

  6. #6
    Join Date
    Sep 2006
    Posts
    8
    Quote Originally Posted by Fry
    In order to loop, you need start value and end value.
    Retrieve them from appropriate parameter (see details below), convert it to int using static method in Interger class
    ( Integer.parseInt() ), and use the values as you like.

    Servlet API has methods that
    1. would get you value of given parameter
    2. would get only values of all the parameters
    3. would get names of all the parameters


    In case you know parameter name, use it to get parameter value in form of String object. Convert to appropriate type (counters are usually int) and use it.

    In case you dont know what are parameter names, then get all the parameter names, and loop thru them, passing each as argument to retrieve its value.

    Hope that solves your problem.
    Last edited by kvasani; 09-07-2006 at 02:55 AM. Reason: more details

  7. #7
    Join Date
    Sep 2006
    Posts
    6
    Well i have a purpose to loop it with out going through the pages.. just the same link over and over,

Similar Threads

  1. QUERY: Multiple Document Interface (MDI) in webpages...
    By dhruba.bandopad in forum ASP.NET
    Replies: 0
    Last Post: 04-07-2006, 07:51 AM
  2. Replies: 0
    Last Post: 10-26-2005, 08:54 AM
  3. Looping within MTA
    By al in forum Enterprise
    Replies: 0
    Last Post: 02-15-2001, 06:51 PM
  4. Looping grid
    By Jeremy Samkowiak in forum ASP.NET
    Replies: 0
    Last Post: 08-31-2000, 03:46 AM
  5. Looping in DTS
    By Chris Kinsman in forum Database
    Replies: 0
    Last Post: 03-14-2000, 01:46 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center