background-process

Beep not working when phonegap app is in background on iOS

假如想象 提交于 2020-01-13 03:36:07
问题 I’m working on the iOS version of my phonegap-based navigation app. My app tracks the user’s location around a walk route using GPS and alerts the user using audio (navigator.notification.beep) and tactile (navigator.notification.vibrate) feedback when they reach a location at which there’s new instructions for them to follow. When my app is running in the foreground, both the audible beep and the vibration fire on reaching the geographic location but when the app is paused in the background,

Sending a process to the background and returning control to my shell

≯℡__Kan透↙ 提交于 2020-01-12 03:33:07
问题 I am programming a shell for my CS class and part of the project involves running a process in the background if the '&' character is passed in by the user. If a process is run in the foreground, I simply execvp the process and it remains in control of the terminal since it is in the foreground. However, if it is a background process, I must return control to my main shell after starting the execution of the process. I understand that the system call tcsetpgrp(pid_t) places the process passed

i want to update my sqlite and firebase database every hour?

独自空忆成欢 提交于 2020-01-11 11:17:54
问题 I want to update my local sqlite and firebase database every hour. But I can't use the broadcast receiver as it was ban in android o. I can't use Job scheduler and work manager as it is a timebase application. I don't want to foreground service because it will use lots of resources and required to show a notification that I can't show. 来源: https://stackoverflow.com/questions/57826280/i-want-to-update-my-sqlite-and-firebase-database-every-hour

How do I pass session to new socket via fsockopen?

*爱你&永不变心* 提交于 2020-01-11 07:49:08
问题 I need to pass the session to an asynchronous call via fsockopen in php. Can you help me pass the session to the new socket? SOLUTION: The following code works. start.php <?php session_start(); $_SESSION['var1'] = 'value1'; async_call('/async.php'); echo '<pre>'; print_r($_SESSION); echo $_COOKIE['PHPSESSID'] . "\r\n"; echo '<a href="verify.php">verify.php</a>'; function async_call($filepath) { $host = 'sandbox'; // set to your domain $sock = fsockopen($host, 80); fwrite($sock, "GET $filepath

Background Process to scan the location of the user at regular intervals and update the local database even when the app is not open

杀马特。学长 韩版系。学妹 提交于 2020-01-11 02:23:37
问题 I am creating an app that checks for user locations every half an hour and updates the location of the user in the local database and then runs CRUD queries based on the user's location even when the app is not running. How do i do it ? I have referred to this http://techtej.blogspot.com.es/2011/03/android-thread-constructspart-4.html article and i am still confused about which is the correct approach for my result ? There are 4 options according to the article for what i intend to achieve

Background Process to scan the location of the user at regular intervals and update the local database even when the app is not open

删除回忆录丶 提交于 2020-01-11 02:23:05
问题 I am creating an app that checks for user locations every half an hour and updates the location of the user in the local database and then runs CRUD queries based on the user's location even when the app is not running. How do i do it ? I have referred to this http://techtej.blogspot.com.es/2011/03/android-thread-constructspart-4.html article and i am still confused about which is the correct approach for my result ? There are 4 options according to the article for what i intend to achieve

Running background services in iOS

拜拜、爱过 提交于 2020-01-09 06:42:31
问题 I need to code an iOS app that sends data to server every 30 minutes. Can this work when the app is in the background? How reliable it can be? 回答1: There is no way to perform tasks in the background permanently at the interval of time you are requesting. You may request specific permission via the developer connection but I must warn you that you will need a very compelling argument. I included the documentation below, maybe your request falls within one of the groupings that could run

how to run my application in background in iphone?

强颜欢笑 提交于 2020-01-09 05:08:05
问题 I want to run my timer in background even when app is not running. Because I want to get gps cordinate of the user after some time interval. What is the method to do this? 回答1: I don't think this is allowed in the iPhone programming paradigm. The operating system is capable of running background tasks but ordinary iPhone apps are not permitted to launch anything like this. 回答2: The Apple Push Notification service is not, in fact, only available to a few developers. It is currently in wide

I want to generate android notification or alarm every day

旧城冷巷雨未停 提交于 2020-01-07 07:49:19
问题 In my application i need to deploy a some kind of reminder. that every day at any fixed time my application generate a notification.. and it happens if my application is running or not. (e.g by using background service) I am able to generate notification, but im un able to create logic to generate it every day. Please help if any one understand what i want. Thanks in advance. 回答1: See below link and this is work for me. Create alarm set on a specified time, using AlarmManager Repeat alarm

Establish a communication link between content script and background page

陌路散爱 提交于 2020-01-07 06:47:30
问题 Developing a chrome extension using javascript is one of my university projects. I don't know how to establish a communication link between content script and background page using messaging. I need some help in this establishing the connection background.html chrome.tabs.getSelected(null, function(tab) { chrome.tabs.sendRequest(tab.id, {method: "getHTML"}, function(response) { console.log(response.data); }); }); content_script.js chrome.extension.onRequest.addListener(function(request,