Show More Tags:  MORE

Firebase onTokenRefresh() is not called

In my MainActivityin my log, I can see the token using FirebaseInstanceId.getInstance().getToken() and it display the generated token. But it seems like in my MyFirebaseInstanceIDService where it is extends to FirebaseInstanceIdService, the onTokenRefresh() is not called, where in this function it


How to add field in registration form in prestashop 1.7?

In my Prestashop I need not add some field in registration form. I tried in authentication.tpl and registration.tpl but not find any hint to add new field.Thanks in advance. You may start digging in classes/form/CustomerFormatter.php under getFormat() method. There is an array of fields for the r


Optional argument in sh script

I wonder if there is any way to execute script with argument that can be optional. For example./script (optional parameter X) pathSo typing ./script /Users/name/Documents would execute certain function (I assume that if statement will be crucial) and ./script X Users/mcichecki/Documents will execute


How to drag/drop to multiple Angular2 component using ng2-dragula

I have a Angular2 component using ng2-dragula to drag/drop like this:@Component({ selector: 'my-comp', directives: [ Dragula ], viewProviders: [ DragulaService ], template: ` <div class="my-div"> <div *ngFor="#item of items" [dragula]='"card-bag"' [dragulaModel]='items'&


Python: urllib2.URLError: <urlopen error [Errno 10060]

I have some problem with reading some urls.I try to use answer from this question Using an HTTP PROXY - Python but it didn't help and I get an error urllib2.URLError: <urlopen error [Errno 10060]I have a list of urlyandex.ru/search?text=авито&lr=47yandex.ru/search?text=цветок%20киддиленд%20м


Angular2 Google Maps style marker

We are working with Angular2 Google Maps (https://angular-maps.com/)I've gotten the Styled Google Maps to work already with this Plunkr:https://plnkr.co/edit/rv6udUOEedMxJejEpIW1import { Directive } from '@angular/core';import { GoogleMapsAPIWrapper } from 'angular2-google-maps/core';@Directive({ s


Tomcat 404 error: The origin server did not find a current representation for the target resource or is not willing to disclose that one exists

This question already has an answer here: Servlet returns “HTTP Status 404 The requested resource (/servlet) is not available” 2 answers Problem solved, I've not added the index.html. Which is point


Error 405 (Method Not Allowed) Laravel 5

Im trying to do a POST request with jQuery but im getting a error 405 (Method Not Allowed), Im working with Laravel 5THis is my code:jQuery<script type="text/javascript"> $(document).ready(function () { $('.delete').click(function (e){ e.preventDefault(); var ro


Datatables: Cannot read property 'mData' of undefined

I have a issue with Datatables. I also went through this link which didnt yield me any result.I have inlcuded all the prerequisites where am parsing data directly into the DOM. Kindly help me to fix this issue. Script$(document).ready(function() { $('.viewCentricPage .teamCentric').dataTable({ "


Display p:fileupload image in p:graphicImage preview without saving it

I am using PrimeFaces 5.3 <p:fileUpload> to upload a PNG image and I would like to show a preview of it in <p:graphicImage> before saving in database.Here's a MCVE:<h:form enctype="multipart/form-data"> <p:fileUpload value="#{bean.uploadedFile}" mode="simple" /> <p:g


How to check if a specified key exists in a given S3 bucket using Java

I would like to check if a key exists in a given bucket using Java. I looked at the API but there aren't any methods that are useful. I tried to use getObject but it threw an exception. Use the jets3t library. Its a lot more easier and robust than the AWS sdk. Using this library you can call, s3s


ReflectionException - Class DatabaseSeeder does not exist , Laravel Seeder

I have database seeder clases in diferent folder. When i write db:seed the console shows this error:[ReflectionException] Class DatabaseSeeder does not exist , Laravel SeederOne class is this:namespace Database\Seeds;use Illuminate\Support\Facades\DB;use Illuminate\Database\Seeder;use Illuminate\D


"Can't resolve all parameters for MdDialogRef: (?)" Error when testing NG2 Material Dialog component

I have a login component as follows: import { Component, OnInit } from '@angular/core';import { MdDialogRef } from '@angular/material';import { AuthService } from '../../core/services/auth.service';@Component({ templateUrl: './login.component.html', styleUrls: ['./login.component.scss']})export cl


changingThisBreaksApplicationSecurity angular2

Iam trying to load a pdf document in an tag in angular2 Dynamically, and when i am tring to change the URL iths throwing an error saying SafeResourceUrlImplchangingThisBreaksApplicationSecurity: "localhost:8002/pdf.pdf"proto: SafeValueImplconstructor: SafeResourceUrlImpl()getTypeName: ()proto:


Can't bind to 'routerLink' since it isn't a known property of 'a'

This question already has an answer here: Angular2 Exception: Can't bind to 'routerLink' since it isn't a known native property 9 answers The problem is that you forgot to add RouterModule to you





Cordova not adding capabilities to appxmanifest file

I'm using Visual Studio 2015 (Update 2) to build an app using Apache Cordova. This app uses the cordova-plugin-media plugin for recording audio. However, when I try to record audio, I get this error: Access is denied.Looking at the generated package.windows10.appxmanifest file in \platforms\windows,


rpivotTable on shiny server not working

I am trying to run a shiny app including a rpivottable.my config:devtools 1.8.0, htmlwidgets 0.4.2, rpivotTable 0.1.4.1, shiny 0.12.0R version 3.1.2 (2014-10-31)Ubuntu 14.04.1 LTSMy code works perfectly locally, but crash on the server. On the browser, I get this error on the console:TypeError: x is


How to Count Select options in Protractor?

I want to count options in select attribute but my test gets failed here is my spec:it('should count the number of option', function()) { expect(element(by.id('sorting_options')).all(by.tagName('option').count())).toBe(3);}it give me Error: C:\wamp\www\First-angular-App>protractor conf.js Starting


Localise Application for English and Arabic Language without restarting app

I want to localise application for two languages one is LTR & Another is RTL without restarting application.class func changeLanguageForceFully(currLan : String){ let langCultureCode: String = currLan let defaults = NSUserDefaults.standardUserDefaults() defaults.setObject([l


How to get the class and method name which caused the crash?

When app crashes I am getting below stack in my debug console.( 0 CoreFoundation 0x000000010811434b __exceptionPreprocess + 171 1 libobjc.A.dylib 0x0000000107b4821e objc_exception_throw + 48 2 CoreFoundation 0x000000010816c


Spring Oauth server with custom login page

I am trying to create Oauth server with spring security and I am new to both of them. The flow is, when I browse the following URL http://localhost:8080/OAuthServer/oauth/authorize?response_type=code&redirect_uri=http://localhost:8080/client/handler&client_id=testProblem 1 :I am being redire


How to read the values of attributes in Apache NiFi

I'm working on a sample NiFi flow where I get a Json file as input. I use EvaluateJsonPath processor to get the value of the desired path. I've set the destination of EvaluateJsonPath as "flow-file attribute" and I added new properties with the required JsonPath. For ex: Property name: username, val


RabbitListener returning String as ASCII instead of String

For some reason RabbitListener is showing the ASCII representation instead of actual string Rabbit MQ Message Exchange raw-cdr Routing Key uk Redelivered priority: 0 delivery_mode: 2 headers: file_name: /Users/shahbour/IdeaProjects/micro-services/file-sftp-serv


C error " incomplete universal character name \u"

I am having trouble with this error. Note that im a bit new to c programming and im not that familliar with the casual error.This is my error: incomplete universal character name \uand this is my code(part of it):while( (ch=getchar())!=EOF ){ ++caractere; switch(ch) { case '\n'


Watson iOS SDK (Swift) and passing context variable to Conversation

I am attempting to pass a context variable at the start of a conversation from my iOS Swift application to the Watson Conversation service. So far I have figured out you have to import RestKit to create the JSON object required and use the Context initializer. Below is a sample of the code I have


How do I wait for another response listener to complete in android volley?

Is it possible to synchronise two volley requests so that one listener will always be executed after the other, regardless of the order their requests return in?I am making two calls to an external (owned/run by others) API, where the first call provides some data and the second adds some necessary


AttributeError: 'module' object has no attribute 'xfeatures2d' [Python/OpenCV 2.4]

This line:sift = cv2.xfeatures2d.SIFT_create()return error:Traceback (most recent call last): File "C:/Python27/openCVskrypty/GUI/SOLUTION2.py", line 11, in <module> sift = cv2.xfeatures2d.SIFT_create()AttributeError: 'module' object has no attribute 'xfeatures2d'I read something about thi


django allauth empty username causes duplicate key in postgress DB

Django 1.8.16django-allauth 0.27.0Using postgres as database.My application does not use usernames, only e-mail addresses as user id.So I use following settings:ACCOUNT_AUTHENTICATION_METHOD = 'email'ACCOUNT_USERNAME_REQUIRED = FalseACCOUNT_EMAIL_REQUIRED = TrueACCOUNT_UNIQUE_EMAIL = TrueACCOUNT_EM


get the names of elements in a complex type(choice) from xml file

My xml file; <?xml version="1.0" encoding="UTF-8"?><tns:military xmlns:tns="Military.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="Military.xsd Military.xsd "> <personel sicilNo="0" title="Bay"> <militaryP> <cl


Using CUDA 8.0 with GCC 6.x - bad function overloading complaint

I'm trying to build some CUDA code using GCC 6.2.1, the default compiler of my distribution (Note: not a GCC version officially supported by CUDA, so you can call this experimental). This is code which builds fine with GCC 4.9.3 and both CUDA versions 7.5 and 8.0.Well, if I build the following (clos


DeveloperSite