User Profile

Collapse

Profile Sidebar

Collapse
mike809
mike809
Last Activity: Sep 16 '11, 10:33 PM
Joined: Aug 18 '11
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • mike809
    started a topic Javascript using link user click simulation
    in PHP

    Javascript using link user click simulation

    I'd like to get contents of a website using JavaScript menu. I need to simulate clicks (or typing javascript:goto Page("p10"); into a browser) on menu links to be able to move from one page to another.

    Basically the process will look like this:
    while (any_content) {
    file_get_conten ts();
    clickalink();
    }

    Can cURL or JSON be used for this task?...
    See more | Go to post

  • mike809
    replied to Getting relative URL out of an absolute one
    in PHP
    Doesn't it work with the current URL only, that means the one which the script is called from? I need it to be done with strings stored in an array.
    See more | Go to post

    Leave a comment:


  • mike809
    started a topic Getting relative URL out of an absolute one
    in PHP

    Getting relative URL out of an absolute one

    I'd like to parse the URL part after TLD. In another words I'm interested in the bold part http://bytes.com/submit/304/ of this URL.
    Let's assume that all the URLs are valid and formally flawless.
    It seems to me one way is to make a regular expression like this: "anything, dot, 2 to 4 letters, slash, anything". The Regexp might look like this:
    Code:
    $regexp = '@.+\.[a-z]{2,4}\/(.+)@si';
    Is my thinking correct or am...
    See more | Go to post

  • Thank you very much, I'm interested in parsing out the URLs only, so I'll probably do that the same way you did it with the A tags. That means finding >href="< and >"< and then use substr() function.
    See more | Go to post

    Leave a comment:


  • Extracting URL from a link containing a specific string

    I'd like to get address of certain links with desired text. Let's say I want to get links containing a word "BMW".

    Code:
    <a href="http://abc.com/xxxx">Dodge</a>
    <a href="http://abc.com/a123.php">Used [B]BMW[/B] card</a>
    <a href="http://xyz.com/ferrari">Brand new Ferraris</a>
    <a href="http://xyz.com/vjklj"><img src="pic.jpg"
    ...
    See more | Go to post
No activity results to display
Show More
Working...