BullGuard Antivirus Sale - 60% Off with openElement !
Forum Home Forum Home >

openElement

> Element Editor
  New Posts New Posts RSS Feed - How to embed other .js for offline using?
  FAQ FAQ  Forum Search   Register Register  Login Login

How to embed other .js for offline using?

 Post Reply Post Reply
Author
Message
djju1029 View Drop Down
Senior Member
Senior Member
Avatar

Joined: Aug 02 2016
Location: the US
Status: Offline
Points: 126
Post Options Post Options   Thanks (0) Thanks(0)   Quote djju1029 Quote  Post ReplyReply Direct Link To This Post Topic: How to embed other .js for offline using?
    Posted: Oct 12 2016 at 1:43pm
Dear OE team,

I want to use some other .js for offline using such as:
    jquery-ui 1.12.1
    jquery.mobile-1.4.5

How to embed these libraries into OE?

Thank you,

DJ
Back to Top
Dmit OE View Drop Down
Admin Group
Admin Group


Joined: May 31 2012
Status: Offline
Points: 5283
Post Options Post Options   Thanks (1) Thanks(1)   Quote Dmit OE Quote  Post ReplyReply Direct Link To This Post Posted: Oct 12 2016 at 3:52pm
Hi,

You can include JS files using a Code Block (Source) type HTML or OtherCode, position Header or EndBody or other. I suggest to put the JS files into Files/Other for them to be automatically uploaded, then add the code in to the Block:

<script src="Files/Other/jquery-ui-1.12.1.js"></script>

Back to Top
djju1029 View Drop Down
Senior Member
Senior Member
Avatar

Joined: Aug 02 2016
Location: the US
Status: Offline
Points: 126
Post Options Post Options   Thanks (0) Thanks(0)   Quote djju1029 Quote  Post ReplyReply Direct Link To This Post Posted: Oct 13 2016 at 8:10pm
Hi,

In order to use the slider form, I put jquery.mobile.css and jquery.mobile.js into Other folder and add onto Header:
// example
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.css">
<script src="https://code.jquery.com/jquery-1.11.3.min.js"></script>
<script src="https://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.js"></script>

It works but I have two problem.

1) After putting jquery.mobile, the javascript code of coping value from Range form to Text box form does not work anymore,

// example of the javascript code of coping value from Range form to Text box form
$('.Rrange  input').change(function(){
    $('.Rrange-mirror  input').val($(this).val()); // copy value from here to "mirror" field
}); // immediately run the code "on change"

2) After putting jquery.mobile.css, text box elements became bigger than before using.
Therefore, layout was broken.

How can I resolve these issuess?

Thank you in advance!!

DJ

Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.063 seconds.