Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8898859
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T00:43:04+00:00 2026-06-15T00:43:04+00:00

EDIT: While the original problem is solved, the code fails to actually do anything.

  • 0

EDIT: While the original problem is solved, the code fails to actually do anything. Tested in Chrome, it inserts ‘hi’ into the password box. In Spynner it simply loads the page.

I’m attempting to use Spynner to scrape a website my school uses to provide online timetables.
For some reason, I always get the following error:

Run Javascript code: jq("[class^=login-text-box]").val("hi")
Javascript console: ReferenceError: Can't find variable: jq

This is caused by the following code:

import spynner

browser = spynner.Browser()
browser.debug_level = 3;
browser.show()
browser.load("http://web.edval.com.au/#publicaccess")
browser.runjs('_jQuery("[class^=login-text-box]").val("hi")')
browser.close()

I have also tried:

import spynner

browser = spynner.Browser()
browser.debug_level = 3;
browser.jslib = 'jq'
browser.show()
browser.load("http://web.edval.com.au/#publicaccess")
browser.runjs('jq("[class^=login-text-box]").val("hi")')
browser.close()

with an equal lack of success. Pasting the JavaScript command into Chrome’s JS Console (after I’ve injected jQuery) works perfectly.

Please could someone offer some assistance?

Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T00:43:06+00:00Added an answer on June 15, 2026 at 12:43 am

    Never mind, even though the docs said jQuery would be loaded as _jQuery, it was actually loaded as $. I fixed it by changing my code to:

    import spynner
    
    browser = spynner.Browser()
    browser.load_jquery(True)
    browser.debug_level = 3;
    browser.show()
    browser.load("http://web.edval.com.au/#publicaccess")
    browser.runjs(browser.jslib+'("[class^=login-text-box]").val("hi")')
    browser.close()
    

    Note that runjs now actually checks browser.jslib.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Edit: Simple code I used to solve the problem in case anyone is interested
While troubleshooting some cryptographic code, I saw a strange hierarchy of stacktraces. I've solved
I've run into a problem while compiling a package around, I am not really
G'day, Edit: While this question covers a situation that can arise in programming a
EDIT SO I figured out a fix. I replaced the while statement with an
I've recently upgraded to Komodo Edit 7 from 6.1, and while the upgrade has
Edit 1 begins The behaviour of the original post applies only to Windows XP
EDIT: I was missing a key concept, the message queue, while creating my custom
Edit: My original title has been sort of changed. I suspect the current title
Edit : Simpler repro case; the following code: setInterval(function(){ var a=[10,20,30,40], i=-1; a[-1] =

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.