Friday, December 4, 2015

YouTube video generated images -- for thumbnails

http://img.youtube.com/vi//default.jpg
http://img.youtube.com/vi//hqdefault.jpg    
http://img.youtube.com/vi//mqdefault.jpg    
http://img.youtube.com/vi//sddefault.jpg    
http://img.youtube.com/vi//maxresdefault.jpg   

source: http://stackoverflow.com/questions/2068344/how-do-i-get-a-youtube-video-thumbnail-from-the-youtube-api

Sunday, November 22, 2015

magento block types

For understanding more about magento block types following are some built-in block types which are widely used in layout.
  1. core/template: This block renders a template defined by its template attribute. The majority of blocks defined in the layout are of type or subtype of core/template.
  2. page/html: This is a subtype of core/template and defines the root block. All other blocks are child blocks of this block.
  3. page/html_head: Defines the HTML head section of the page which contains elements for including JavaScript, CSS etc.
  4. page/html_header: Defines the header part of the page which contains the site logo, top links, etc.
  5. page/template_links: This block is used to create a list of links. Links visible in the footer and header area use this block type.
  6. core/text_list: Some blocks like contentleftright etc. are of type core/text_list. When these blocks are rendered, all their child blocks are rendered automatically without the need to call thegetChildHtml() method.
  7. page/html_wrapper: This block is used to create a wrapper block which renders its child blocks inside an HTML tag set by the action setHtmlTagName. The default tag is 
     if no element is set.
  8. page/html_breadcrumbs: This block defines breadcrumbs on the page.
  9. page/html_footer: Defines footer area of page which contains footer links, copyright message etc.
  10. core/messages: This block renders error/success/notice messages.
  11. page/switch: This block can be used for the language or store switcher.
This is a list of only commonly used block types. There are many other block types which are used in advanced theme implementations.

Saturday, October 17, 2015

14 Monitors on a Single Windows 8 PC with USB Graphics Adapters

Tuesday, June 23, 2015

Yii 1.1 path

Yii::app()->getBaseUrl(true);   // => http://localhost/sample
Yii::app()->getHomeUrl();       // => /sample/index.php
Yii::app()->getBaseUrl(false);  // => /sample


Yii::app()->request->baseUrl // => /sample

Yii::app()->theme->baseUrl //=> sample/themes/bluetheme

Thursday, May 21, 2015

Composer Yii 2.0 update







































set the path to php.exe

A:\>
A:\>cd xampp
A:\xampp>cd php
A:\xampp\php>
A:\xampp\php>PATH="A:\xampp\php"


check the php version; should be greater than 5.4

A:\xampp\php>php -v
PHP 5.6.3 (cli) (built: Nov 12 2014 17:18:08)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2014 Zend Technologies


i copied the composer files from C:\Users\jerome\AppData\Local\ComposerSetup\bin
composer, composer.bat, composer.phar
i think only phar file is needed, anyways copied all the files into xampp/php folder

A:\xampp\php>dir
 Volume in drive A is Data
 Volume Serial Number is C629-A5C0

 Directory of A:\xampp\php

05/17/2015  03:22 PM              .
05/17/2015  03:22 PM              ..
06/18/2013  02:04 PM              cfg
05/16/2015  10:18 PM               587 composer
10/16/2013  06:21 PM                38 composer.bat
05/16/2015  10:18 PM         1,103,875 composer.phar


follow the instructions from 
http://www.yiiframework.com/download/
--install the composer asset plugin

A:\xampp\php>php composer.phar global require "fxp/composer-asset-plugin:1.0.0"
Changed current directory to C:/Users/jlabs/AppData/Roaming/Composer
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Nothing to install or update
Generating autoload files


install the project files

A:\xampp\php>php composer.phar create-project yiisoft/yii2-app-advanced ../htdocs/advanced 2.0.4
Installing yiisoft/yii2-app-advanced (2.0.4)
  - Installing yiisoft/yii2-app-advanced (2.0.4)
    Loading from cache

Created project in ../htdocs/advanced
Loading composer repositories with package information
Installing dependencies (including require-dev)
  - Installing yiisoft/yii2-composer (2.0.3)
    Loading from cache

  - Installing ezyang/htmlpurifier (v4.6.0)
    Loading from cache

  - Installing cebe/markdown (1.1.0)
    Loading from cache

  - Installing bower-asset/jquery (2.1.4)
    Loading from cache

  - Installing bower-asset/jquery.inputmask (3.1.63)
    Loading from cache

  - Installing bower-asset/punycode (v1.3.2)
    Loading from cache

  - Installing bower-asset/yii2-pjax (v2.0.4)
    Loading from cache

  - Installing yiisoft/yii2 (2.0.4)
    Loading from cache

  - Installing swiftmailer/swiftmailer (v5.4.0)
    Loading from cache

  - Installing yiisoft/yii2-swiftmailer (2.0.4)
    Loading from cache

  - Installing yiisoft/yii2-codeception (2.0.4)
    Loading from cache

  - Installing bower-asset/bootstrap (v3.3.4)
    Loading from cache

  - Installing yiisoft/yii2-bootstrap (2.0.4)
    Loading from cache

  - Installing yiisoft/yii2-debug (2.0.4)
    Loading from cache

  - Installing bower-asset/typeahead.js (v0.10.5)
    Loading from cache

  - Installing phpspec/php-diff (v1.0.2)
    Loading from cache

  - Installing yiisoft/yii2-gii (2.0.4)
    Loading from cache

  - Installing fzaninotto/faker (v1.4.0)
    Loading from cache

  - Installing yiisoft/yii2-faker (2.0.3)
    Loading from cache

Writing lock file
Generating autoload files





change the default jdk path in netbeans 8.0.2



















i have installed netbeans in
A:\Program Files\NetBeans 8.0.2\

go to
A:\Program Files\NetBeans 8.0.2\etc

edit
netbeans.conf

change line 57


netbeans_jdkhome="A:\Program Files\Java\jdk1.8.0_31"

netbeans_jdkhome="A:\Program Files\Java\jdk1.8.0_45"

Wednesday, May 13, 2015

Wednesday, April 15, 2015

Magento : Get Base Url , Skin Url , Media Url , Js Url , Store Url and Current Url

Get Url in phtml files

1. Get Base Url :

Mage::getBaseUrl();


2. Get Skin Url :

Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_SKIN);


(a) Unsecure Skin Url :

$this->getSkinUrl('images/imagename.jpg');


(b) Secure Skin Url :

$this->getSkinUrl('images/imagename.gif', array('_secure'=>true));


3. Get Media Url :

Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA);


4. Get Js Url :

Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_JS);


5. Get Store Url :

Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_WEB);


6. Get Current Url

Mage::helper('core/url')->getCurrentUrl();




Get Url in cms pages or static blocks

1. Get Base Url :

{{store url=""}}


2. Get Skin Url :

{{skin url='images/imagename.jpg'}}


3. Get Media Url :

{{media url='/imagename.jpg'}}


4. Get Store Url :

{{store url='mypage.html'}}

Wednesday, March 4, 2015

Enable Disabled Buttons in Windows

https://www.raymond.cc/blog/download/did/851/

the program must 10 years old, still works. click to enable, youll see the "on"



paletton.com ! Website Color Scheme



No Admin User for Windows 7 :) Manage to get back the admin

i wanted the CTRL + ALT + DEL login for window 7 Enterprise

playing around with the registry have to be careful, with no usb and windows dvd

i manage to remove the 4GB limit in my 32 bit windows 7 installation, its using all 10GB have to some more test and see :)

HKEY_LOCAL_MACHINE\
SOFTWARE\
Microsoft\
Windows NT\
CurrentVersion\
Winlogon\
SpecialAccounts\
UserList

i add the last two key






select the "UserList" key on the right side add user name as DWORD (32bit) Value

the "user" was a admin account, i couldnt logged into from command prompt or runas. it was like doomsday well not quite.

i tried to login into recovery mode "Repair Your Computer" option when you press F8























chose the command prompt option in the "System Recovery Options" menu

* i was to login using the admin account user




















net user Administrator /active:yes simple or capital didnt work

type regedt32.exe

in registry tool click
HKEY_LOCAL_MACHINE or HKLM

then click File -> Load Hive option


go to your windows drive, note the drive letters may be different

Windows\System32\config

click the SOFTWARE file and load it

add name u want myHive

goto

HKEY_LOCAL_MACHINE\
myHive\
Microsoft\
Windows NT\
CurrentVersion\
Winlogon\
SpecialAccounts\
UserList

delete the entries and make the value to 1

thats it.

About

Blogger templates