qid
int64
1
74.7M
question
stringlengths
0
58.3k
date
stringlengths
10
10
metadata
list
response_j
stringlengths
2
48.3k
response_k
stringlengths
2
40.5k
8,044,447
I have an HTML5 web-app that has sound effects. I'm trying to get these effects working in iOS5 and can't for the life of me. Wondering if anyone has any work-arounds to get JS control of an HTML5 audio/video control in iOS5. Or even a way to control multiple audio files with one click. As it stands right now, if I h...
2011/11/08
[ "https://Stackoverflow.com/questions/8044447", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
Absurb, but you have to see it from iPhone or any mobile phone's point of view. It is a mobile phone going over a cellular network with bandwidth limitations, which many people know about from the recent Sprint commercial. They do not want users going over their bandwidth limit because some site is sending their phone ...
Have you tried something like this?? ``` function clickedOnce(){ $('audio').each(function(){ this.play(); }); } ```
8,044,447
I have an HTML5 web-app that has sound effects. I'm trying to get these effects working in iOS5 and can't for the life of me. Wondering if anyone has any work-arounds to get JS control of an HTML5 audio/video control in iOS5. Or even a way to control multiple audio files with one click. As it stands right now, if I h...
2011/11/08
[ "https://Stackoverflow.com/questions/8044447", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
Absurb, but you have to see it from iPhone or any mobile phone's point of view. It is a mobile phone going over a cellular network with bandwidth limitations, which many people know about from the recent Sprint commercial. They do not want users going over their bandwidth limit because some site is sending their phone ...
Due to Apple, they have restricted the auto-play features to prevent cell data charges. In xcode4 i added a workaround though. In your "webViewDidFinishLoad" Send a javascript call to auto play the video and it works. I tried this in the html file with regular javascript but it did not work. Doing it through webViewDid...
8,044,447
I have an HTML5 web-app that has sound effects. I'm trying to get these effects working in iOS5 and can't for the life of me. Wondering if anyone has any work-arounds to get JS control of an HTML5 audio/video control in iOS5. Or even a way to control multiple audio files with one click. As it stands right now, if I h...
2011/11/08
[ "https://Stackoverflow.com/questions/8044447", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
Due to Apple, they have restricted the auto-play features to prevent cell data charges. In xcode4 i added a workaround though. In your "webViewDidFinishLoad" Send a javascript call to auto play the video and it works. I tried this in the html file with regular javascript but it did not work. Doing it through webViewDid...
Have you tried something like this?? ``` function clickedOnce(){ $('audio').each(function(){ this.play(); }); } ```
64,799
A lot of software installation dialogs on Windows throw up a query to the installing user asking if this software should be installed for **all users** or the **current user**. Why do they do this? Why not just install for all users? What is the real technical difference between the two options? I would like to know t...
2009/11/03
[ "https://superuser.com/questions/64799", "https://superuser.com", "https://superuser.com/users/1062/" ]
Take a look at the following web site, it goes into pretty good detail on the differences of *all users* and *current user*: [Installation types](http://www.tarma.com/support/tin5/using/installtypes.htm) **Edit:** This is for a particular type of installation setup software, but the information here is valid for most...
I think the only difference is whether it'll put a shortcut in the all user start menu folder, or in the current user's start menu folder.
64,799
A lot of software installation dialogs on Windows throw up a query to the installing user asking if this software should be installed for **all users** or the **current user**. Why do they do this? Why not just install for all users? What is the real technical difference between the two options? I would like to know t...
2009/11/03
[ "https://superuser.com/questions/64799", "https://superuser.com", "https://superuser.com/users/1062/" ]
In a nutshell... Install For All Users would be used when you want the program to be "active" for anyone who logs on to the computer with their personal account (if there is more than one login). A good example would be an antivirus program, that you would want to be available while any user is logged in. Install for...
Take a look at the following web site, it goes into pretty good detail on the differences of *all users* and *current user*: [Installation types](http://www.tarma.com/support/tin5/using/installtypes.htm) **Edit:** This is for a particular type of installation setup software, but the information here is valid for most...
64,799
A lot of software installation dialogs on Windows throw up a query to the installing user asking if this software should be installed for **all users** or the **current user**. Why do they do this? Why not just install for all users? What is the real technical difference between the two options? I would like to know t...
2009/11/03
[ "https://superuser.com/questions/64799", "https://superuser.com", "https://superuser.com/users/1062/" ]
Take a look at the following web site, it goes into pretty good detail on the differences of *all users* and *current user*: [Installation types](http://www.tarma.com/support/tin5/using/installtypes.htm) **Edit:** This is for a particular type of installation setup software, but the information here is valid for most...
I think that there are two ways to answer this question: For a system admin ------------------ * You've got applications that you don't want anyone to use other than yourself--**current user, admin**--, * you've got bs/bloatware apps that you don't want launching in admin mode but somehow monetize things for your com...
64,799
A lot of software installation dialogs on Windows throw up a query to the installing user asking if this software should be installed for **all users** or the **current user**. Why do they do this? Why not just install for all users? What is the real technical difference between the two options? I would like to know t...
2009/11/03
[ "https://superuser.com/questions/64799", "https://superuser.com", "https://superuser.com/users/1062/" ]
In a nutshell... Install For All Users would be used when you want the program to be "active" for anyone who logs on to the computer with their personal account (if there is more than one login). A good example would be an antivirus program, that you would want to be available while any user is logged in. Install for...
I think the only difference is whether it'll put a shortcut in the all user start menu folder, or in the current user's start menu folder.
64,799
A lot of software installation dialogs on Windows throw up a query to the installing user asking if this software should be installed for **all users** or the **current user**. Why do they do this? Why not just install for all users? What is the real technical difference between the two options? I would like to know t...
2009/11/03
[ "https://superuser.com/questions/64799", "https://superuser.com", "https://superuser.com/users/1062/" ]
I think that there are two ways to answer this question: For a system admin ------------------ * You've got applications that you don't want anyone to use other than yourself--**current user, admin**--, * you've got bs/bloatware apps that you don't want launching in admin mode but somehow monetize things for your com...
I think the only difference is whether it'll put a shortcut in the all user start menu folder, or in the current user's start menu folder.
64,799
A lot of software installation dialogs on Windows throw up a query to the installing user asking if this software should be installed for **all users** or the **current user**. Why do they do this? Why not just install for all users? What is the real technical difference between the two options? I would like to know t...
2009/11/03
[ "https://superuser.com/questions/64799", "https://superuser.com", "https://superuser.com/users/1062/" ]
In a nutshell... Install For All Users would be used when you want the program to be "active" for anyone who logs on to the computer with their personal account (if there is more than one login). A good example would be an antivirus program, that you would want to be available while any user is logged in. Install for...
I think that there are two ways to answer this question: For a system admin ------------------ * You've got applications that you don't want anyone to use other than yourself--**current user, admin**--, * you've got bs/bloatware apps that you don't want launching in admin mode but somehow monetize things for your com...
16,656,079
I want to be able to translate a certain directory in my homedirectory on any OS to the actual absolute path on that OS e.g. `(make-pathname :directory '(:absolute :home "directoryiwant")` should be translated to "/home/weirdusername/directoryiwant" on a unixlike system. What would be the function of choice to do that...
2013/05/20
[ "https://Stackoverflow.com/questions/16656079", "https://Stackoverflow.com", "https://Stackoverflow.com/users/919434/" ]
If you need something relative to your home directory, the Common Lisp functions [**user-homedir-pathname**](http://www.lispworks.com/documentation/lw61/CLHS/Body/f_user_h.htm) and [**merge-pathnames**](http://www.lispworks.com/documentation/HyperSpec/Body/f_merge_.htm) can help you: ``` CL-USER> (merge-pathnames ...
``` CL-USER > (make-pathname :directory (append (pathname-directory (user-homedir-pathname)) (list "directoryiwant")) :defaults (user-homedir-pathname)) #P"/Users/joswig/directoryiwant/" ``` The functio...
212,060
I have in stalled a dual boot beside windows and now I'm having a problem checking `apt-get update` when I type in `apt-get update` this is the outcome. I don't know what to do ``` $ apt-get update E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied) E: Unable to lock directory /var/...
2012/11/05
[ "https://askubuntu.com/questions/212060", "https://askubuntu.com", "https://askubuntu.com/users/104623/" ]
Have you tried putting `sudo` in front of your commands? Like this: ``` sudo apt-get update sudo apt-get upgrade ``` This is necessary for every apt command, except for apt-cache. The `sudo` command will temporarily set your rights to that of [root user](http://en.wikipedia.org/wiki/Superuser), which is necessary ...
Open terminal and run following commnads: ``` sudo rm /var/lib/dpkg/lock sudo apt-get update sudo apt-get upgrade ```
6,245,895
On my new Ubuntu system, I've managed to get Apache2 up and running for developing my ZendFramework Web Applications... I've got my `available-sites` config working correctly because I am able to request `localhost` and it servers up the correct `index.html` from my specified directory. **Problem :** if I request `i...
2011/06/05
[ "https://Stackoverflow.com/questions/6245895", "https://Stackoverflow.com", "https://Stackoverflow.com/users/785127/" ]
If Firefox downloads your PHP files it means that your server doesn't have PHP or the Apache PHP module installed. Have you installed the Apache PHP module? If not then install it by typing this into a terminal: ``` sudo apt-get install libapache2-mod-php5 ``` And if yes, do you have your index.php located in `/var...
I'll assume you installed PHP already and installed the PHP module for Apache here... Did you restart apache? If not: `sudo service apache2 restart` Make sure that your httpd.conf file is also being executed. If necessary, restart it after making an edit that would cause an error on load. If it doesn't fail to restar...
6,245,895
On my new Ubuntu system, I've managed to get Apache2 up and running for developing my ZendFramework Web Applications... I've got my `available-sites` config working correctly because I am able to request `localhost` and it servers up the correct `index.html` from my specified directory. **Problem :** if I request `i...
2011/06/05
[ "https://Stackoverflow.com/questions/6245895", "https://Stackoverflow.com", "https://Stackoverflow.com/users/785127/" ]
If you are using userdir (http://localhost/~user/phpinfo.php) you will want to: ``` vi /etc/apache2/mods-enabled/php5.conf ``` Change ``` <IfModule mod_userdir.c> <Directory /home/*/public_html> php_admin_value engine Off </Directory> </IfModule> ``` to comment the php\_admin\_value ``` <IfModule mo...
I have installed php 7.0 and getting the dailog box. I have installed apache php module for 7.0 version and it fix my problem. sudo apt-get install libapache2-mod-php7.0
6,245,895
On my new Ubuntu system, I've managed to get Apache2 up and running for developing my ZendFramework Web Applications... I've got my `available-sites` config working correctly because I am able to request `localhost` and it servers up the correct `index.html` from my specified directory. **Problem :** if I request `i...
2011/06/05
[ "https://Stackoverflow.com/questions/6245895", "https://Stackoverflow.com", "https://Stackoverflow.com/users/785127/" ]
If you are using userdir (http://localhost/~user/phpinfo.php) you will want to: ``` vi /etc/apache2/mods-enabled/php5.conf ``` Change ``` <IfModule mod_userdir.c> <Directory /home/*/public_html> php_admin_value engine Off </Directory> </IfModule> ``` to comment the php\_admin\_value ``` <IfModule mo...
For me, the solution was to create the following 2 symbolic links: ``` ln -s /etc/apache2/mods-available/php5.conf /etc/apache2/mods-enabled/php5.conf ln -s /etc/apache2/mods-available/php5.load /etc/apache2/mods-enabled/php5.load ``` and to restart Apache: ``` /etc/init.d/apache2 restart ``` Hitting the `http://...
6,245,895
On my new Ubuntu system, I've managed to get Apache2 up and running for developing my ZendFramework Web Applications... I've got my `available-sites` config working correctly because I am able to request `localhost` and it servers up the correct `index.html` from my specified directory. **Problem :** if I request `i...
2011/06/05
[ "https://Stackoverflow.com/questions/6245895", "https://Stackoverflow.com", "https://Stackoverflow.com/users/785127/" ]
I'll assume you installed PHP already and installed the PHP module for Apache here... Did you restart apache? If not: `sudo service apache2 restart` Make sure that your httpd.conf file is also being executed. If necessary, restart it after making an edit that would cause an error on load. If it doesn't fail to restar...
I have installed php 7.0 and getting the dailog box. I have installed apache php module for 7.0 version and it fix my problem. sudo apt-get install libapache2-mod-php7.0
6,245,895
On my new Ubuntu system, I've managed to get Apache2 up and running for developing my ZendFramework Web Applications... I've got my `available-sites` config working correctly because I am able to request `localhost` and it servers up the correct `index.html` from my specified directory. **Problem :** if I request `i...
2011/06/05
[ "https://Stackoverflow.com/questions/6245895", "https://Stackoverflow.com", "https://Stackoverflow.com/users/785127/" ]
If Firefox downloads your PHP files it means that your server doesn't have PHP or the Apache PHP module installed. Have you installed the Apache PHP module? If not then install it by typing this into a terminal: ``` sudo apt-get install libapache2-mod-php5 ``` And if yes, do you have your index.php located in `/var...
If you are using userdir (http://localhost/~user/phpinfo.php) you will want to: ``` vi /etc/apache2/mods-enabled/php5.conf ``` Change ``` <IfModule mod_userdir.c> <Directory /home/*/public_html> php_admin_value engine Off </Directory> </IfModule> ``` to comment the php\_admin\_value ``` <IfModule mo...
6,245,895
On my new Ubuntu system, I've managed to get Apache2 up and running for developing my ZendFramework Web Applications... I've got my `available-sites` config working correctly because I am able to request `localhost` and it servers up the correct `index.html` from my specified directory. **Problem :** if I request `i...
2011/06/05
[ "https://Stackoverflow.com/questions/6245895", "https://Stackoverflow.com", "https://Stackoverflow.com/users/785127/" ]
If Firefox downloads your PHP files it means that your server doesn't have PHP or the Apache PHP module installed. Have you installed the Apache PHP module? If not then install it by typing this into a terminal: ``` sudo apt-get install libapache2-mod-php5 ``` And if yes, do you have your index.php located in `/var...
I have installed php 7.0 and getting the dailog box. I have installed apache php module for 7.0 version and it fix my problem. sudo apt-get install libapache2-mod-php7.0
6,245,895
On my new Ubuntu system, I've managed to get Apache2 up and running for developing my ZendFramework Web Applications... I've got my `available-sites` config working correctly because I am able to request `localhost` and it servers up the correct `index.html` from my specified directory. **Problem :** if I request `i...
2011/06/05
[ "https://Stackoverflow.com/questions/6245895", "https://Stackoverflow.com", "https://Stackoverflow.com/users/785127/" ]
If Firefox downloads your PHP files it means that your server doesn't have PHP or the Apache PHP module installed. Have you installed the Apache PHP module? If not then install it by typing this into a terminal: ``` sudo apt-get install libapache2-mod-php5 ``` And if yes, do you have your index.php located in `/var...
For me, the solution was to create the following 2 symbolic links: ``` ln -s /etc/apache2/mods-available/php5.conf /etc/apache2/mods-enabled/php5.conf ln -s /etc/apache2/mods-available/php5.load /etc/apache2/mods-enabled/php5.load ``` and to restart Apache: ``` /etc/init.d/apache2 restart ``` Hitting the `http://...
6,245,895
On my new Ubuntu system, I've managed to get Apache2 up and running for developing my ZendFramework Web Applications... I've got my `available-sites` config working correctly because I am able to request `localhost` and it servers up the correct `index.html` from my specified directory. **Problem :** if I request `i...
2011/06/05
[ "https://Stackoverflow.com/questions/6245895", "https://Stackoverflow.com", "https://Stackoverflow.com/users/785127/" ]
You need to enable the PHP extension. Do this with the command `sudo a2enmod php`.
I have installed php 7.0 and getting the dailog box. I have installed apache php module for 7.0 version and it fix my problem. sudo apt-get install libapache2-mod-php7.0
6,245,895
On my new Ubuntu system, I've managed to get Apache2 up and running for developing my ZendFramework Web Applications... I've got my `available-sites` config working correctly because I am able to request `localhost` and it servers up the correct `index.html` from my specified directory. **Problem :** if I request `i...
2011/06/05
[ "https://Stackoverflow.com/questions/6245895", "https://Stackoverflow.com", "https://Stackoverflow.com/users/785127/" ]
For me, the solution was to create the following 2 symbolic links: ``` ln -s /etc/apache2/mods-available/php5.conf /etc/apache2/mods-enabled/php5.conf ln -s /etc/apache2/mods-available/php5.load /etc/apache2/mods-enabled/php5.load ``` and to restart Apache: ``` /etc/init.d/apache2 restart ``` Hitting the `http://...
I have installed php 7.0 and getting the dailog box. I have installed apache php module for 7.0 version and it fix my problem. sudo apt-get install libapache2-mod-php7.0
6,245,895
On my new Ubuntu system, I've managed to get Apache2 up and running for developing my ZendFramework Web Applications... I've got my `available-sites` config working correctly because I am able to request `localhost` and it servers up the correct `index.html` from my specified directory. **Problem :** if I request `i...
2011/06/05
[ "https://Stackoverflow.com/questions/6245895", "https://Stackoverflow.com", "https://Stackoverflow.com/users/785127/" ]
If you are using userdir (http://localhost/~user/phpinfo.php) you will want to: ``` vi /etc/apache2/mods-enabled/php5.conf ``` Change ``` <IfModule mod_userdir.c> <Directory /home/*/public_html> php_admin_value engine Off </Directory> </IfModule> ``` to comment the php\_admin\_value ``` <IfModule mo...
You need to enable the PHP extension. Do this with the command `sudo a2enmod php`.
37,960,788
I'm studying the heap of glibc. There's no main\_arena symbol in libc.so, even if I try to dump it with pwntool. However, when I debug a test program, I can print the main\_arena structure. ``` gdb-peda$ p main_arena $1 = { mutex = 0x0, flags = 0x0, fastbinsY = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...
2016/06/22
[ "https://Stackoverflow.com/questions/37960788", "https://Stackoverflow.com", "https://Stackoverflow.com/users/5912310/" ]
`main_arena` is a local symbol and is specifically **not exported**. the list of exported symbols is controlled via the `Version` files in the glibc source tree. this is, by design, to keep people from being able to link against random symbols that glibc uses internally (so as to not pollute the namespace as is require...
The libc.so.6 is stripped. And the debug version of it is not. That's why readelf doesn't show main\_arena. I still wonder how does gdb know the symbol name, even when the library is stripped.
32,482,705
I'm trying to add a char in front of another certain char unless its already preceded by the char I'm trying to inject. This works fine (insert an n before any Z unless it already has an n before it): ``` s/([^n])Z/$1nZ/g; ``` except on word boundaries preceded by nothing. So to fix that I tried: ``` s/([\b^n])Z/$1...
2015/09/09
[ "https://Stackoverflow.com/questions/32482705", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1967804/" ]
Two problems with `[\b^n]`: * `^` only negates the character class if it's the first character. * `[...]` matches a character, but you're trying to match something other than a character. In there, `\b` there represents character `08` (backspace).
Thanks guys- never knew that ^ was different in position 1, in a CC. I move it around outside of a CC (to tag a beginning) and it works as expected. I guess I see why they did it (so you can use ^ within [] to indicate caret not negation). But it seems like escaping it would have had the same effect. Sometimes I wond...
23,628,690
I have a user login app, which takes email, and password from user. I want to save the email and password in phone cache so user does not have to type again. Is there any way to save data in Android cache.
2014/05/13
[ "https://Stackoverflow.com/questions/23628690", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3605640/" ]
You can use `SharedPreferences` for that.. ``` SharedPreferences wmbPreference1,wmbPreference2; SharedPreferences.Editor editor; //wmbPreference for Shared Prefs that lasts forever wmbPreference1 = PreferenceManager.getDefaultSharedPreferences(this); //installsp for Shared Prefs that lasts only just once each ...
Use [SharedPreferences](http://developer.android.com/reference/android/content/SharedPreferences.html) for this. Something like [this](http://examples.javacodegeeks.com/android/core/content/android-sharedpreferences-example/)
23,628,690
I have a user login app, which takes email, and password from user. I want to save the email and password in phone cache so user does not have to type again. Is there any way to save data in Android cache.
2014/05/13
[ "https://Stackoverflow.com/questions/23628690", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3605640/" ]
I think you need to use `SharedPreference` for that which save your data while your application in your device. After uninstall the app from device the data will be remove. 1) Save Data to `SharedPreference` : ``` SharedPreferences prefs = getSharedPreferences("UserData", MODE_PRIVATE); SharedPreferences.Editor edito...
Use [SharedPreferences](http://developer.android.com/reference/android/content/SharedPreferences.html) for this. Something like [this](http://examples.javacodegeeks.com/android/core/content/android-sharedpreferences-example/)
23,628,690
I have a user login app, which takes email, and password from user. I want to save the email and password in phone cache so user does not have to type again. Is there any way to save data in Android cache.
2014/05/13
[ "https://Stackoverflow.com/questions/23628690", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3605640/" ]
SharedPreferences for this kind of type are **much** simpler than use application cache. For more info about SharedPreferences read documentation, you can have SharedPreferences related to an activity or to an activity (it changes just where it will be saved.) To access to the default sharedpreference you will use th...
Use [SharedPreferences](http://developer.android.com/reference/android/content/SharedPreferences.html) for this. Something like [this](http://examples.javacodegeeks.com/android/core/content/android-sharedpreferences-example/)
23,628,690
I have a user login app, which takes email, and password from user. I want to save the email and password in phone cache so user does not have to type again. Is there any way to save data in Android cache.
2014/05/13
[ "https://Stackoverflow.com/questions/23628690", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3605640/" ]
You can use `SharedPreferences` for that.. ``` SharedPreferences wmbPreference1,wmbPreference2; SharedPreferences.Editor editor; //wmbPreference for Shared Prefs that lasts forever wmbPreference1 = PreferenceManager.getDefaultSharedPreferences(this); //installsp for Shared Prefs that lasts only just once each ...
**1.Declare these variables/constants in your class** ``` private SharedPreferences prefs = null; public static final String MY_PREFERENCE = "my_preference";// preference name public static final String USER_NAME = "username"; // key for username public static final String PASSWORD = "passoword";//key for password ``...
23,628,690
I have a user login app, which takes email, and password from user. I want to save the email and password in phone cache so user does not have to type again. Is there any way to save data in Android cache.
2014/05/13
[ "https://Stackoverflow.com/questions/23628690", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3605640/" ]
I think you need to use `SharedPreference` for that which save your data while your application in your device. After uninstall the app from device the data will be remove. 1) Save Data to `SharedPreference` : ``` SharedPreferences prefs = getSharedPreferences("UserData", MODE_PRIVATE); SharedPreferences.Editor edito...
You can use `SharedPreferences` for that.. ``` SharedPreferences wmbPreference1,wmbPreference2; SharedPreferences.Editor editor; //wmbPreference for Shared Prefs that lasts forever wmbPreference1 = PreferenceManager.getDefaultSharedPreferences(this); //installsp for Shared Prefs that lasts only just once each ...
23,628,690
I have a user login app, which takes email, and password from user. I want to save the email and password in phone cache so user does not have to type again. Is there any way to save data in Android cache.
2014/05/13
[ "https://Stackoverflow.com/questions/23628690", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3605640/" ]
You can use `SharedPreferences` for that.. ``` SharedPreferences wmbPreference1,wmbPreference2; SharedPreferences.Editor editor; //wmbPreference for Shared Prefs that lasts forever wmbPreference1 = PreferenceManager.getDefaultSharedPreferences(this); //installsp for Shared Prefs that lasts only just once each ...
SharedPreferences for this kind of type are **much** simpler than use application cache. For more info about SharedPreferences read documentation, you can have SharedPreferences related to an activity or to an activity (it changes just where it will be saved.) To access to the default sharedpreference you will use th...
23,628,690
I have a user login app, which takes email, and password from user. I want to save the email and password in phone cache so user does not have to type again. Is there any way to save data in Android cache.
2014/05/13
[ "https://Stackoverflow.com/questions/23628690", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3605640/" ]
I think you need to use `SharedPreference` for that which save your data while your application in your device. After uninstall the app from device the data will be remove. 1) Save Data to `SharedPreference` : ``` SharedPreferences prefs = getSharedPreferences("UserData", MODE_PRIVATE); SharedPreferences.Editor edito...
**1.Declare these variables/constants in your class** ``` private SharedPreferences prefs = null; public static final String MY_PREFERENCE = "my_preference";// preference name public static final String USER_NAME = "username"; // key for username public static final String PASSWORD = "passoword";//key for password ``...
23,628,690
I have a user login app, which takes email, and password from user. I want to save the email and password in phone cache so user does not have to type again. Is there any way to save data in Android cache.
2014/05/13
[ "https://Stackoverflow.com/questions/23628690", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3605640/" ]
SharedPreferences for this kind of type are **much** simpler than use application cache. For more info about SharedPreferences read documentation, you can have SharedPreferences related to an activity or to an activity (it changes just where it will be saved.) To access to the default sharedpreference you will use th...
**1.Declare these variables/constants in your class** ``` private SharedPreferences prefs = null; public static final String MY_PREFERENCE = "my_preference";// preference name public static final String USER_NAME = "username"; // key for username public static final String PASSWORD = "passoword";//key for password ``...
23,628,690
I have a user login app, which takes email, and password from user. I want to save the email and password in phone cache so user does not have to type again. Is there any way to save data in Android cache.
2014/05/13
[ "https://Stackoverflow.com/questions/23628690", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3605640/" ]
I think you need to use `SharedPreference` for that which save your data while your application in your device. After uninstall the app from device the data will be remove. 1) Save Data to `SharedPreference` : ``` SharedPreferences prefs = getSharedPreferences("UserData", MODE_PRIVATE); SharedPreferences.Editor edito...
SharedPreferences for this kind of type are **much** simpler than use application cache. For more info about SharedPreferences read documentation, you can have SharedPreferences related to an activity or to an activity (it changes just where it will be saved.) To access to the default sharedpreference you will use th...
26,711,249
`/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/universal-darwin13/rbconfig.rb:213: warning: Insecure world writable dir /usr in PATH, mode 040777` I've tried these two commands after searching for solutions on Stackexchange, but it didn't work for me. It still shows me the warning which I'v...
2014/11/03
[ "https://Stackoverflow.com/questions/26711249", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1873047/" ]
Learn to read the error messages closely. ``` Insecure world writable dir /usr in PATH ``` Note it's not saying `/usr/local`. To confirm this diagnosis, use ``` ls -ld /usr drwxrwxrwx 14 ownerID groupID 4096 Dec 10 2010 /usr #-------^- is the world-writeable part ``` As you know, you can fix it with ...
I fixed this by using Disk Utility to repair disk permissions. Open the Disk Utility application and select the disk your system is installed on. Then you can select "Repair Disk Permissions" from the First Aid tab. Repair will take a couple of minutes
26,711,249
`/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/universal-darwin13/rbconfig.rb:213: warning: Insecure world writable dir /usr in PATH, mode 040777` I've tried these two commands after searching for solutions on Stackexchange, but it didn't work for me. It still shows me the warning which I'v...
2014/11/03
[ "https://Stackoverflow.com/questions/26711249", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1873047/" ]
Learn to read the error messages closely. ``` Insecure world writable dir /usr in PATH ``` Note it's not saying `/usr/local`. To confirm this diagnosis, use ``` ls -ld /usr drwxrwxrwx 14 ownerID groupID 4096 Dec 10 2010 /usr #-------^- is the world-writeable part ``` As you know, you can fix it with ...
Executing the following worked for me on Mac OS X 10.11 El Capitan `sudo chmod o-w /usr/local` The error occured when loading a vagrant as follows; `vagrant status /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/pre-rubygems.rb:31: warning: Insecure world writable dir /usr/local in PATH, mode 040777 /opt/v...
26,711,249
`/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/universal-darwin13/rbconfig.rb:213: warning: Insecure world writable dir /usr in PATH, mode 040777` I've tried these two commands after searching for solutions on Stackexchange, but it didn't work for me. It still shows me the warning which I'v...
2014/11/03
[ "https://Stackoverflow.com/questions/26711249", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1873047/" ]
I fixed this by using Disk Utility to repair disk permissions. Open the Disk Utility application and select the disk your system is installed on. Then you can select "Repair Disk Permissions" from the First Aid tab. Repair will take a couple of minutes
Executing the following worked for me on Mac OS X 10.11 El Capitan `sudo chmod o-w /usr/local` The error occured when loading a vagrant as follows; `vagrant status /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/pre-rubygems.rb:31: warning: Insecure world writable dir /usr/local in PATH, mode 040777 /opt/v...
2,169
I marveled at the two flight videos today on YouTube by Perseverance helicopter flights during Ingenuity mission. Got me thinking. Why aren’t the helicopter blades wider? I would like to think that in order to compensate for Mars’ thinner air. Doesn’t increasing the area of wing surfaces equal bigger lift? [Video 1...
2021/11/20
[ "https://drones.stackexchange.com/questions/2169", "https://drones.stackexchange.com", "https://drones.stackexchange.com/users/3741/" ]
Hi mate the design of an ESC with a power limiter is not an easy task. [![enter image description here](https://i.stack.imgur.com/krbAG.png)](https://i.stack.imgur.com/krbAG.png) A purchased ESC will probably have a means of limiting torque or current, but not power. Battery current is probably the best indication of...
This is done by choosing the correct battery and propeller combination--that's it. Choose a battery. Fully charge it. Then, start testing propellers with a power meter in series with your battery. Continually reduce the diameter or pitch or both of the propeller until the power is below 700W at full throttle. Done.
53,440,769
I was doing some python and noticed that: ``` print(len(str(int)) ``` yields 13. To be clear, int is just the integer class, no variable assigned to it. You could run just this code and it yields 13. Now that I think about it, could it be printing the length of 'string' and 'integer' together? If so, why?
2018/11/23
[ "https://Stackoverflow.com/questions/53440769", "https://Stackoverflow.com", "https://Stackoverflow.com/users/10501220/" ]
You seem to want to mark the first occurrence as unique, but not others. So, let's join in the comparison value: ``` select t.*, (id = min_id) as is_first_occurrence from t join (select customer_id, min(id) as min_id from t group by customer_id ) tt on t.customer_id = tt.customer_id; ...
You can try below ``` select id,a.customerid, case when cnt=1 then 1 else 0 end as Unique_Flag from tablename a left join (select customerid, count(*) as cnt from tablename group by customerid )b on a.customerid=b.customerid ```
53,440,769
I was doing some python and noticed that: ``` print(len(str(int)) ``` yields 13. To be clear, int is just the integer class, no variable assigned to it. You could run just this code and it yields 13. Now that I think about it, could it be printing the length of 'string' and 'integer' together? If so, why?
2018/11/23
[ "https://Stackoverflow.com/questions/53440769", "https://Stackoverflow.com", "https://Stackoverflow.com/users/10501220/" ]
You seem to want to mark the first occurrence as unique, but not others. So, let's join in the comparison value: ``` select t.*, (id = min_id) as is_first_occurrence from t join (select customer_id, min(id) as min_id from t group by customer_id ) tt on t.customer_id = tt.customer_id; ...
[![Sample table example](https://i.stack.imgur.com/fqg8w.png)](https://i.stack.imgur.com/fqg8w.png)You can use lead function as given below to get the required output. `SELECT ID, CUSTOMER_ID, CASE WHEN CUSTOMER_ID != CUSTOMER_ID_NEXT THEN 1 ELSE 0 END AS UNIQUE_FLAG FROM (SELECT ID, CUSTOMER_ID,LEAD(CUSTOMER_ID, 1,...
52,994,916
I have a dict of tuples such as: ``` d = {'a': (3, 5), 'b': (5, 8), 'c': (9, 3)} ``` I want to return the key of the minimum of the tuple values based on the tuple index. For example, if using tuple index = 0, then 'a' would be returned. if index = 1, then 'c' would be returned. I have tried using min(), for exam...
2018/10/25
[ "https://Stackoverflow.com/questions/52994916", "https://Stackoverflow.com", "https://Stackoverflow.com/users/4309647/" ]
You can write a lambda function to get the elements from the value by their index: ``` min(d, key=lambda k: d[k][0]) # 'a' min(d, key=lambda k: d[k][1]) # 'c' ```
Dictionaries are unsorted and have no index. If you want the return the key alphabetically first you could use the ascii order: ``` print(chr(min([ord(key) for key in d.keys()]))) ```
52,994,916
I have a dict of tuples such as: ``` d = {'a': (3, 5), 'b': (5, 8), 'c': (9, 3)} ``` I want to return the key of the minimum of the tuple values based on the tuple index. For example, if using tuple index = 0, then 'a' would be returned. if index = 1, then 'c' would be returned. I have tried using min(), for exam...
2018/10/25
[ "https://Stackoverflow.com/questions/52994916", "https://Stackoverflow.com", "https://Stackoverflow.com/users/4309647/" ]
You can write a lambda function to get the elements from the value by their index: ``` min(d, key=lambda k: d[k][0]) # 'a' min(d, key=lambda k: d[k][1]) # 'c' ```
Since multiple keys could have the same value, you might want to return a list of matching keys, not just a single key. ``` def min_keys(d, index): # Initialize lists values = [] matches = [] # Append tuple items to list based on index for t in list(d.values()): values.append(t[index]) ...
52,994,916
I have a dict of tuples such as: ``` d = {'a': (3, 5), 'b': (5, 8), 'c': (9, 3)} ``` I want to return the key of the minimum of the tuple values based on the tuple index. For example, if using tuple index = 0, then 'a' would be returned. if index = 1, then 'c' would be returned. I have tried using min(), for exam...
2018/10/25
[ "https://Stackoverflow.com/questions/52994916", "https://Stackoverflow.com", "https://Stackoverflow.com/users/4309647/" ]
You can write a lambda function to get the elements from the value by their index: ``` min(d, key=lambda k: d[k][0]) # 'a' min(d, key=lambda k: d[k][1]) # 'c' ```
Here's a portable method you can use for dicts with a structure like yours, and feel free to choose the index of interest in the tuple: ``` def extract_min_key_by_index(cache, index): min_val = float('inf') min_key = 0 for k, v in d.iteritems(): if v[index] < min_val: min_key, min_val ...
52,994,916
I have a dict of tuples such as: ``` d = {'a': (3, 5), 'b': (5, 8), 'c': (9, 3)} ``` I want to return the key of the minimum of the tuple values based on the tuple index. For example, if using tuple index = 0, then 'a' would be returned. if index = 1, then 'c' would be returned. I have tried using min(), for exam...
2018/10/25
[ "https://Stackoverflow.com/questions/52994916", "https://Stackoverflow.com", "https://Stackoverflow.com/users/4309647/" ]
Since multiple keys could have the same value, you might want to return a list of matching keys, not just a single key. ``` def min_keys(d, index): # Initialize lists values = [] matches = [] # Append tuple items to list based on index for t in list(d.values()): values.append(t[index]) ...
Dictionaries are unsorted and have no index. If you want the return the key alphabetically first you could use the ascii order: ``` print(chr(min([ord(key) for key in d.keys()]))) ```
52,994,916
I have a dict of tuples such as: ``` d = {'a': (3, 5), 'b': (5, 8), 'c': (9, 3)} ``` I want to return the key of the minimum of the tuple values based on the tuple index. For example, if using tuple index = 0, then 'a' would be returned. if index = 1, then 'c' would be returned. I have tried using min(), for exam...
2018/10/25
[ "https://Stackoverflow.com/questions/52994916", "https://Stackoverflow.com", "https://Stackoverflow.com/users/4309647/" ]
Since multiple keys could have the same value, you might want to return a list of matching keys, not just a single key. ``` def min_keys(d, index): # Initialize lists values = [] matches = [] # Append tuple items to list based on index for t in list(d.values()): values.append(t[index]) ...
Here's a portable method you can use for dicts with a structure like yours, and feel free to choose the index of interest in the tuple: ``` def extract_min_key_by_index(cache, index): min_val = float('inf') min_key = 0 for k, v in d.iteritems(): if v[index] < min_val: min_key, min_val ...
17,628,677
In java all methods are pass by value.But today i learnt that constructors are pass by reference. ``` // Attack the internals of a Period instance Date start = new Date(); Date end = new Date(); Period p = new Period(start, end); end.setYear(78); // Modifies internals of p! ``` This works and is able to edit the pr...
2013/07/13
[ "https://Stackoverflow.com/questions/17628677", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1002790/" ]
It will work same way for other method. Actually reference is passed by value. ``` Class A{ B b; void setB(B b) { this.b = b; } }; A a; B b; A.setB(b); b.change(); //changed in A ``` What it means that reference is passed by value? ``` void f(A a) { a.change(); // caller will see that object i...
You are dealing with only references,not objects. The classic definition of pass by value. *The value of a reference variable is an "address" in Java. When you pass a reference variable to a method, a new reference variable is placed on the stack and a copy of the passed reference variable's value is used to initiali...
17,628,677
In java all methods are pass by value.But today i learnt that constructors are pass by reference. ``` // Attack the internals of a Period instance Date start = new Date(); Date end = new Date(); Period p = new Period(start, end); end.setYear(78); // Modifies internals of p! ``` This works and is able to edit the pr...
2013/07/13
[ "https://Stackoverflow.com/questions/17628677", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1002790/" ]
It will work same way for other method. Actually reference is passed by value. ``` Class A{ B b; void setB(B b) { this.b = b; } }; A a; B b; A.setB(b); b.change(); //changed in A ``` What it means that reference is passed by value? ``` void f(A a) { a.change(); // caller will see that object i...
the mechanism is same for both constructor and method. From the [doc](http://docs.oracle.com/javase/tutorial/java/javaOO/arguments.html) > > Reference data type parameters, such as objects, are also passed into > methods by value. This means that when the method returns, the > passed-in reference still references t...
17,628,677
In java all methods are pass by value.But today i learnt that constructors are pass by reference. ``` // Attack the internals of a Period instance Date start = new Date(); Date end = new Date(); Period p = new Period(start, end); end.setYear(78); // Modifies internals of p! ``` This works and is able to edit the pr...
2013/07/13
[ "https://Stackoverflow.com/questions/17628677", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1002790/" ]
It will work same way for other method. Actually reference is passed by value. ``` Class A{ B b; void setB(B b) { this.b = b; } }; A a; B b; A.setB(b); b.change(); //changed in A ``` What it means that reference is passed by value? ``` void f(A a) { a.change(); // caller will see that object i...
No, you aren't changing any private fields. The private fields in Period are not touched, they still reference the same object. Unfortunatly, a Date object is mutable. So you see the mutation through the Period object. If you want to avoid this, make a copy of each object passed in the constructor, only thus you'll ha...
17,628,677
In java all methods are pass by value.But today i learnt that constructors are pass by reference. ``` // Attack the internals of a Period instance Date start = new Date(); Date end = new Date(); Period p = new Period(start, end); end.setYear(78); // Modifies internals of p! ``` This works and is able to edit the pr...
2013/07/13
[ "https://Stackoverflow.com/questions/17628677", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1002790/" ]
You've got that wrong: > > In java all methods are pass by value. > > > Instead: In Java all parameters are passed by value, even references are passed by value. You don't "pass objects", only references to objects. This is the same for methods and constructors. So ``` end.setYear(78); // Modifies internals...
You are dealing with only references,not objects. The classic definition of pass by value. *The value of a reference variable is an "address" in Java. When you pass a reference variable to a method, a new reference variable is placed on the stack and a copy of the passed reference variable's value is used to initiali...
17,628,677
In java all methods are pass by value.But today i learnt that constructors are pass by reference. ``` // Attack the internals of a Period instance Date start = new Date(); Date end = new Date(); Period p = new Period(start, end); end.setYear(78); // Modifies internals of p! ``` This works and is able to edit the pr...
2013/07/13
[ "https://Stackoverflow.com/questions/17628677", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1002790/" ]
You've got that wrong: > > In java all methods are pass by value. > > > Instead: In Java all parameters are passed by value, even references are passed by value. You don't "pass objects", only references to objects. This is the same for methods and constructors. So ``` end.setYear(78); // Modifies internals...
the mechanism is same for both constructor and method. From the [doc](http://docs.oracle.com/javase/tutorial/java/javaOO/arguments.html) > > Reference data type parameters, such as objects, are also passed into > methods by value. This means that when the method returns, the > passed-in reference still references t...
17,628,677
In java all methods are pass by value.But today i learnt that constructors are pass by reference. ``` // Attack the internals of a Period instance Date start = new Date(); Date end = new Date(); Period p = new Period(start, end); end.setYear(78); // Modifies internals of p! ``` This works and is able to edit the pr...
2013/07/13
[ "https://Stackoverflow.com/questions/17628677", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1002790/" ]
You've got that wrong: > > In java all methods are pass by value. > > > Instead: In Java all parameters are passed by value, even references are passed by value. You don't "pass objects", only references to objects. This is the same for methods and constructors. So ``` end.setYear(78); // Modifies internals...
No, you aren't changing any private fields. The private fields in Period are not touched, they still reference the same object. Unfortunatly, a Date object is mutable. So you see the mutation through the Period object. If you want to avoid this, make a copy of each object passed in the constructor, only thus you'll ha...
17,628,677
In java all methods are pass by value.But today i learnt that constructors are pass by reference. ``` // Attack the internals of a Period instance Date start = new Date(); Date end = new Date(); Period p = new Period(start, end); end.setYear(78); // Modifies internals of p! ``` This works and is able to edit the pr...
2013/07/13
[ "https://Stackoverflow.com/questions/17628677", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1002790/" ]
the mechanism is same for both constructor and method. From the [doc](http://docs.oracle.com/javase/tutorial/java/javaOO/arguments.html) > > Reference data type parameters, such as objects, are also passed into > methods by value. This means that when the method returns, the > passed-in reference still references t...
You are dealing with only references,not objects. The classic definition of pass by value. *The value of a reference variable is an "address" in Java. When you pass a reference variable to a method, a new reference variable is placed on the stack and a copy of the passed reference variable's value is used to initiali...
17,628,677
In java all methods are pass by value.But today i learnt that constructors are pass by reference. ``` // Attack the internals of a Period instance Date start = new Date(); Date end = new Date(); Period p = new Period(start, end); end.setYear(78); // Modifies internals of p! ``` This works and is able to edit the pr...
2013/07/13
[ "https://Stackoverflow.com/questions/17628677", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1002790/" ]
No, you aren't changing any private fields. The private fields in Period are not touched, they still reference the same object. Unfortunatly, a Date object is mutable. So you see the mutation through the Period object. If you want to avoid this, make a copy of each object passed in the constructor, only thus you'll ha...
You are dealing with only references,not objects. The classic definition of pass by value. *The value of a reference variable is an "address" in Java. When you pass a reference variable to a method, a new reference variable is placed on the stack and a copy of the passed reference variable's value is used to initiali...
3,823
Who knows one hundred nineteen? ------------------------------- *Please cite/link your sources, if possible. At some point at least twenty-four hours from now, I will:* * *Upvote all interesting answers.* * *Accept the best answer.* * *Go on to the next number.*
2010/11/04
[ "https://judaism.stackexchange.com/questions/3823", "https://judaism.stackexchange.com", "https://judaism.stackexchange.com/users/2/" ]
[The Yerushalmi (Shabbos 7:2)](http://www.hebrewbooks.org/pdfpager.aspx?req=14141&pgnum=101) mentions sponges (ספוג) in a group of items where cutting them causes them to grow back even more, and therefore declares that someone who does so has performed two categories of work, "reaping" and "planting." These melachos r...
R. Yosef Albo, Sefer ha-Ikkarim 3:1, writes: > > Coral is intermediate between inanimate matter and plants. **We also > find the sea sponge, which only has the sense of touch, and is an > intermediate between plant and animal stages**. We also find the > monkey to be intermediate between animals and man. > > > Th...
3,823
Who knows one hundred nineteen? ------------------------------- *Please cite/link your sources, if possible. At some point at least twenty-four hours from now, I will:* * *Upvote all interesting answers.* * *Accept the best answer.* * *Go on to the next number.*
2010/11/04
[ "https://judaism.stackexchange.com/questions/3823", "https://judaism.stackexchange.com", "https://judaism.stackexchange.com/users/2/" ]
[The Yerushalmi (Shabbos 7:2)](http://www.hebrewbooks.org/pdfpager.aspx?req=14141&pgnum=101) mentions sponges (ספוג) in a group of items where cutting them causes them to grow back even more, and therefore declares that someone who does so has performed two categories of work, "reaping" and "planting." These melachos r...
Assuming the key *halachik* distinction is that which underlies the difference between *tolesh* and *netilas neshama* in *hilchos shabbos*, as seems plausible, that should depend on whether sponges display some form of sentience (at least basic percepts of pain and/or pleasure, as distinct from the automated motions of...
3,823
Who knows one hundred nineteen? ------------------------------- *Please cite/link your sources, if possible. At some point at least twenty-four hours from now, I will:* * *Upvote all interesting answers.* * *Accept the best answer.* * *Go on to the next number.*
2010/11/04
[ "https://judaism.stackexchange.com/questions/3823", "https://judaism.stackexchange.com", "https://judaism.stackexchange.com/users/2/" ]
[The Yerushalmi (Shabbos 7:2)](http://www.hebrewbooks.org/pdfpager.aspx?req=14141&pgnum=101) mentions sponges (ספוג) in a group of items where cutting them causes them to grow back even more, and therefore declares that someone who does so has performed two categories of work, "reaping" and "planting." These melachos r...
It does not matter if it is an animal or plant since inedible things are kosher I do not need to bring a source that a sea sponge is not edible until someone claims otherwise [Gelatin, Kosher](http://ohr.edu/ask_db/ask_main.php/127/Q1/) > > Now, food which even a dog won't eat loses its status as food. Halachicall...
3,823
Who knows one hundred nineteen? ------------------------------- *Please cite/link your sources, if possible. At some point at least twenty-four hours from now, I will:* * *Upvote all interesting answers.* * *Accept the best answer.* * *Go on to the next number.*
2010/11/04
[ "https://judaism.stackexchange.com/questions/3823", "https://judaism.stackexchange.com", "https://judaism.stackexchange.com/users/2/" ]
[The Yerushalmi (Shabbos 7:2)](http://www.hebrewbooks.org/pdfpager.aspx?req=14141&pgnum=101) mentions sponges (ספוג) in a group of items where cutting them causes them to grow back even more, and therefore declares that someone who does so has performed two categories of work, "reaping" and "planting." These melachos r...
Sea Sponge does not have fins or scales so it is not kosher. Please see Vaikra 11:9-13. It says of all living creatures, not just fish. 9 These may ye eat of all that are in the waters: whatsoever hath fins and scales in the waters, in the seas, and in the rivers, them may ye eat. 10 And all that have not fins and sca...
3,823
Who knows one hundred nineteen? ------------------------------- *Please cite/link your sources, if possible. At some point at least twenty-four hours from now, I will:* * *Upvote all interesting answers.* * *Accept the best answer.* * *Go on to the next number.*
2010/11/04
[ "https://judaism.stackexchange.com/questions/3823", "https://judaism.stackexchange.com", "https://judaism.stackexchange.com/users/2/" ]
R. Yosef Albo, Sefer ha-Ikkarim 3:1, writes: > > Coral is intermediate between inanimate matter and plants. **We also > find the sea sponge, which only has the sense of touch, and is an > intermediate between plant and animal stages**. We also find the > monkey to be intermediate between animals and man. > > > Th...
Assuming the key *halachik* distinction is that which underlies the difference between *tolesh* and *netilas neshama* in *hilchos shabbos*, as seems plausible, that should depend on whether sponges display some form of sentience (at least basic percepts of pain and/or pleasure, as distinct from the automated motions of...
3,823
Who knows one hundred nineteen? ------------------------------- *Please cite/link your sources, if possible. At some point at least twenty-four hours from now, I will:* * *Upvote all interesting answers.* * *Accept the best answer.* * *Go on to the next number.*
2010/11/04
[ "https://judaism.stackexchange.com/questions/3823", "https://judaism.stackexchange.com", "https://judaism.stackexchange.com/users/2/" ]
R. Yosef Albo, Sefer ha-Ikkarim 3:1, writes: > > Coral is intermediate between inanimate matter and plants. **We also > find the sea sponge, which only has the sense of touch, and is an > intermediate between plant and animal stages**. We also find the > monkey to be intermediate between animals and man. > > > Th...
It does not matter if it is an animal or plant since inedible things are kosher I do not need to bring a source that a sea sponge is not edible until someone claims otherwise [Gelatin, Kosher](http://ohr.edu/ask_db/ask_main.php/127/Q1/) > > Now, food which even a dog won't eat loses its status as food. Halachicall...
3,823
Who knows one hundred nineteen? ------------------------------- *Please cite/link your sources, if possible. At some point at least twenty-four hours from now, I will:* * *Upvote all interesting answers.* * *Accept the best answer.* * *Go on to the next number.*
2010/11/04
[ "https://judaism.stackexchange.com/questions/3823", "https://judaism.stackexchange.com", "https://judaism.stackexchange.com/users/2/" ]
R. Yosef Albo, Sefer ha-Ikkarim 3:1, writes: > > Coral is intermediate between inanimate matter and plants. **We also > find the sea sponge, which only has the sense of touch, and is an > intermediate between plant and animal stages**. We also find the > monkey to be intermediate between animals and man. > > > Th...
Sea Sponge does not have fins or scales so it is not kosher. Please see Vaikra 11:9-13. It says of all living creatures, not just fish. 9 These may ye eat of all that are in the waters: whatsoever hath fins and scales in the waters, in the seas, and in the rivers, them may ye eat. 10 And all that have not fins and sca...
3,823
Who knows one hundred nineteen? ------------------------------- *Please cite/link your sources, if possible. At some point at least twenty-four hours from now, I will:* * *Upvote all interesting answers.* * *Accept the best answer.* * *Go on to the next number.*
2010/11/04
[ "https://judaism.stackexchange.com/questions/3823", "https://judaism.stackexchange.com", "https://judaism.stackexchange.com/users/2/" ]
Assuming the key *halachik* distinction is that which underlies the difference between *tolesh* and *netilas neshama* in *hilchos shabbos*, as seems plausible, that should depend on whether sponges display some form of sentience (at least basic percepts of pain and/or pleasure, as distinct from the automated motions of...
It does not matter if it is an animal or plant since inedible things are kosher I do not need to bring a source that a sea sponge is not edible until someone claims otherwise [Gelatin, Kosher](http://ohr.edu/ask_db/ask_main.php/127/Q1/) > > Now, food which even a dog won't eat loses its status as food. Halachicall...
3,823
Who knows one hundred nineteen? ------------------------------- *Please cite/link your sources, if possible. At some point at least twenty-four hours from now, I will:* * *Upvote all interesting answers.* * *Accept the best answer.* * *Go on to the next number.*
2010/11/04
[ "https://judaism.stackexchange.com/questions/3823", "https://judaism.stackexchange.com", "https://judaism.stackexchange.com/users/2/" ]
Assuming the key *halachik* distinction is that which underlies the difference between *tolesh* and *netilas neshama* in *hilchos shabbos*, as seems plausible, that should depend on whether sponges display some form of sentience (at least basic percepts of pain and/or pleasure, as distinct from the automated motions of...
Sea Sponge does not have fins or scales so it is not kosher. Please see Vaikra 11:9-13. It says of all living creatures, not just fish. 9 These may ye eat of all that are in the waters: whatsoever hath fins and scales in the waters, in the seas, and in the rivers, them may ye eat. 10 And all that have not fins and sca...
4,438,359
What is the best way of doing this ? ``` rand('Helloworld','Hi world'); ``` I know this is not working as rand needs a min and max number, but what is the solution for this ?
2010/12/14
[ "https://Stackoverflow.com/questions/4438359", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
Use [array\_rand](http://php.net/manual/en/function.array-rand.php).
Something likes that: ``` <?php $array = array(1, 2, 3); $array[ mt_rand( 0, count($array) -1 ) ]; ?> ```
4,438,359
What is the best way of doing this ? ``` rand('Helloworld','Hi world'); ``` I know this is not working as rand needs a min and max number, but what is the solution for this ?
2010/12/14
[ "https://Stackoverflow.com/questions/4438359", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
Use [array\_rand](http://php.net/manual/en/function.array-rand.php).
PHP's [array\_rand()](http://php.net/manual/en/function.array-rand.php) for sure. Example: ``` <?php $names = array('Neo', 'Morpheus', 'Trinity', 'Cypher', 'Tank'); echo 'Hello ' . $names[array_rand($names)]; ```
4,438,359
What is the best way of doing this ? ``` rand('Helloworld','Hi world'); ``` I know this is not working as rand needs a min and max number, but what is the solution for this ?
2010/12/14
[ "https://Stackoverflow.com/questions/4438359", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
Use [array\_rand](http://php.net/manual/en/function.array-rand.php).
``` function rand_of() { $_ = func_get_args(); return $_[rand(0, count($_) - 1)]; } echo rand_of("foo", "bar", "baz"); ```
4,438,359
What is the best way of doing this ? ``` rand('Helloworld','Hi world'); ``` I know this is not working as rand needs a min and max number, but what is the solution for this ?
2010/12/14
[ "https://Stackoverflow.com/questions/4438359", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
Something likes that: ``` <?php $array = array(1, 2, 3); $array[ mt_rand( 0, count($array) -1 ) ]; ?> ```
``` function rand_of() { $_ = func_get_args(); return $_[rand(0, count($_) - 1)]; } echo rand_of("foo", "bar", "baz"); ```
4,438,359
What is the best way of doing this ? ``` rand('Helloworld','Hi world'); ``` I know this is not working as rand needs a min and max number, but what is the solution for this ?
2010/12/14
[ "https://Stackoverflow.com/questions/4438359", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
PHP's [array\_rand()](http://php.net/manual/en/function.array-rand.php) for sure. Example: ``` <?php $names = array('Neo', 'Morpheus', 'Trinity', 'Cypher', 'Tank'); echo 'Hello ' . $names[array_rand($names)]; ```
``` function rand_of() { $_ = func_get_args(); return $_[rand(0, count($_) - 1)]; } echo rand_of("foo", "bar", "baz"); ```
2,080,573
I'm new at YouTube Data API as well as C#. I want to search the video and display the result into a listview and I did but I can't did it asynchronously. I've searched and try a lot but end up with nothing. <http://google-gdata.googlecode.com/svn/docs/folder48/Multithreadedoperations.html> Please help me.
2010/01/17
[ "https://Stackoverflow.com/questions/2080573", "https://Stackoverflow.com", "https://Stackoverflow.com/users/120516/" ]
Most WebService API's (especially [REST](http://en.wikipedia.org/wiki/Representational_State_Transfer)ful ones) do not provide an async way to retrieve results, since in general, they try to remain stateless: I believe that the Youtube API is no exception. Instead you will need to lean on traditional methods for simu...
Can't you wrap any non async method in a asynchronous call using asynchronous delegates? My reference is this [link](http://www.albahari.com/threading/part3.aspx#_Asynch_Delegates). Ok So did you make your async call something like this ... ``` private delegate <returnType> YouTubeAPI( <args> ) private YouTubeAPI fun...
67,788,187
This is the full question: **Write a Python program to get a string from a given string where all occurrences of its first char have been changed to '$', except the first char itself. Sample String : 'restart' Expected Result : 'resta$t'** The code I gave was as follows: ``` e="Test string" f="" for k in range(0,len(...
2021/06/01
[ "https://Stackoverflow.com/questions/67788187", "https://Stackoverflow.com", "https://Stackoverflow.com/users/16094948/" ]
Finally solved this. I had tried with Charset unicode on the DLL call previously, but I had missed setting it on the structs: ``` [DllImport(DLL, CallingConvention = CallingConvention.StdCall, CharSet = CharSet.Unicode)] private static extern void CalculateData(MyDLLQuery indata, out MyDLLResult outdata, CallbackDeleg...
``` StructLayout(LayoutKind.Sequential, Pack = 1, CharSet = CharSet.Unicode)] public struct Result { //SizeCount bezieht sich anscheinden auf Char (hier 2 Byte) und // nicht auf die Bytegröße des Felds [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)] public string BIC; //Delphi: ...
30,734,678
My Situation: ------------- I have learnt Swift for a while and Swift is my only language I've learnt for iOS Development, which means I did not learn Objective-C Systematically. I can just read OC Code a little. I got a `CGPoint` problem when I tried to translate a OC project to Swift project. Objective-C Code: ---...
2015/06/09
[ "https://Stackoverflow.com/questions/30734678", "https://Stackoverflow.com", "https://Stackoverflow.com/users/4658539/" ]
It's called undefined behavior, since it's undefined sometimes it works. Yes you can write past a memory block in c, but that's illegal because it invokes undefined behavior, the behavior is therefore not predictable and your program might or might not work. What you expect from `strcpy()` doesn't happen because `strc...
What you are experiencing is a [buffer overflow](http://en.wikipedia.org/wiki/buffer_overflow) In short, you write to invalid memory addresses invoking [Undefined Behavior](http://en.wikipedia.org/wiki/Undefined_behavior). Anything can happen.
30,734,678
My Situation: ------------- I have learnt Swift for a while and Swift is my only language I've learnt for iOS Development, which means I did not learn Objective-C Systematically. I can just read OC Code a little. I got a `CGPoint` problem when I tried to translate a OC project to Swift project. Objective-C Code: ---...
2015/06/09
[ "https://Stackoverflow.com/questions/30734678", "https://Stackoverflow.com", "https://Stackoverflow.com/users/4658539/" ]
It's called undefined behavior, since it's undefined sometimes it works. Yes you can write past a memory block in c, but that's illegal because it invokes undefined behavior, the behavior is therefore not predictable and your program might or might not work. What you expect from `strcpy()` doesn't happen because `strc...
It seems that it worked but in fact your code invokes undefined behavior. You are writing data to unallocated memory location. You should note that in ``` strcpy(str1, str2); ``` `strcpy` has no way to check whether the string pointed to by `str2` will fit into the character array `str1`. In your case it will c...
41,533
AssalamuAlaykum O-rahmatullah O-barokatuh! When some one is praying can we cross? Give me some proofs of the hadith, JazacAllah-khair! Assalamu'Alaykum O Rahmatullah O Barokatuh!
2017/07/21
[ "https://islam.stackexchange.com/questions/41533", "https://islam.stackexchange.com", "https://islam.stackexchange.com/users/23527/" ]
The narration below indicates that we are commanded to pray behind a Barrier/Sutrah: > > If the one who is praying has set up a sutrah (object to serve as a > screen). In this case it is permissible to pass beyond the sutrah, > because the Prophet (peace and blessings of Allaah be upon him) said: > “If any one of ...
Default rule: If there's a sutra (barrier like a pole of hands height) then any male can pass. In congregation prayer one can pass in front of anybody except the imam irrespective of barrier.
13,898,551
I have a small program that connects to an access database, and what I am trying to do is update(edit) a selected record via an edit form. When I execute my code, I get this error: ```none System.Data.OleDb.OleDbException was unhandled Message=Syntax error (missing operator) in query expression '5346 S. Eubank blvd'...
2012/12/16
[ "https://Stackoverflow.com/questions/13898551", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1907302/" ]
`"abcde"` is a string literal, which is an array of characters (`char[]`). It is *typically* placed in a read-only data section of the program. If you were to pass that to `printf`, the compiler is actually passing the address of that array to `printf`. However, here you are *de-referencing* that pointer, which passes...
Remember the printf function takes in a const char\* as a parameter, and as said above a string is just an array of char values. When passing an array in c++ the compiler takes it as a pointer to the first element of the []. Ex. string nums[] = {"one", "two); string\* p2 = nums; //Totally valid and how the compiler wo...
13,898,551
I have a small program that connects to an access database, and what I am trying to do is update(edit) a selected record via an edit form. When I execute my code, I get this error: ```none System.Data.OleDb.OleDbException was unhandled Message=Syntax error (missing operator) in query expression '5346 S. Eubank blvd'...
2012/12/16
[ "https://Stackoverflow.com/questions/13898551", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1907302/" ]
`"abcde"` is a string literal and thus has array type. In any context but `sizeof` or the operand of `&`, an array decays to a pointer to its first element. Thus, when used as the operand of the unary `*` operator, `"abcde"` is evaluated to a pointer to the "a" at the beginning of the string, and the `*` operator deref...
Remember the printf function takes in a const char\* as a parameter, and as said above a string is just an array of char values. When passing an array in c++ the compiler takes it as a pointer to the first element of the []. Ex. string nums[] = {"one", "two); string\* p2 = nums; //Totally valid and how the compiler wo...
59,702,185
I'm trying to design a mobile application with comboBox inside TableView. ``` import QtQuick 2.9 import QtQuick.Controls 2.2 import QtQuick 2.7 import QtQuick.Controls 2.0 import QtQuick.Layouts 1.0 import QtQuick.Controls 1.2 import QtQuick.Window 2.0 import QtLocation 5.6 import QtPositioning 5.6 import QtQuick.Cont...
2020/01/12
[ "https://Stackoverflow.com/questions/59702185", "https://Stackoverflow.com", "https://Stackoverflow.com/users/12698050/" ]
One way to do it is to do it is through a self-join with the same table and a 1-month delay. That way, we match user&month combinations with user&previous-month to see if it's a returning user. For example, using the 2M row public table `bigquery-public-data.hacker_news.stories` and a particular user: [![enter image d...
If you are just looking at the previous month, then do the following: * Convert the months to numbers. * Aggregate the data at the user/month level. Then you can just use `lag()`: ``` select month, count(*) as num_users, countif(prev_month_int = month_int - 1) as prev_num_users, countif(prev_mon...
8,770,215
How i write the inline conditional statement in Flex with two expressions(case) like ``` text="{expression, expression2 ? true:false}" ``` Flex compiler only check the first expression and on behalf of that give result.But i want to check both statement and show result. if no condition met then do nothing.
2012/01/07
[ "https://Stackoverflow.com/questions/8770215", "https://Stackoverflow.com", "https://Stackoverflow.com/users/355191/" ]
If I understand your question correctly either: `text = ((expression) && (expression2)) ? true : false;` or `text = ((expression) || (expression2)) ? true : false;` **[UPDATE 1]** Well I say either, but the first tests to see if both conditions are true, where as the second tests if either condition is true which I...
I would write the following statements instead : ``` var expression1:Boolean; var expression2:Boolean; var result:Boolean; expression1 = condition?true:false; expression2 = anotherCondition?true:false; result = expression1&&expression2; ```
8,770,215
How i write the inline conditional statement in Flex with two expressions(case) like ``` text="{expression, expression2 ? true:false}" ``` Flex compiler only check the first expression and on behalf of that give result.But i want to check both statement and show result. if no condition met then do nothing.
2012/01/07
[ "https://Stackoverflow.com/questions/8770215", "https://Stackoverflow.com", "https://Stackoverflow.com/users/355191/" ]
If you want them in one `if` statement, use the `and` or `or` operators: `&&~ and`||`, respectively. For example: ``` var x:int = 6 if (x > 3 && x < 10) { trace("both are true, so its contents will be acted on."); } var bob:Boolean = true; if (x > 10 || bob) { trace("x > 10 is false, but bob is true, so this ...
I would write the following statements instead : ``` var expression1:Boolean; var expression2:Boolean; var result:Boolean; expression1 = condition?true:false; expression2 = anotherCondition?true:false; result = expression1&&expression2; ```
8,770,215
How i write the inline conditional statement in Flex with two expressions(case) like ``` text="{expression, expression2 ? true:false}" ``` Flex compiler only check the first expression and on behalf of that give result.But i want to check both statement and show result. if no condition met then do nothing.
2012/01/07
[ "https://Stackoverflow.com/questions/8770215", "https://Stackoverflow.com", "https://Stackoverflow.com/users/355191/" ]
There are number of methods, you can just write like that : `(condition1 && condition2) ? statement if true : statement if false` but if you want to execute this code in mxml component bindings, then you must use : `'&amp &amp'` instead of `&&`,`'&lt'` instead of `<`, etc.
I would write the following statements instead : ``` var expression1:Boolean; var expression2:Boolean; var result:Boolean; expression1 = condition?true:false; expression2 = anotherCondition?true:false; result = expression1&&expression2; ```
8,770,215
How i write the inline conditional statement in Flex with two expressions(case) like ``` text="{expression, expression2 ? true:false}" ``` Flex compiler only check the first expression and on behalf of that give result.But i want to check both statement and show result. if no condition met then do nothing.
2012/01/07
[ "https://Stackoverflow.com/questions/8770215", "https://Stackoverflow.com", "https://Stackoverflow.com/users/355191/" ]
If I understand your question correctly either: `text = ((expression) && (expression2)) ? true : false;` or `text = ((expression) || (expression2)) ? true : false;` **[UPDATE 1]** Well I say either, but the first tests to see if both conditions are true, where as the second tests if either condition is true which I...
If you want them in one `if` statement, use the `and` or `or` operators: `&&~ and`||`, respectively. For example: ``` var x:int = 6 if (x > 3 && x < 10) { trace("both are true, so its contents will be acted on."); } var bob:Boolean = true; if (x > 10 || bob) { trace("x > 10 is false, but bob is true, so this ...
8,770,215
How i write the inline conditional statement in Flex with two expressions(case) like ``` text="{expression, expression2 ? true:false}" ``` Flex compiler only check the first expression and on behalf of that give result.But i want to check both statement and show result. if no condition met then do nothing.
2012/01/07
[ "https://Stackoverflow.com/questions/8770215", "https://Stackoverflow.com", "https://Stackoverflow.com/users/355191/" ]
If I understand your question correctly either: `text = ((expression) && (expression2)) ? true : false;` or `text = ((expression) || (expression2)) ? true : false;` **[UPDATE 1]** Well I say either, but the first tests to see if both conditions are true, where as the second tests if either condition is true which I...
There are number of methods, you can just write like that : `(condition1 && condition2) ? statement if true : statement if false` but if you want to execute this code in mxml component bindings, then you must use : `'&amp &amp'` instead of `&&`,`'&lt'` instead of `<`, etc.
8,770,215
How i write the inline conditional statement in Flex with two expressions(case) like ``` text="{expression, expression2 ? true:false}" ``` Flex compiler only check the first expression and on behalf of that give result.But i want to check both statement and show result. if no condition met then do nothing.
2012/01/07
[ "https://Stackoverflow.com/questions/8770215", "https://Stackoverflow.com", "https://Stackoverflow.com/users/355191/" ]
There are number of methods, you can just write like that : `(condition1 && condition2) ? statement if true : statement if false` but if you want to execute this code in mxml component bindings, then you must use : `'&amp &amp'` instead of `&&`,`'&lt'` instead of `<`, etc.
If you want them in one `if` statement, use the `and` or `or` operators: `&&~ and`||`, respectively. For example: ``` var x:int = 6 if (x > 3 && x < 10) { trace("both are true, so its contents will be acted on."); } var bob:Boolean = true; if (x > 10 || bob) { trace("x > 10 is false, but bob is true, so this ...
1,065,854
When creating MX records for a domain, is it important what they are called? I want to manage email through a remote service and have added the appropriate destination and priority. The service that is used to manage the domain (cpanel) does not allow the MX record name to be called `@` so I gave it a name like `mx1.m...
2021/06/06
[ "https://serverfault.com/questions/1065854", "https://serverfault.com", "https://serverfault.com/users/89776/" ]
The owner name is crucially important as it has to match the right-hand-side of the email address. Eg `foo@example.com` -> look up `example.com MX`, `foo@bar.example.com` -> look up `bar.example.com MX`. If the `MX` exists at `mx1.example.com` it will only serve any purpose for mail sent to addresses ending with `@mx...
You can also give the name for MX record as *domainname.com*. (the period character at the end is required), replace with your primary domain hosted in CPanel.
8,846,551
I'm trying to get the latitude/longitude of all of a user's friends using a single API call. I believe I need to write a multi-query FQL statement, but I can't get the syntax correct. I believe the two queries need to be something like the following: ``` '"friends":"SELECT uid,current_location FROM user WHERE uid IN ...
2012/01/13
[ "https://Stackoverflow.com/questions/8846551", "https://Stackoverflow.com", "https://Stackoverflow.com/users/783423/" ]
Edit: The query should work by adjusting the second query to: ``` '"location":"SELECT location FROM page WHERE id IN (SELECT current_location.id FROM #friends)"'; ``` When working with an array type in the FB API you can access the value in any query by doing array.value Also, if all you need is the page's id, you...
``` facebook.batch_fql({ 'query1': "SELECT uid, name, current_location.id FROM user WHERE uid IN (SELECT uid2 FROM friend WHERE uid1=me())", 'query2': "SELECT page_id, name, description, location FROM page WHERE page_id IN (SELECT current_location.id FROM #query1)" }) ``` will return two responses one will b...
8,846,551
I'm trying to get the latitude/longitude of all of a user's friends using a single API call. I believe I need to write a multi-query FQL statement, but I can't get the syntax correct. I believe the two queries need to be something like the following: ``` '"friends":"SELECT uid,current_location FROM user WHERE uid IN ...
2012/01/13
[ "https://Stackoverflow.com/questions/8846551", "https://Stackoverflow.com", "https://Stackoverflow.com/users/783423/" ]
``` fql?q=SELECT location,name FROM page WHERE page_id in (SELECT current_location.id from user where uid in(select uid2 from friend where uid1=me())) ``` this will do the magic for you
``` facebook.batch_fql({ 'query1': "SELECT uid, name, current_location.id FROM user WHERE uid IN (SELECT uid2 FROM friend WHERE uid1=me())", 'query2': "SELECT page_id, name, description, location FROM page WHERE page_id IN (SELECT current_location.id FROM #query1)" }) ``` will return two responses one will b...
3,107,636
I would like to know if there's a way of automatically minify html, css or javascript files. So that each time I save the "source file" Vim automatically make the same changes to a minified version of the file (or automatically creates or override a minified version). Something like this: **Source:** ``` // The -is...
2010/06/24
[ "https://Stackoverflow.com/questions/3107636", "https://Stackoverflow.com", "https://Stackoverflow.com/users/122536/" ]
Use PHP's DOM parser Incomplete example, but something to get you started: ``` $dom = new DOMDocument(); $dom->loadHTML($yourHtmlDocument); $xPath = new DOMXPath($dom); $elements = $xPath->query('\\random\td\a'); // Or whatever your real path would be foreach($elements as $node) { echo $node->nodeValue; } ``` [...
``` $regexp = "FrmKlant.aspx.*\">(.*)<\/a>\s(.*)<br>\s(.*)\s\s(.*)</td>"; ```
3,107,636
I would like to know if there's a way of automatically minify html, css or javascript files. So that each time I save the "source file" Vim automatically make the same changes to a minified version of the file (or automatically creates or override a minified version). Something like this: **Source:** ``` // The -is...
2010/06/24
[ "https://Stackoverflow.com/questions/3107636", "https://Stackoverflow.com", "https://Stackoverflow.com/users/122536/" ]
Use PHP's DOM parser Incomplete example, but something to get you started: ``` $dom = new DOMDocument(); $dom->loadHTML($yourHtmlDocument); $xPath = new DOMXPath($dom); $elements = $xPath->query('\\random\td\a'); // Or whatever your real path would be foreach($elements as $node) { echo $node->nodeValue; } ``` [...
It is usually not a good idea, to try and extract information from HTML/XML using regular expressions. They a renot well suited to deal with nested structures. Everything you can try will horribly break if your "random html" parts are evil enough, so use them only if have very good control over the html. Try a parser ...
35,965,655
How should an entry in the info.plist file be added in Meteor? Is there a mobile-config setting or similar? The Uber documentation has an example of why you would want to add an entry: <https://developer.uber.com/docs/deep-linking>
2016/03/13
[ "https://Stackoverflow.com/questions/35965655", "https://Stackoverflow.com", "https://Stackoverflow.com/users/4025140/" ]
I've not used Meteor, but you might be able to use the [cordova-custom-config](https://github.com/dpa99c/cordova-custom-config) plugin to define custom config in `project/cordova-build-override/config.xml` (see [Meteor Advanced Build Customization](https://github.com/meteor/meteor/wiki/Meteor-Cordova-integration#advanc...
The answer by @davealden is not a correct answer for Meteor. Meteor uses `mobile-config.js`for mobile configurations. You should configure this file and avoid 3rd party workarounds as Meteor checks this file in making the build and using a 3rd party would lead inconsistency. The `mobile-config.js` file is located in ...
15,358,208
Using Poco, I'm trying to emulate an AXIS camera web-server, that sends jpeg frames on clients request. Each web response should be encoded with Content-Type: multipart/x-mixed-replace and a predefined boundary. How can I do it with Poco? Thanks.
2013/03/12
[ "https://Stackoverflow.com/questions/15358208", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1483751/" ]
The *response.setContentType()* is rigth, but when you make the *sendBuffer()*, Poco doesn't put the predefined boundary strings at top of each boundary block. It is important to specify *setChunkedTransferEncoding()* to *false* to avoid chunk transfers, that it is not what I am asking for. What I need is this: <http...
Something along these lines should do: ``` using Poco::Net::HTTPRequestHandler; using Poco::Net::HTTPServerRequest; using Poco::Net::HTTPServerResponse; using Poco::Net::HTTPRequestHandlerFactory; using Poco::Net::HTTPServerParams; using Poco::Net::HTTPServer; using Poco::Net::ServerSocket; using Poco::Net::SocketAddr...
3,974,769
How to add an event handler on all div elements with GWT? I tried the following code but the window alerts are not fired up (But "etvoila" class is set up): ```java private NodeList<Element> pageDIVElements; public void initDiv() { MyDIVEventHandler handler = new MyDIVEventHandler(); pageDIVElements = Docu...
2010/10/20
[ "https://Stackoverflow.com/questions/3974769", "https://Stackoverflow.com", "https://Stackoverflow.com/users/388465/" ]
Looks like you negelected to sink the events that you want the listener to be notified of. In this case for example I would add the following into initDiv to element or the relevant children. ``` DOM.sinkEvents(elem, Event.ONCLICK | Event.ONMOUSEOUT | Event.ONMOUSEOVER); ```
Similarly to [this question](https://stackoverflow.com/questions/3954392/in-gwt-adding-an-event-handler-on-any-of-the-host-page-tags), you can wrap it in a `Label`. ``` NodeList<Element> elems = Document.get().getElementsByTagName("div"); for (int i = 0; i < elems.getLength(); i++) { Element elem = elems.get(i); L...
85,317
I'm an undergraduate electrical engineer. I have studied up to 80 percent of a masters in electrical engineering program and have two IEEE published papers. Is there such a thing as a PhD entrance exam that I can take to prove my ability to pass advanced electrical courses and get admitted directly into a PhD in a univ...
2017/02/19
[ "https://academia.stackexchange.com/questions/85317", "https://academia.stackexchange.com", "https://academia.stackexchange.com/users/69643/" ]
Admission and funding in European PhD programs depends a lot on the university and the country's regulations. You should search for the programs you are interested in applying to and read their specific requirements.
In Germany, it is possible to start your PhD without a master [since 2000](http://www.kmk.org/fileadmin/veroeffentlichungen_beschluesse/2000/2000_04_14-Bachelor-Master-Promotion.pdf) (text only in German). You have to find an advisor and pass a qualifying examination, which differs by university. So, you first have to ...
85,317
I'm an undergraduate electrical engineer. I have studied up to 80 percent of a masters in electrical engineering program and have two IEEE published papers. Is there such a thing as a PhD entrance exam that I can take to prove my ability to pass advanced electrical courses and get admitted directly into a PhD in a univ...
2017/02/19
[ "https://academia.stackexchange.com/questions/85317", "https://academia.stackexchange.com", "https://academia.stackexchange.com/users/69643/" ]
Admission and funding in European PhD programs depends a lot on the university and the country's regulations. You should search for the programs you are interested in applying to and read their specific requirements.
The Dutch (eg. Eindhoven) situation is that a PhD is normally funded (or done as an external PhD with a company). As such anyone will have to go through what amounts to a "job" interview. Within the system a masters is normally expected, but exceptions can be made, especially for candidates from countries where a maste...
85,317
I'm an undergraduate electrical engineer. I have studied up to 80 percent of a masters in electrical engineering program and have two IEEE published papers. Is there such a thing as a PhD entrance exam that I can take to prove my ability to pass advanced electrical courses and get admitted directly into a PhD in a univ...
2017/02/19
[ "https://academia.stackexchange.com/questions/85317", "https://academia.stackexchange.com", "https://academia.stackexchange.com/users/69643/" ]
Admission and funding in European PhD programs depends a lot on the university and the country's regulations. You should search for the programs you are interested in applying to and read their specific requirements.
In Spain it is in general necessary to have an "Oficial" Master's degree to enter a PhD program. The "official" qualifier means that some master's programs are formally recognized as conduits to doctoral programs, whereas others are not. In general a foreign degree would have to be recognized as equivalent to a Spanish...
85,317
I'm an undergraduate electrical engineer. I have studied up to 80 percent of a masters in electrical engineering program and have two IEEE published papers. Is there such a thing as a PhD entrance exam that I can take to prove my ability to pass advanced electrical courses and get admitted directly into a PhD in a univ...
2017/02/19
[ "https://academia.stackexchange.com/questions/85317", "https://academia.stackexchange.com", "https://academia.stackexchange.com/users/69643/" ]
Admission and funding in European PhD programs depends a lot on the university and the country's regulations. You should search for the programs you are interested in applying to and read their specific requirements.
In France, they count it in years of study. My Bachelor in Engineering was 5 years, so that was "equivalent" to a MS in France. I had an MS as well, but I didn't even bother ($) translating it, because it wasn't necessary.
2,409,759
[Problem](https://bugzilla.mozilla.org/show_bug.cgi?id=519028) exists only on FireFox (from 3.6 up to current 9), other browsers are fine. My code looks like this: ``` jQuery.extend({ AnchorFromUrl : function(url) { var anchor = url.substr(1).replace('.html',''); $.fizzer_anchor = anchor; w...
2010/03/09
[ "https://Stackoverflow.com/questions/2409759", "https://Stackoverflow.com", "https://Stackoverflow.com/users/281106/" ]
I had the same problem, but found this interesting post and it worked for me, its just adding 2 lines of javascript. The problem occure when the hash element changes, so, we need to re-stablish it via javascript <http://kilianvalkhof.com/2010/javascript/the-case-of-the-disappearing-favicon/> this is the code ``` fun...
I noticed this behaviour, too. Every now and then Firefox drops a favicon or it refuses to put the favicon alongside my bookmark. I think this is a Firefox bug. To workaround this (and for other functionality), I installed the [Favicon Picker add-on](https://addons.mozilla.org/en-US/firefox/addon/7849). Of course, thi...
2,409,759
[Problem](https://bugzilla.mozilla.org/show_bug.cgi?id=519028) exists only on FireFox (from 3.6 up to current 9), other browsers are fine. My code looks like this: ``` jQuery.extend({ AnchorFromUrl : function(url) { var anchor = url.substr(1).replace('.html',''); $.fizzer_anchor = anchor; w...
2010/03/09
[ "https://Stackoverflow.com/questions/2409759", "https://Stackoverflow.com", "https://Stackoverflow.com/users/281106/" ]
It worked for me : ``` var link = document.createElement('link'); link.type = 'image/x-icon'; link.rel = 'shortcut icon'; link.href = 'FAV_ICON_URL'; document.getElementsByTagName('head')[0].appendChild(link); ``` Refer : [Changing Website Icon Dynamically](https://stackoverflow.com/a/260876/644011)
I noticed this behaviour, too. Every now and then Firefox drops a favicon or it refuses to put the favicon alongside my bookmark. I think this is a Firefox bug. To workaround this (and for other functionality), I installed the [Favicon Picker add-on](https://addons.mozilla.org/en-US/firefox/addon/7849). Of course, thi...
2,409,759
[Problem](https://bugzilla.mozilla.org/show_bug.cgi?id=519028) exists only on FireFox (from 3.6 up to current 9), other browsers are fine. My code looks like this: ``` jQuery.extend({ AnchorFromUrl : function(url) { var anchor = url.substr(1).replace('.html',''); $.fizzer_anchor = anchor; w...
2010/03/09
[ "https://Stackoverflow.com/questions/2409759", "https://Stackoverflow.com", "https://Stackoverflow.com/users/281106/" ]
I had the same problem, but found this interesting post and it worked for me, its just adding 2 lines of javascript. The problem occure when the hash element changes, so, we need to re-stablish it via javascript <http://kilianvalkhof.com/2010/javascript/the-case-of-the-disappearing-favicon/> this is the code ``` fun...
It worked for me : ``` var link = document.createElement('link'); link.type = 'image/x-icon'; link.rel = 'shortcut icon'; link.href = 'FAV_ICON_URL'; document.getElementsByTagName('head')[0].appendChild(link); ``` Refer : [Changing Website Icon Dynamically](https://stackoverflow.com/a/260876/644011)
20,386,499
I'm working on a system for serialization/deserialization, and I'm trying to get some really fancy stuff going with functions. My goal is to serialize objects containing functions in a human-readable and reversible manner (the serialized files will need processing after the loadfile() step). I need a way to get the act...
2013/12/04
[ "https://Stackoverflow.com/questions/20386499", "https://Stackoverflow.com", "https://Stackoverflow.com/users/996118/" ]
Using `debug.getinfo` you can get `source`, `linedefined`, and `lastlinedefined`. Unless you format your code really weirdly you should be able to extract the complete code of your function from this info. There is no need to parse code, just to get the correct set of lines.
You want to disasseble the bytecode into Lua statements and expressions. Try <http://chunkspy.luaforge.net/>. Or maybe <http://luadec.luaforge.net/> but I haven't used them so can't give much more info. Luac (Lua compiler) also has -l switch which produces assembly listing that could potentially be parsed. Then there i...
32,388,991
I have 4 files index.html page1.html page2.html page3.html Here's my code... ``` page3.html <ons-page> <ons-tabbar> <ons-tab page="home.html" active="true"> <ons-icon icon="ion-home"></ons-icon> <span style="font-size: 14px">Home</span> </ons-tab> <ons-tab page="favo.html" active="tr...
2015/09/04
[ "https://Stackoverflow.com/questions/32388991", "https://Stackoverflow.com", "https://Stackoverflow.com/users/5226610/" ]
A simple and efficient method would be to use pub/sub method, but with callbacks rather than events. Here is what I would do: ``` <html ng-app="ClickGame"> <body ng-controller="MainController"> <p><button type="button" ng-click="click()">Click me!</button></p> <p>You have clicked {{ timesClicked }} times.</p> ...
``` Inject Achievement Service in controller and put this service in your scope app.controller('MainController' , ['Achievements' ,function(Achievements){ $scope.achivement = Achievements; //Put this service in your scope $scope.$watch('achivement.Player.links',function(newVal,oldVal){ //do...
29,195,173
How do I process tokens in the TfvcRelease 12 build template for TFS and Release Management 2013.4? I have both web.config and web.config.tokens files. I've seen this way: <http://www.colinsalmcorner.com/post/webdeploy-and-release-management--the-proper-way> But it also looks like this can be a solution: ``` /p:Us...
2015/03/22
[ "https://Stackoverflow.com/questions/29195173", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1372525/" ]
Create an editor Object first : ``` SharedPreferences.Editor editor = prefs.edit(); ``` And use the editor object to store and fetch your string set like this : ``` editor.putStringSet("List", set); editor.apply(); Set<String> fetch = editor.getStringSet("List", null); ```
You could write your results to a JSON String and store them in Shared Preferences like this: <https://stackoverflow.com/a/5968562/617044> But if you choose to go down the route you're currently on then you're going to have to store a parcelable. As noted in another answer; you can use putStringSet(), getStringSet() ...
11,011,823
I have the latest FF and I am trying to embed a video using the video tag. I saved the file on my desktop with test.html and my video is also at the desktop This is the code I'm using ``` <!DOCTYPE html> <html> <body> <video controls> <source src="Wildlife.wmv"> Your browser doesn't support video, you may downlo...
2012/06/13
[ "https://Stackoverflow.com/questions/11011823", "https://Stackoverflow.com", "https://Stackoverflow.com/users/803183/" ]
Browsers don't use wmv as the codec isn't widely avaliable - use mp4, ogg or webm depending on the browser. <http://camendesign.com/code/video_for_everybody> is a brilliant resource for learning about the intricacies here.
You can try this ``` <body> <object width="50%" height="50%" type="video/x-ms-asf" url="Wildlife.wmv" data="Wildlife.wmv" classid="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6"> <param name="url" value="Wildlife.wmv"> <param name="filename" value="Wildlife.wmv"> <param name="autostart" value="1"> <param name="uiM...
11,011,823
I have the latest FF and I am trying to embed a video using the video tag. I saved the file on my desktop with test.html and my video is also at the desktop This is the code I'm using ``` <!DOCTYPE html> <html> <body> <video controls> <source src="Wildlife.wmv"> Your browser doesn't support video, you may downlo...
2012/06/13
[ "https://Stackoverflow.com/questions/11011823", "https://Stackoverflow.com", "https://Stackoverflow.com/users/803183/" ]
Browsers don't use wmv as the codec isn't widely avaliable - use mp4, ogg or webm depending on the browser. <http://camendesign.com/code/video_for_everybody> is a brilliant resource for learning about the intricacies here.
Try this if you are running your application on various user agents. ``` <!DOCTYPE html> <html> <body> <video controls> <source src="Wildlife.mp4" type="video/mp4"> <source src="Wildlife.ogg" type="video/ogg"> <source src="Wildlife.webm" type="video/webm"> Your browser doesn't support ...
10,265,935
I am not able to execute pthreads program in c. Please tell me what is wrong with the following program. I am neither getting any error nor expected output. ``` void *worker(void * arg) { int i; int *id=(int *)arg; printf("Thread %d starts\n", *id ); } void main(int argc, char **argv) { int thrd_no,i,*thrd_id...
2012/04/22
[ "https://Stackoverflow.com/questions/10265935", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1265751/" ]
`thrd_no = atoi(argv[1] - 1);` likely doesn't do what you intended; the way `argv` is normally passed into a new process and parsed into a C array, `argv[1] - 1` is probably pointing at `\0` (specifically, the `\0` at the end of `argv[0]`). (More generally, indexing backwards off the start of a string is rarely correct...
You are passing the same address `&rank` to each thread, so `id` and `*id` is the same for all your `worker`-s. You should better allocate on the heap the address you pass to each worker routine. You might also include `<stdint.h` and use `intptr_t`, e.g. ``` void worker (void* p) { intptr_t rk = (intptr_t) p...