GithubHelp home page GithubHelp logo

Comments (7)

mgol avatar mgol commented on June 22, 2024 1

I think it's about the demos. E.g. the page https://jqueryui.com/draggable/ loads the URL https://jqueryui.com/resources/demos/draggable/default.html in an iframe and that one uses protocol-relative URLs as mentioned above.

While those URLs are valid, in 2023 it makes sense to just use HTTPS everywhere.

I'm not sure where exactly this is defined, though.

from jqueryui.com.

mgol avatar mgol commented on June 22, 2024 1

It looks like it may be defined here:

jqueryui.com/Gruntfile.js

Lines 221 to 223 in 1d19439

source = source.replace(
/<link rel="stylesheet" href="\.\.\/\.\.\/themes[^>]+>/,
"<link rel=\"stylesheet\" href=\"//code.jquery.com/ui/" + pkg.version + "/themes/base/jquery-ui.css\">" );
. PRs welcome.

from jqueryui.com.

dmethvin avatar dmethvin commented on June 22, 2024

When the protocol is missing, it should take the protocol of whatever page it's used in. Do you have a link to a page where it isn't working? What does devtools show you on the network panel?

from jqueryui.com.

WarriorofZarona avatar WarriorofZarona commented on June 22, 2024

It's just part of the view source example code. Note that this is the only place where it is missing, the cdn's for the other links and scripts are written correctly.

In draggable:

<!doctype html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <title>jQuery UI Draggable - Default functionality</title>
  <link rel="stylesheet" href="//code.jquery.com/ui/1.13.2/themes/base/jquery-ui.css">
  <link rel="stylesheet" href="/resources/demos/style.css">
  <style>
  #draggable { width: 150px; height: 150px; padding: 0.5em; }
  </style>
  <script src="https://code.jquery.com/jquery-3.6.0.js"></script>
  <script src="https://code.jquery.com/ui/1.13.2/jquery-ui.js"></script>
  <script>
  $( function() {
    $( "#draggable" ).draggable();
  } );
  </script>
</head>
<body>
 
<div id="draggable" class="ui-widget-content">
  <p>Drag me around</p>
</div>
 
 
</body>
</html>

from jqueryui.com.

markvantilburg avatar markvantilburg commented on June 22, 2024

If you open the file locally it will put file:// there and as such will not load the css file.

from jqueryui.com.

dmethvin avatar dmethvin commented on June 22, 2024

Where is the "view source example code"? Do you have a link to it? There are a lot of pages and I'm still not sure which page it is based on the description above.

from jqueryui.com.

mgol avatar mgol commented on June 22, 2024

I transferred the issue to the correct repository.

from jqueryui.com.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.