PageSourceSearch

https://lookdiary.com.hk/merchant/js/login.js

js lookdiary.com.hk collected 2026-10-04 19:35:54 UTC 1,066 bytes, 41 lines download raw bytes

1//var localurl = "http://localhost/work/public_html/dev/";
2var localurl = "https://"+window.location.hostname+"/";
3
4
5function login_user(refresh_page=true, post_ajax_function=false)
6{
7 		data={
8			username: $("#form-sign-in-email")[0].value,
9			password: $("#form-sign-in-password")[0].value
10			};
11		$.ajax({
12			method:"POST",
13			url:"user/login",
14			data:data,
15			success: function(r,s,x){
16				//console.log(r);
17 				var obj=$.parseJSON(r);
18				//console.log(obj);
19				//print_r(obj);
20 				if(obj.status==1)
21				{
22                    if(refresh_page) {
23						var loc = window.location.href;
24     					if(obj.last=='booking'){
25     						window.location.replace(localurl+""+obj.last);
26     					} else if (loc.indexOf('booking') != -1 ) {
27    						window.location.replace(loc);
28    					} else{
29     						window.location.replace(localurl+"profile");
30    					}
31					} else {
32						if(post_ajax_function != false && typeof post_ajax_function == "function") {
33							post_ajax_function();
34						}
35					}
36 				}
37				else
38					alert("Error, " +obj.msg);
39			}
40		});
41};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.