This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Custom interface that enables communication between Fragment and its Activity | |
public interface OnItemSelectedListener | |
{ | |
public void onItemSelected(String item); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// In Activity: | |
@Override | |
public void onTabSelected(ActionBar.Tab tab, | |
FragmentTransaction fragmentTransaction) { | |
// When the given tab is selected, switch to the corresponding page in | |
// the ViewPager. | |
mViewPager.setCurrentItem(tab.getPosition()); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Form Data Submit</title> | |
<link rel="stylesheet" href="css/bootstrap.css"> | |
<style> | |
#contact label.error { | |
color: #e9266d; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) sudo vim /etc/udev/rules.d/51-android.rules | |
Add SUBSYSTEM=="usb", ATTR{idVendor}=="0bb4", MODE="0666", | |
ATTR{idVendor}=="0bb4" > this is your mobile device vendor | |
for more info please find following url | |
https://developer.android.com/studio/run/device.html | |
2) sudo chmod 644 /etc/udev/rules.d/51-android.rules |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Regular expression for extracting tag attributes | |
<name attribute=value attribute="value" attribute='value'> | |
(\S+)=["']?((?:.(?!["']?\s+(?:\S+)=|[>"']))+.)["']? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
::-webkit-input-placeholder { | |
color: red; | |
} | |
input:-moz-placeholder { /* Firefox 18- */ | |
color: red; | |
} | |
input::-moz-placeholder { /* Firefox 19+ */ | |
color: red; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$key = "secret_key"; | |
$data ="String"; | |
// Encodeing | |
$encoded = base64_encode(mcrypt_encrypt(MCRYPT_RIJNDAEL_256, md5($key), $data, MCRYPT_MODE_CBC, md5(md5($key)))); | |
// Decoding | |
$decoded = rtrim(mcrypt_decrypt(MCRYPT_RIJNDAEL_256, md5($key), base64_decode($encoded), MCRYPT_MODE_CBC, md5(md5($key))), "\0"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// jQuery Plugin Boilerplate | |
// A boilerplate for kick-starting jQuery plugins development | |
// version 1.3, May 07th, 2011 | |
// by Stefan Gabos | |
// with help from Roger Padilla, Shinya, JohannC, Steven Black, Rob Lifford | |
// remember to change every instance of "pluginName" to the name of your plugin! | |
(function($) { | |
// here it goes! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.htaccess.sample | |
.modgit/ | |
.modman/ | |
app/code/community/Phoenix/ | |
app/code/community/Cm/ | |
app/code/core/ | |
app/design/adminhtml/default/default/ | |
app/design/frontend/base/ | |
app/design/frontend/rwd/ | |
app/design/frontend/default/blank/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$("#input").autocomplete({ | |
open: function(event, ui) { | |
$('.ui-autocomplete').off('menufocus hover mouseover mouseenter'); | |
} | |
}); |