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 | |
| /* | |
| // save this file to: ExcelService.class.php | |
| Create new folder 'libs' under your project dir, and download PHPExcel-1.8 library .zip from here.. | |
| use this clone url: [email protected]:PHPOffice/PHPExcel.git | |
| OR https://github.com/PHPOffice/PHPExcel. | |
| */ | |
| define('TMP_FILES', "../temp/"); // temp folder where it stores the files into. |
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 | |
| /** | |
| * Create a web friendly URL slug from a string. | |
| * | |
| * Although supported, transliteration is discouraged because | |
| * 1) most web browsers support UTF-8 characters in URLs | |
| * 2) transliteration causes a loss of information | |
| * | |
| * @author Sean Murphy <[email protected]> | |
| * @copyright Copyright 2012 Sean Murphy. All rights reserved. |
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
| # Get Graphics Magick | |
| > cd / | |
| > mkdir /dowload | |
| > cd /download | |
| > wget ftp://ftp.graphicsmagick.org/pub/GraphicsMagick/GraphicsMagick-LATEST.tar.gz | |
| > tar -xzvf GraphicsMagick-LATEST.tar.gz | |
| > cd GraphicsMagick-1.3.21 (or the lastest graphics magick) | |
| # Install Graphics Magick | |
| ## Get libs |
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
| #!/usr/bin/env bash | |
| # | |
| # Script to install Magento2 | |
| # | |
| # @author Raj KB <[email protected]> | |
| # @website http://www.magepsycho.com | |
| # @version 0.1.0 | |
| # UnComment it if bash is lower than 4.x version |
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
| PATH_TO_MAGENTO='/path/to/magento/installation/folder' | |
| GITHUB_TOKEN='github-token-here' | |
| MAGENTO_USER='your-key-here' | |
| MAGENTO_PASS='your-pass-here' | |
| MAGENTO_ADMIN_URL='http://your-server.com' | |
| MAGENTO_ADMIN_USER='admin' | |
| MAGENTO_ADMIN_PASS='admin123' | |
| # ondrej best php apt-repository for php to be able to | |
| # update and install PHP as needed |
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 | |
| /** | |
| * A simple fix for a shell execution on preg_match('/[0-9]\.[0-9]+\.[0-9]+/', shell_exec('mysql -V'), $version); | |
| * The only edit that was done is that shell_exec('mysql -V') was changed to mysql_get_server_info() because not all | |
| * systems have shell access. XAMPP, WAMP, or any Windows system might not have this type of access. mysql_get_server_info() | |
| * is easier to use because it pulls the MySQL version from phpinfo() and is compatible with all Operating Systems. | |
| * @link http://www.magentocommerce.com/knowledge-base/entry/how-do-i-know-if-my-server-is-compatible-with-magento | |
| * @author Magento Inc. | |
| */ |
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 | |
| /* | |
| replacing the default "Enter title here" placeholder text in the title input box | |
| with something more descriptive can be helpful for custom post types | |
| place this code in your theme's functions.php or relevant file | |
| source: http://flashingcursor.com/wordpress/change-the-enter-title-here-text-in-wordpress-963 | |
| */ |
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
| server { | |
| # see: http://wiki.nginx.org/Pitfalls | |
| # see: http://wiki.nginx.org/IfIsEvil | |
| listen 80; | |
| root /app; | |
| index index.html index.htm index.php; | |
| error_page 404 /index.php; | |
| # Make site accessible from http://set-ip-address.xip.io |
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 | |
| // store {utm_campaign}, {utm_source} and {utm_medium} vars in cookies | |
| add_action( 'init', function() { | |
| $keys = array( 'utm_source', 'utm_medium', 'utm_campaign' ); | |
| foreach( $keys as $key ) { | |
| if( ! empty( $_GET[ $key ] ) ) { | |
| $value = (string) $_GET[ $key ]; | |
| setcookie( $key, $value, time()+3600, '/'); | |
| } |
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
| <?xml version="1.0"?> | |
| <layout> | |
| <default> | |
| <!--Root/Default Layouts--> | |
| <reference name="root"> | |
| <!--Appending Block--> | |
| <block type="page/html_breadcrumbs" name="breadcrumbs" as="breadcrumbs"/> | |
| </reference> | |
| <!--CSS and JS Files--> |
NewerOlder