Posts

swift - Scores are not registered on the leaderboard of GameCenter -

i've got such log when score report leaderboard. <gkscore: 0xxxxxxxxxx>player:playerid:g:9999999999 alias:tester ajw rank:0 date:2017-03-28 08:31:26 +0000 value:1 formattedvalue:(null) context:0x0 leaderboard:testscore group:(null) the value seems sent, formattedvalue , group null. i've tried app on testflight, score never registered on leaderboard. shows "no scores". appdelegate.swift func application(_ application: uiapplication, didfinishlaunchingwithoptions launchoptions: [uiapplicationlaunchoptionskey: any]?) -> bool { // login check if let presentvc = window?.rootviewcontroller { let targetvc = presentvc let player = gklocalplayer.localplayer() player.authenticatehandler = {(viewcontroller, error) -> void in if ((viewcontroller) != nil) { print("login: faile") // login phase start targetvc.present(viewcontroller!, animated: true, comp...

jboss - Keycloak 'ExampleDS' in production -

i'm following guide set keycloak 3.0.0 in ha mode production oracle db. see in standalone-ha.xml file there's subsystem: <subsystem xmlns="urn:jboss:domain:ee:4.0"> at bottom of subsystem section there's <default-bindings> element refers exampleds datasource: <default-bindings context-service="java:jboss/ee/concurrency/context/default" datasource="java:jboss/datasources/exampleds" managed-executor-service="java:jboss/ee/concurrency/executor/default" managed-scheduled-executor-service="java:jboss/ee/concurrency/scheduler/default" managed-thread-factory="java:jboss/ee/concurrency/factory/default"/> exampleds declared use h2 driver, cannot use in production. can change <default-bindings> element refer oracle keycloakds datasource? you need add , configure oracle jdbc driver beforehand , add datasource needed keycloak. can follow example setup stated here . have seen...

PHP regex, skip <link> tags when rel="canonical" -

i run php script in wordpress removes http: , https: protocols links using following regex: $links = preg_replace( '/<input\b[^<]*\bvalue=[\"\']https?:\/\/(*skip)(*f)|https?:\/\//', '//', $links ); for first part: <input\b[^<]*\bvalue=[\"\']https?:\/\/(*skip)(*f) , skips <input> tags have http: / https: value, such as: <input type="url" value="http://example.com"> additionally, i'd skip <link> tags have rel="canonical" attribute: <link rel="canonical" href="http://example.com/remove-http/" /> using regex tester , i've been trying update logic. i've come far: <(input|link)\b[^<]*\(value|rel)=[\"\'](https?:\/\/|canonical)(*skip)(*f)|https?:\/\/ but hasn't worked me. the (*skip)(*f) verbs used discard text matched far , proceed search next match position regex index after matching text pattern before the...

javascript - LazyLoad on multiple elements with both default and non-default sources and attributes -

i using lazyload xt ( https://github.com/ressio/lazy-load-xt ) load default <img> s , it's working fine using $.extend($.lazyloadxt, { selector: 'img', srcattr: 'src' }); i using srcattr: 'src' due compatibility third party plugin requires default src . however, have several div s background-image lazy load. question is; how configure plugin target div fx .someclass lazy load background-image default attr data-bg ? i've tried several different variations seem cancel other 1 out. back-ground image work not <img> etc. furthermore have html5 video running lazy load default src instead of data-src . basically, know how define each element lazyload, based on fx class, , src attribute whether it's lazyload default or html default. for information have included plugin using bower , use both jquery.lazyloadxt.js , jquery.lazyloadxt.extra.js . sorry noob question, hope can help.

javascript - Getting contacts from ContactsApp Service for autocomplete using GAS -

Image
how code getcontacts() using apps script if i'll have use jquery autocomplete "multiple", fetch emails(email not phone or other details). it should return in such way if person has 2 email ids saved under single name, has added returning json array. example if person.a has pera1@gmail.com , pera1@yahoo.com list has be var emails = [ "person.a" <pera1@gmail.com>, "person.a" <pera1@yahoo.com>, ... ]; javascript emails = google.script.run.getcontacts(); $( function() { var availabletags = emails; function split( val ) { return val.split( /,\s*/ ); } function extractlast( term ) { return split( term ).pop(); } $( "#recipients" ) // don't navigate away field on tab when selecting item .on( "keydown", function( event ) { if ( event.keycode === $.ui.keycode.tab && $( ).autocomplete( "instance" ).menu.activ...

android - How to get the cursor on Editext of child item of the Recyclerview when the new item is added to it? -

i have recyclerview i'm adding child items on click of button dynamically. each child item has editext. when new child item been added recyclerview editetext of new item should focus. how can it? you can request focus inside adapter. something this: @override public void onbindviewholder(recyclerview.viewholder holder, final int position) { ((viewholder) holder).youredittext.requestfocus(); // set focus on edittext whenever child getting created }

handling multiple select values in ASP.net MVC with a service layer -

i have many multiple select dropdowns in asp.net mvc application , wondering best way handle transferring values viewmodel model saved database using ef6 (im using db first way create entities). 1 of viewmodels looks this public class someviewmodel{ public string[] selectedids public ienumerable<selectlistitem> selectvalues //other properties } i decided create partial model class , add selectedids like public partial class somemodel{ public string[] selectedids //other properties } my model passed service layer public class someservicelayer{ public int insertsomething(somemodel model){ //do stuff if (model.selectedids.length != 0){ model.selectvalues = _context.selectvalues .where(b => model.selectedids.contains(b.id.tostring())).tolist(); } } } it feels wrong have add custom property in partial class model. there better way of handling this? interest...