Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

149
Views
Por qué el estado de XMLHttpRequest es 0

mi guión de fondo.js:

 let portFromCS; function connected(p) { portFromCS = p; // portFromCS.postMessage({greeting: "hi there content script!"}); portFromCS.onMessage.addListener(function(m) { portFromCS.postMessage ({greeting: "In background script, received message from content script:" + m.greeting}); let xhr0 = new XMLHttpRequest(); xhr0.open("GET", "http://127.0.0.1:7878/"+m.greeting); //ok xhr0.send(); let text = xhr0.status; xhr0 = new XMLHttpRequest(); xhr0.open("GET", "http://127.0.0.1:7878/return/"+text); xhr0.send(); }); } browser.runtime.onConnect.addListener(connected);

conectarme a mi servidor web,

devoluciones

 socket://127.0.0.1:52626 GET /Data also provided by socket://127.0.0.1:52636 GET /return/0

significa que uno xhr hace lo que quiero y el otro no

servidor: (escrito por rust + poema)

 #[handler] fn index_test(remote_addr: &RemoteAddr, method: Method, uri: &Uri) -> String { let uri = uri.to_string(); let uri = urlencoding::decode(uri.as_str()).unwrap(); let s0 = format!("{}\n{}\n{}",remote_addr,method,uri); println!("{}",s0); s0 }

captura de pantalla: abrir en el navegador

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!