Document processing of jquery
1. Internal insertion
append(content|fn) after appending the content of the current element
appendTo(content) and append are reversed
prepend(content|fn) is appended before the content of the current element
prependTo(content)
$(".block").append($(".small"));
$(".block").append(function (index,html) ...
Posted by trystan on Thu, 13 Feb 2020 23:16:25 -0800
jquer event bubbling
What is event bubbling?
Initialize the page first, and the page code is as follows:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title></title>
</head>
<style>
*{
margin: 0;
padding: 0;
}
#content{
background: #ccc;
}
#content span{
background: yellow;
margin: 5px ...
Posted by Cetanu on Thu, 13 Feb 2020 09:10:31 -0800
Drag elements freely for free sorting
Last issue we used jquery to sort by moving elements up and down, but we found that moving up and down, while sorting is possible, is not flexible, rigid, and fast enough to achieve the purpose we want to sort.Let's show you how to quickly drag to the sort position you want.
First, we'll introduce a plug-in, gridly.js, for element dragging.
...
Posted by parse-error on Wed, 12 Feb 2020 08:55:44 -0800
Dynamic load user menu
The process is that the user enters the module page after logging in, clicks on different modules, and enters the menu page (different modules, different menu contents)
Problems encountered
1. The menu data is stored in the store and the page is blank after refreshing
Solution: initialize the menu every time in the global navigation guard ...
Posted by vandalite on Wed, 12 Feb 2020 07:16:43 -0800
ArcGIS api for javascript accesses server's security services by registering token with IdentityManager
Available environment: A stand-alone server environment that is not federated with a portal.Enprise Environment Access Security Services see two other articleshttps://blog.csdn.net/qq_40376439/article/details/104227280https://blog.csdn.net/qq_40376439/article/details/104217511Scenario for use: When we p ...
Posted by manyamile on Tue, 11 Feb 2020 18:08:44 -0800
Django+Paginator+ajax dynamic load paging
How to switch pages without refreshing the whole page?
In fact, the implementation is very simple. The idea is: how many pages are the Paginator backend split (for example: how many pages in total; how many pages are the current page; what is the content of this page?) , through Ajax interactive data display.
Two core objects of Paginator (Pagi ...
Posted by retoto on Mon, 10 Feb 2020 06:56:11 -0800
Download files through jQuery.Ajax
I have a struts 2 operation on the server side for file download.
<action name="download" class="com.xxx.DownAction">
<result name="success" type="stream">
<param name="contentType">text/plain</param>
<param name="inputName">imageStream</param>
<param name="contentDisposition ...
Posted by Greaser9780 on Mon, 10 Feb 2020 03:04:08 -0800
jQuery animation loop with timer
When we need to play multiple jQuery animations, and need to play them in cycles many times, but there are functions similar to setTimeout in the cycles,
We found that functions such as for, while cannot be used.
At this time, we can encapsulate animation into a function. The details are as follows:
1.html
<div class="im ...
Posted by bing_crosby on Sun, 09 Feb 2020 10:20:20 -0800
spring boot+layui paging practice
The project uses layui to make a simple book search page and share it.
Like friends give a little like!!!
Realization effect
Development steps
1. Front page and JS
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">
<head>
...
Posted by woobarb on Fri, 07 Feb 2020 07:02:38 -0800
Getting started with javaScript
Getting started with javaScript
Article directory
Getting started with javaScript
1, Basic grammar
What can I do
Notes
Identifier, literal quantity and variable naming specification
data type
Data type conversion, operator
2, Common methods of string and array
Character method
Array method
3, ...
Posted by mahaguru on Wed, 05 Feb 2020 04:37:29 -0800