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

381
Views
ajax POST, tratando de agregar el enlace del directorio agrega la ruta dos veces
 $.ajax({ type: "POST", url: "/bbr-category-configuration", data: "category_data", dataType: "json", success: function (response){ console.log(response); } });

estoy probando mi formulario ajax en una consola.log

1

dice 404 no encontrado, pero pensé que estaba bien, me perdí la ruta completa, así que agregué:

 url: "clinical/bbr-category-configuration",

Esta vez, la ruta pasa dos veces por mi carpeta clinical , como se ve en la siguiente captura de pantalla.

2

¿Cómo está pasando esto? (el directorio se agrega dos veces)

over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

Lo que está definiendo es la ruta absoluta y relativa de la url.

En un archivo JS o html, si redirige/solicita a cualquier URL con /urlPath , su redirección/solicitud será desde la URL base ( http://example.com/urlPath ) en adelante.

Puede ver este comportamiento con un elemento de anclaje simple. Simplemente colóquelos en el archivo html y verá el resultado.

 <a href="clinical/bbr-category-configuration">Redirects from the current path</a> <a href="/clinical/bbr-category-configuration">Redirects from the base url path</a>

La configuración de categoría clínica/bbr anterior redirigirá/solicitará desde su URL actual. si está en https://example.com/url/url2 , irá ahttps://example.com/url/clinical/bbr-category-configuration

Entonces, en su caso, debe usar /clinical/bbr-category-configuration como lo menciona @ Aless55

over 4 years ago · Santiago Trujillo Report
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!