Jump to content

Recommended Posts

Posted (edited)

yes it is activated

I have my firewall turned off

EDIT: it works if i use _FFStart to start a new firefox and get the link then

Edited by d0n
Posted

yes it is activated

I have my firewall turned off

EDIT: it works if i use _FFStart to start a new firefox and get the link then

OK - _FFStart activates MozRepl per commandline. Do you have it really activated? In the menu Extras(Tools)/MozRepl the first entry must be "Stop" then it works and "Activate on startup" should be checked.
  • 2 weeks later...
Posted

hi, i've ran into another problem

I am trying to enter some text in a field and click a button

<textarea rows="7" cols="10" name="message" id="message" class="autosave" style="width: 100%; height: 120px;" onkeydown="ctlent(event);" tabindex="2"></textarea><br><br>

Button

<input class="button" name="replysubmit" id="postsubmit" value="Submit" tabindex="3" title="" type="submit">

For the inserting the text part i am trying to use _FFSetValue()

but i am not sure how to use it, i've tried looking at your examples on the site, however it doesn't type USER on the user field and PASS on the password field

#include <FF.au3>

If _FFStart("http://ff-au3-example.thorsten-willert.de/",default,2) Then
    _FFSetValue("user","Max Mustermann")
    _FFSetValue("pass","My_Password")

    _FFDisConnect()
EndIf
Posted

hi, i've ran into another problem

I am trying to enter some text in a field and click a button

<textarea rows="7" cols="10" name="message" id="message" class="autosave" style="width: 100%; height: 120px;" onkeydown="ctlent(event);" tabindex="2"></textarea><br><br>

Button

<input class="button" name="replysubmit" id="postsubmit" value="Submit" tabindex="3" title="" type="submit">

;...
_FFSetValue("YourMessage", "message", "id")
_FFClick("postsubmit", "id")

For the inserting the text part i am trying to use _FFSetValue()

but i am not sure how to use it, i've tried looking at your examples on the site, however it doesn't type USER on the user field and PASS on the password field

#include <FF.au3>

If _FFStart("http://ff-au3-example.thorsten-willert.de/",default,2) Then
    _FFSetValue("user","Max Mustermann")
    _FFSetValue("pass","My_Password")

    _FFDisConnect()
EndIf

Sorry, the example was wrong. But you can see in the error-messages what is wrong ...

Corrected example:

#include <FF.au3>

If _FFStart("http://ff-au3-example.thorsten-willert.de/",default,2) Then
    _FFSetValue("Max Mustermann", "user", "id")
    _FFSetValue("My_Password","pass", "id")

    _FFDisConnect()
EndIf
Posted

is it possible to start Firefox hidden? right now using this code will start the firefox in full window, then minimized, then hidden.

_FFStart("about:blank",Default,1,True)
Posted (edited)

is it possible to start Firefox hidden? right now using this code will start the firefox in full window, then minimized, then hidden.

_FFStart("about:blank",Default,1,True)

Sorry it isn't possible. FireFox can't start, like many other applications, hidden. Run* and @sw_hide have no effect if you starting FireFox with it. So the current "hidden" starting is only a workaround for this "problem". Edited by Stilgar
Posted (edited)

_FFFrameEnter doesn't work . Help me.

#include <FF.au3>
_FFStart("http://vdict.com/",Default,1,False,"127.0.0.1",4242)
sleep (2000)
_FFFrameEnter(4)

>"C:\Program Files\AutoIt3\SciTE\..\autoit3.exe" /ErrorStdOut "C:\Documents and Settings\UserXP\Desktop\testforworks.au3"    
__FFStartProcess: ""C:\Program Files\Mozilla Firefox\firefox.exe" -new-window "http://vdict.com/"  -repl 4242  -P Default
_FFConnect: OS: WIN_XP WIN32_NT 2600 Service Pack 3
_FFConnect: AutoIt: 3.3.0.0
_FFConnect: FF.au3: 0.5.3.10b
_FFConnect: IP: 127.0.0.1
_FFConnect: Port:   4242
_FFConnect: Delay:  2ms
_FFConnect: Socket:     1704
__FFSend: try{window.content.top.document.browserDOMWindow}catch(e){'_FFCmd_Err';};
__FFRecv: 
__FFSend: try{navigator.userAgent}catch(e){'_FFCmd_Err';};
__FFRecv: Mozilla/5.0 (Windows; U; Windows NT 5.1; vi; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5
_FFConnect: Browser:    Mozilla/5.0 (Windows; U; Windows NT 5.1; vi; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5
__FFSendJavascripts: Sending functions to FireFox .......... done
_FFLoadWait: ................. loaded in 4318ms
>Exit code: 0    Time: 10.947
Edited by Unfrog
Posted

@DanP2:

I would change this in one of the next versions.

_FFFrameEnter doesn't work . Help me.

#include <FF.au3>
_FFStart("http://vdict.com/",Default,1,False,"127.0.0.1",4242)
sleep (2000)
_FFFrameEnter(4)

>"C:\Program Files\AutoIt3\SciTE\..\autoit3.exe" /ErrorStdOut "C:\Documents and Settings\UserXP\Desktop\testforworks.au3"    
__FFStartProcess: ""C:\Program Files\Mozilla Firefox\firefox.exe" -new-window "http://vdict.com/"  -repl 4242  -P Default
_FFConnect: OS: WIN_XP WIN32_NT 2600 Service Pack 3
_FFConnect: AutoIt: 3.3.0.0
_FFConnect: FF.au3: 0.5.3.10b
_FFConnect: IP: 127.0.0.1
_FFConnect: Port:   4242
_FFConnect: Delay:  2ms
_FFConnect: Socket:     1704
__FFSend: try{window.content.top.document.browserDOMWindow}catch(e){'_FFCmd_Err';};
__FFRecv: 
__FFSend: try{navigator.userAgent}catch(e){'_FFCmd_Err';};
__FFRecv: Mozilla/5.0 (Windows; U; Windows NT 5.1; vi; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5
_FFConnect: Browser:    Mozilla/5.0 (Windows; U; Windows NT 5.1; vi; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5
__FFSendJavascripts: Sending functions to FireFox .......... done
_FFLoadWait: ................. loaded in 4318ms
>Exit code: 0    Time: 10.947

Have you tried it with the current version (V0.6.0.0) of the FF.au3, too?

Where did you find any frame on this page: http://vdict.com/ ??

And why are you writing all default parameters into the function-call from _FFStart?:

_FFStart("http://vdict.com/")

is the same like

_FFStart("http://vdict.com/",Default,1,False,"127.0.0.1",4242)

Posted (edited)

>"C:\Program Files\AutoIt3\SciTE\..\autoit3.exe" /ErrorStdOut "C:\Documents and Settings\UserXP\Desktop\testforworks.au3"    
__FFStartProcess: ""C:\Program Files\Mozilla Firefox\firefox.exe" -new-window " http://vdict.com/"  -repl 4242  -P Default
_FFConnect: OS: WIN_XP WIN32_NT 2600 Service Pack 3
_FFConnect: AutoIt: 3.3.0.0
_FFConnect: FF.au3: 0.6.0.0b-5
_FFConnect: IP: 127.0.0.1
_FFConnect: Port:   4242
_FFConnect: Delay:  2ms
_FFConnect: Socket:     1700
__FFSend: try{window.content.top.document.browserDOMWindow}catch(e){'_FFCmd_Err';};
__FFRecv: 
__FFSend: try{navigator.userAgent}catch(e){'_FFCmd_Err';};
__FFRecv: Mozilla/5.0 (Windows; U; Windows NT 5.1; vi; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5
_FFConnect: Browser:    Mozilla/5.0 (Windows; U; Windows NT 5.1; vi; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5
__FFSendJavascripts: Sending functions to FireFox .......... done
_FFLoadWait: ................... loaded in 4855ms
>Exit code: 0    Time: 11.380

Nothing change , I've habit write full code and my English is very bad.So i test it on vdict site .With any iframe , I don't care

Edited by Unfrog
Posted

>"C:\Program Files\AutoIt3\SciTE\..\autoit3.exe" /ErrorStdOut "C:\Documents and Settings\UserXP\Desktop\testforworks.au3"    
__FFStartProcess: ""C:\Program Files\Mozilla Firefox\firefox.exe" -new-window " http://vdict.com/"  -repl 4242  -P Default
_FFConnect: OS: WIN_XP WIN32_NT 2600 Service Pack 3
_FFConnect: AutoIt: 3.3.0.0
_FFConnect: FF.au3: 0.6.0.0b-5
_FFConnect: IP: 127.0.0.1
_FFConnect: Port:   4242
_FFConnect: Delay:  2ms
_FFConnect: Socket:     1700
__FFSend: try{window.content.top.document.browserDOMWindow}catch(e){'_FFCmd_Err';};
__FFRecv: 
__FFSend: try{navigator.userAgent}catch(e){'_FFCmd_Err';};
__FFRecv: Mozilla/5.0 (Windows; U; Windows NT 5.1; vi; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5
_FFConnect: Browser:    Mozilla/5.0 (Windows; U; Windows NT 5.1; vi; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5
__FFSendJavascripts: Sending functions to FireFox .......... done
_FFLoadWait: ................... loaded in 4855ms
>Exit code: 0    Time: 11.380

Nothing change , I've habit write full code and my English is very bad.So i test it on vdict site .With any iframe , I don't care

What should your script do on a page without frames and no more other functions?

#include <FF.au3>
_FFStart("http://vdict.com/")
sleep (2000)
_FFFrameEnter(4)

Try this:

#region Includes
#include <FF.au3>
#endregion Includes

If _FFConnect() Then
    If _FFOpenURL("http://www.autoit.de") Then
        _FFFrameEnter(2)
        MsgBox(0,"Frame 2 URL", _FFCmd(".location.href") )
        _FFFrameLeave()
        MsgBox(0,"Top URL",_FFCmd(".location.href") )
    EndIf
EndIf

then can you see that it works.

  • 2 weeks later...
Posted (edited)

Is there any way to make a list of URLs (and possibly titles) of all open tabs using this UDF? Or any other way?

With the function _FF_TabGetAllURLs in FFEx.au3 you get an array with the URLs of all open tabs.

For titles:

Func _FF_TabGetAllTitles()
    Return StringSplit(_FFCmd("FFau3.tmp='';for(i=0;i<gBrowser.tabContainer.childNodes.length-1;i++){FFau3.tmp+=gBrowser.getBrowserAtIndex(i).contentdocument.title+'|'}FFau3.tmp+gBrowser.getBrowserAtIndex(i++).contentdocument.title;"), "|")
EndFunc   ;==>_FF_TabGetAllTitles
Edited by Stilgar
Posted

With the function _FF_TabGetAllURLs in FFEx.au3 you get an array with the URLs of all open tabs.

For titles:

Func _FF_TabGetAllTitles()
    Return StringSplit(_FFCmd("FFau3.tmp='';for(i=0;i<gBrowser.tabContainer.childNodes.length-1;i++){FFau3.tmp+=gBrowser.getBrowserAtIndex(i).contentdocument.title+'|'}FFau3.tmp+gBrowser.getBrowserAtIndex(i++).contentdocument.title;"), "|")
EndFunc   ;==>_FF_TabGetAllTitles

_FF_GetAllURLs() doesn't seem to return anything. The tab add-on I have installed (Tab Kit) might be causing problems with it. Can you think of any way around this, or any other way of doing it?

Thanks,

Zach

Posted (edited)

_FF_GetAllURLs() doesn't seem to return anything. The tab add-on I have installed (Tab Kit) might be causing problems with it. Can you think of any way around this, or any other way of doing it?

Thanks,

Zach

Just use the functions in the FF.au3:

#include <Array.au3>
#include <FF.au3>

Main()

Func Main()
    If _FFConnect() Then
        Local $a = _TabURLs()
        _ArrayDisplay($a)
    EndIf
EndFunc   ;==>Main

Func _TabURLs()
    Local $iC = _FFTabGetSelected()
    Local $iT = _FFGetLength("tabs")
    Local $aURLs[$iT]
    For $i = 0 To $iT - 1
        _FFTabSetSelected($i)
        $aURLs[$i] = _FFCmd(".location.href")
    Next
    _FFTabSetSelected($iC)
    Return $aURLs
EndFunc   ;==>_TabURLs
Edited by Stilgar
Posted

I've the HTML script like this :

<tr valign="center"><td width="100%">
                  <div id="div__4668003_0">
                <table border="0" cellpadding="0" cellspacing="0" width="100%">
                  <tr>
                      <td valign="middle" width="5%">
                      <input name="cg__4668003" type="radio"
                      
                        value="0" />
                    </td>
                    <td class="radiolist" width="95%">
                        <span class="style4668003">Yes</span>
                    </td>
                  </tr>
                </table>
                </div>
            </td></tr>

Plz, Help me use _FFFormRadioButton for this .

And Use _FFFormCheckBox for that one .

<tr valign="center"><td width="100%">
                  <div id="div__4668004_0">
                  <table border="0" cellpadding="0" cellspacing="0" width="100%">
                    <tr>
                      <td valign="middle" width="5">
                        <input name="cg__4668004" type="checkbox"
                        
                          value="1"
                          />
                      </td>
                      <td class="checklist" width="275">
                        <span class="style4668004">Adhesive Bandages</span>
                      </td>
                    </tr>
                  </table>
                  </div>
                </td></tr>

Thx

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...