Welcome to Sinaru’s thought vault!

  • A business name to Work

    I have bootstrapped myself work in Ruwalla. I needed to represent this as a business so I started my own business called Creotex that is doing web development.

  • Edit images while on WordPress

    Tip to update the images on WP. This feature comes inbuilt of WordPress. Go to media. Click on the image. Click edit image button. Then you will see a list of button that you can use to manipulate (rotate, scale…) the image. Once changed, it will affect all the places where the image is used.

  • Redirect from one host to another using Apache htaccess

    Redirect from one host to another using Apache htaccess RewriteCond %{HTTP_HOST} ^old-domain.com$ [NC] RewriteRule ^(.*)$ http://www.new-domain.com/$1 [R=301,L]

  • Speed up Selenium web-driver tests by disabling images and CSS

    Using Selenium Webdriver, we can manipulate and use a web browser programmatically. This is widely used in website testing as once a programmed script is written to run on a website, we can sit back and relax while the script is testing the desired outcomes of the website. Also there are many other use cases. […]

  • PDF version of Guide to MongoDB Indexes

    You can download the PDF version for MongoDB indexes on their official site at: http://docs.mongodb.org/master/MongoDB-indexes-guide.pdf

  • Fixing No Input File Specified error on Nginx + PHP

    Today I wanted to try out Nginx server my windows machine. After setting up the basic server block details for my project, I called the site URL. In the WT-NMP stack to quickly setup the software I needed. In the server block, I needed to specify my root path in a different location other than […]

  • Kalapaluwawa Sri Sudarshanarama Purana Viharaya

    Kalapaluwawa Sri Sudarshanarama Purana Viharaya

  • Setting up xdebug with phpstorm

    This guide provide a step by step details on how to set up phpstorm IDE to work with xdebug.   Installing on Ubuntu In software search for xdebug and install.   Add to the following xdebug settings to php.ini file   xdebug.remote_enable = 1 xdebug.remote_port = 9000 xdebug.remote_handler = dbgp xdebug.remote_mode = req     […]

  • Xpath vs CSS Selectors

    After researching and reviewing on whether to choose XPATH or CSS selector, the following are the points I came across.   Some points to CSS Generally CSS is easy to use and readable over XPATH. REF: http://www.seleniumhq.org/docs/appendix_locating_techniques.jsp#starting-to-use-css-instead-of-xpath   CSS is native to browsers and XPATH is not REF: http://old.eurostarconferences.com/blog/2013/1/28/liveblogged!-automated-web-testing-traps-for-the-unwary-with-simon-stewart CSS is preferred for testing as […]

  • NUC machines might be the next desktop killer

    While it seems like to CPU processing power is coming to a limitation, Intel is focusing on small form factor machines.