Posts

charts - HighCharts gauge big figure and congested percentage issues -

Image
i having follow issues in highchart gauges: sales revenue gauges not start ranges have assigned check sales/revenue block, ranges provide gauge is: 511721.61 604761.90 604761.91 744322.34 744322.35 1116483.52 another issue in profit percentage block, ranges closely bound. not good, ranges are, 40.01 41.87 41.88 44.19 44.20 46.52 third issue if dialer figure exceeding range values, needle circles on dialer again , stops on wrong figure, want if needle should not recircle , stop on end of green end. https://jsfiddle.net/9mcw95bf/1/ [https://jsfiddle.net/9mcw95bf/1/][2]

html - Why is my footer at the top of my page? -

firstly, used #copyright { position: fixed; bottom: 0; left: 0; right: 0; height: 50px } footer { position: fixed; bottom: 50px; left: 0; right: 0; } which worked fine until tested site on smaller screen , realised footers overlapping content. tried setting html , body height 100% , setting wrapper min height 100% , placing footer underneath, in hopes of more relative footer. stuck @ top, causing ? #wrapper { display: block; position: fixed; text-align: center; min-height: 100%; width: 100%; top: 0; bottom: 0; left: 0; right: 0; } #header p { font-size: 2em; margin: 0; } #header ul { list-style-type: none; } #header ul li { display: inline; padding: 20px 20px; font-size: 1.5em; margin: 0 30px; } #copyright { position: relative; height: 50px; width: 100%; text-align: center; font-size: 0.8em; } #footer { position: relative; margin-top: 15px; height: 50px; width: 100%; text-ali...

jquery - Using 3rd party json data in django -

i have live monitoring data tool called prtg via api want build django site brings in real time reporting along other dashboards have created. i'm stuck @ first step of bring in api data display on page. the api data this: {"prtg-version": "14.1.8.1371", "treesize": 381, "sensors": [ { "objid": 1001, "probe": "newname", "group": "newname", "device": "br-s-log", "sensor": "system health", "status": "up", "status_raw": 3, "message": "<div class=\"status\">ok<div class=\"moreicon\"></div></div>", "message_raw": "ok", "lastvalue": "100 %", "lastvalue_raw": 100.0000, "priority": 5 }, { "objid": 1002, "probe": "newname", "group...

How to convert an array into an array object in javascript? -

my scenario upload text file contain data this a1,b1,,c1,d1, a2,b2,,c2,d2, from data, able read , split ("\n") , result is array=[array[0]:[a1,b1,,c1,d1] array[1]:[a2,b2,,c2,d2]] how can populate array above array object? sample output: newarray=[[name="a1",age:"b2",address="",contact="c1",gender="d1"], [name="a2",age:"b2",address="",contact="c2",gender="d2"]] as position of each attribute in array seems fixed, create function fixed assignment. this: var str = "a1,b1,,c1,d1,\na2,b2,,c2,d2,"; var objects = parsestring(str); console.log(objects); function parsestring(strin){ var objectlist = []; var splitresult = strin.split("\n"); for(var i=0;i<splitresult.length;i++){ var valuearray = splitresult[0].split(","); objectlist.push(maptoobject(valuearray)); } return objec...

jquery - How to align a rotating wheel to stop in center position not random position using javascripts? -

i trying create wheel on wordpress using javascript. have done making wheel , it's spinning randomly after click , stopping on random position. i edit wheel function, stop on center position of each part of wheel. also, wheel not stop , repeat section again. in each click spin wheel stop in new section. , stop in center position of wheel. possible? here have used spin wheel on wordpress <img src="elevatingpolitics.com/wp-content/uploads/2016/10/ep-wheel.png" alt="" usemap="#linkwheel" width="500" height="auto" style=""> var img = document.queryselector('img'); img.addeventlistener('click', onclick, false); function onclick() { this.removeattribute('style'); var deg = 1500 + math.round(math.random() * 1500); var css = '-webkit-transform: rotate(' + deg + 'deg);'; this.setattribute( 'style', css ); } here wheel image section...

typescript - Angular 2: Observable not returning the object (nested) from service -

i have angular service returns user object. user object has own attributes plus array of walls. service returns observable calling component. in service, able create user object json returned http service. however, when subscribe service in component, object returned null. doing wrong here? // user.ts import { wall } './wall'; export class user { id: number; entrytype: number; usertype: number; subscriptiontype: number; iscoach: boolean; username: string; email: string; name: string; password: string; created: string; memberwalls: wall[]; } //wall.ts export class wall { title: string; viewitem_id: number; } //authentication.service.ts authenticate(authrequest: login): observable<user> { let url: string = this.apiurl + appsettings.login_service; let headers = new headers({ 'content-type': appsettings.content_type_header, //'; charset=utf-8', 'client-...

vue.js - How to use eslint autofix in .vue? -

i want use autofix in .vue file, eslint show errors, no autofix. how configure .eslintrc make work? it not work. had same issue , asked question here (surprised haven't found it). asked them on github , answer still not came solution use fix plugins (vue-loader). eslint , vuejs files. throwing errors not fixing them here thread on github of eslint: https://github.com/eslint/eslint/issues/7456#issuecomment-256757117 hope helps.