MCPcopy Index your code
hub / github.com/XIU2/UserScript / getNextF

Function getNextF

Autopage.user.js:2237–2245  ·  view source on GitHub ↗
(css)

Source from the content-addressed store, hash-verified

2235 }
2236 // 通用型获取下一页地址(从 form input 中获取,返回 GET URL)
2237 function getNextF(css) {
2238 let form = getOne(css), value = '';
2239 if (form) {
2240 form.querySelectorAll('input[name]').forEach(function(input) {value += input.name + '=' + input.value + '&';}) // 生成表单参数
2241 value = encodeURI(value.replace(/&$/,'')); // 清理最后一个 & 符号
2242 if (form.action && value) return (form.action + '?' + value)
2243 }
2244 return '';
2245 }
2246
2247
2248 // 检查 URL

Callers

nothing calls this directly

Calls 1

getOneFunction · 0.85

Tested by

no test coverage detected