Jump to content

Recommended Posts

Be more precise, you need to provide us with more details on what you want to do. You want to open a url (How? Is the Url just a page? Is it supose to load from PHP automaticaly? Is it from your Mysql?)...

 

To solve your HTML link problem

 

< a href= "http://www.google.com">Go to google</a>

 

Link to comment
https://forums.phpfreaks.com/topic/89814-click-word-on-webpage/#findComment-460279
Share on other sites

I did a Google as advised and found this:

 

<?php

$handle = fopen("http://www.google.co.uk/", "r");

?>

 

I'm presuming the above opens url!

 

If this worked how would i get the word "ADVERTISING PROGRAMMES" link clicked???

 

Look forward to your reply.

 

regards

 

BFGK

Link to comment
https://forums.phpfreaks.com/topic/89814-click-word-on-webpage/#findComment-460283
Share on other sites

Thanks

 

But i'm no fraudster!!!

 

Just a newbie to PHP! I thought that PHP would be a cool method of producing the same results as VB.

 

I created some code in VBScript that uses sendkeys to logon to website and download text files for our business!!!

 


Set objShell = WScript.CreateObject("WScript.Shell")

objShell.Run "iexplore.exe"
objShell.AppActivate "Internet Explorer" , 3
WScript.Sleep 1000

objShell.run("http://www")
WScript.Sleep 8000

objShell.Sendkeys "username"
WScript.Sleep 3000

objShell.Sendkeys "{TAB}"
WScript.Sleep 3000

objShell.Sendkeys "password"
WScript.Sleep 3000

'objShell.Sendkeys "{ENTER}"
'WScript.Sleep 50000

objShell.Sendkeys "{TAB 7} "
WScript.Sleep 1000

'objShell.Sendkeys "{ENTER}"
'WScript.Sleep 50000

objShell.Sendkeys "{TAB 12}"
WScript.Sleep 1000

objShell.Sendkeys "{ENTER}"
WScript.Sleep 5000

' download file save to desktop										
'objShell.Sendkeys "{TAB 2}"
'WScript.Sleep 5000

objShell.Sendkeys "{ENTER}"
WScript.Sleep 1000

objShell.Sendkeys "{ENTER}"
WScript.Sleep 10000

objShell.Sendkeys "%f" 
WScript.Sleep 8000

objShell.Sendkeys "{DOWN 11}" 
WScript.Sleep 3000

objShell.Sendkeys "{ENTER}"
WScript.Sleep 8000

'objShell.Sendkeys "%f" 
'WScript.Sleep 1000

'objShell.Sendkeys "{DOWN 4}" 
'WScript.Sleep 1000

'objShell.Sendkeys "{ENTER}"
'WScript.Sleep 3000


 

 

As you can above the code is long and complicated!!!

 

Lock the topic if you think thats appropriate!

 

I will stay a newbie forever!!!

 

thanks

 

BFGK

Link to comment
https://forums.phpfreaks.com/topic/89814-click-word-on-webpage/#findComment-460325
Share on other sites

you can do something like ...

 

put a link that has a login details

 

assuming you have this on your link!

 

teng.php?user=teng&id=123456

 

now when you click the link you will be navigated on to that page right? now do this..

 

if(isset($_GET['user']) && isset($_GET['id'])){
      if(//check if valid username and id){
               header('location: location of the text file  to be downloaded');
       }else{
       //do erroring thingy
      }
}else{
//not valid
}

 

hope that helps..

Link to comment
https://forums.phpfreaks.com/topic/89814-click-word-on-webpage/#findComment-460331
Share on other sites

Hello all

 

I've been researching into my forum question and i think the first stage that i was trying to explain was REDIRECTION to another webpage!

 

The form page i am trying to create uses basic authentication.

 

Creating a form that inserts username and password into this: http://username:password@www.webpage.com

 

Any ideas or examples to look at!

 

regards

 

BFGK

Link to comment
https://forums.phpfreaks.com/topic/89814-click-word-on-webpage/#findComment-461879
Share on other sites

Hello all

 

I thought i'd keep you all updated on my progress!!

 

Created the simple form page! (Even got page to email back result!!!)

 

Used POST method.

 

Now able to create the basic authentication link/url: http:username:password@www.webpage.com

 

Learnt a lot searching google created url link from above but really want to the above link to open without displaying webpage and locate specific file!!!

 

I was wondering whether this is possible???

 

Look forward to any replies!

 

regards

 

BFGK

 

 

 

Link to comment
https://forums.phpfreaks.com/topic/89814-click-word-on-webpage/#findComment-462345
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.