mirror of
https://github.com/jquery/jquery-ui.git
synced 2026-02-16 05:55:21 -05:00
demos: view source should show the actual full source, not just the javascript
This commit is contained in:
@@ -153,7 +153,7 @@
|
||||
function loadDemo(path) {
|
||||
var directory = path.match(/([^\/]+)\/[^\/\.]+\.html$/)[1];
|
||||
$.get(path, function(data) {
|
||||
var source = data.match(/<script.*>.*<\/script>/ig)[1];
|
||||
var source = data;
|
||||
data = data.replace(/<script.*>.*<\/script>/ig,""); // Remove script tags
|
||||
data = data.replace(/<\/?link.*>/ig,""); //Remove link tags
|
||||
data = data.replace(/<\/?html.*>/ig,""); //Remove html tag
|
||||
|
||||
Reference in New Issue
Block a user