Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Eric Marchand
    @phimage
    I create it for fun and to test OAuthSwift by making some automatic oauth authentication unit tests https://github.com/dongri/OAuthSwift/blob/master/OAuthSwiftTests/ServicesTests.swift
    Let me know if you use it (for unit testing or other things)
    Tamir Twina
    @TamirTwina
    Hi , i tried playing with Erik the other day and for some reason it only worked in Testing mode.
    Whenever i would trigger a visitURL i would get a success response with an empty html . Is it a known issue or i'm missing something ? Tried it with the plain google example as well
    Eric Marchand
    @phimage
    Hi, only using test scheme? I never try elsewhere than test target
    I will test, but I have, I think, no node that make difference between testing mode or other mode
    No code*
    Tamir Twina
    @TamirTwina
    Yeah, i've seen that .. but for some reason , running on a main target with the google example (or any other website) doesn't seem to populate the Document object with the url's content
    I tried with\without Futures
    And thanks for the quick response :smile: !
    Eric Marchand
    @phimage
    I can't test from now, in 6hours I will. The flow is : waiting for page loaded and execute JavaScript :" document.documentElement.outerHTML" to get html. Maybe page is not loaded yet! But webkit say it is...
    Tamir Twina
    @TamirTwina
    Cool, thanks !
    Eric Marchand
    @phimage
    I think I find the issue @TamirTwina, on IOS(and IOS simulator) webkit allow only HTTPS (on OSX and test no problem) : to by pass this security I find info here https://www.hackingwithswift.com/example-code/system/how-to-handle-the-https-requirements-in-ios-9-with-app-transport-security
    thanks for your feedback I will update readme about that
    Tamir Twina
    @TamirTwina
    My next guess was to check AST :)
    Cool , thanks !
    kehlawler
    @kehlawler
    Wondering if Erik supports downloading. I have a website that when I press a button it downloads an xml file for me to use. Updating the form and doing the click work great with Erik but I need a way to get the downloaded content - any ideas? I love Erik due to it's simplicity and low overhead and that's the only function I don't see any way to accomplish.
    Eric Marchand
    @phimage
    Pleasee don't write
    Eric Marchand
    @phimage
    This message was deleted
    Eric Marchand
    @phimage
    Please don't read previous message. When you click on download button, what happened? javascript download? redirection on a file?
    you can use any network code or library like alamofire if you can obtain the url after the click
    kehlawler
    @kehlawler
    Thanks for the quick replay. I'm quite new to javascript so please bare with me - when you hit the download button it creates a file based on what you've checked off on the site and downloads it (it's not my website). In my test program showing the web view the file shows up on my device screen but I have no idea how to get that content. The html in question is as follows:
    <div id="ctl00_ContentBody_uxDownload" onkeypress="javascript:return WebForm_FireDefaultButton(event, 'ctl00_ContentBody_uxDownload')">

    <p>
    <input name="ctl00$ContentBody$chkAll" type="button" id="chkAll" onclick="this.value = check(this.form.CID)" value="Uncheck All" data-uncheck="Uncheck All" data-check="Check All">
    </p>
    <input id="Download" type="submit" value="Download" name="Download" clientidmode="Static">
    </p>

    </div>
    When I do a 'click' using Erik on the 'Download' id I get my results
    Sorry I keep hitting return which starts a new message ... I would imagine the file is either temporary or streamed using javascript as they wouldn't be kept around.
    Eric Marchand
    @phimage
    ok if "streamed" ie. file with special header which force download, I don't know how to do it . Current webkit version do not allow to implement download delegate
    if the file created is opened in webview then you can try "currentContent"
    but I think this will not work because your file is not an html document...
    kehlawler
    @kehlawler
    I tried 'currentContent' and even though that is what is showing in the web view I still get the original page.
    It must have opened a separate page - thanks for your insight and your time
    Eric Marchand
    @phimage
    yes you must have right. unfortunately I have not access to a mac computer and do some tests to help you.
    kehlawler
    @kehlawler
    no worries - just realized I didn't get exactly the file data on the web view but the 'http gets' to create it so I may be able to work with that - thanks again
    Timothy Obiso
    @TimmyO18
    Hey, I'm trying to run my app but whenever I try to build i get 'libxml/xmlversion.h' file not found
    Timothy Obiso
    @TimmyO18
    nvm i got it to work by manually adding Kanna in the Podfile at 1.02
    Timothy Obiso
    @TimmyO18
    is there any way to press a button with Erik?
    Eric Marchand
    @phimage
    Query select the element button and call click m├ęthode
    Timothy Obiso
    @TimmyO18
    is there anyway to have javascript enabled because the website I'm trying to sign into requires javascript to be enabled to run it
    Eric Marchand
    @phimage
    JavaScript is enabled, button click is down using JavaScript
    And see readme, there is a method to execute your own JavaScript
    Timothy Obiso
    @TimmyO18
    yeah i saw that but when i do fill out all the necessary fields, and try to submit the form, the onsubmit javascript for the form doesn't run the webpage is https://ps01.bergen.org/public/
    Hugo Lundin
    @hugolundin
    Hi @phimage! I am trying to use Erik for parsing and submitting a form. It seems to work, but the form submission does not give any response at all. The currentContent does not change after submission, and I can't seem to find anything other to try. Any suggestions? :)