This file contains 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
INSERT INTO mydb.test2 SELECT * FROM mydb.test | |
The above query will copy all data from test table to test2 table. |
This file contains 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
create table mydb.test2 like mydb.test; | |
This file contains 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
sudo apt-get install php5-curl |
This file contains 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
find /var/www/joomla -type f -exec chmod 0644 {} \; | |
find /var/www/joomla -type d -exec chmod 0755 {} \; |
This file contains 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 JHTML::_('behavior.modal'); ?> | |
<a href="index.php?option=com_users&view=registration&tmpl=component" class="modal" rel="{handler: 'ajax',size: {x: 600, y: 450}}">Register Now For Deal</a> |
This file contains 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
#!/bin/sh | |
#sudo apt-get install linux-headers-3.5.0-21-generic | |
sudo apt-get install linux-headers-$(uname -r) | |
sudo apt-get remove virtualbox-dkms | |
sudo apt-get install virtualbox-dkms |
This file contains 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
function createTableFromJSON(jsonObj){ | |
var table=''; | |
var tableHeader=jsonObj[0]; | |
table+='<table>'; | |
table+='<thead><tr>'; | |
for(index in tableHeader){ | |
table+='<th>'+index+'</th>'; | |
} | |
table+='</tr></thead>'; | |
table+='<tbody>'; |
This file contains 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
mysqldump -h DBHOST -u DBUSER -p --single-transaction DBNAME > data.sql |
This file contains 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
mysql -h DBHOST -u DBUSER -pDBPASS DBNAME < backup/data.sql |
This file contains 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
Backup | |
mysqldump -p -u username database_name > dbname.sql | |
Restore | |
mysql -p -u username database_name < file.sql |