Author: kubilay

html2canvas- Take Screenshot of Web Page and Save It to Server (JavaScript and PHP)

FeedBack is important. Usually, end-users struggle to clarify their problems. And you might be unreachable for a phone call or remote connection. That causes a huge need of visualization. First solution that appears in mind is to capture the current screen of user. However, when I tried to implement that, it wasn’t so easy as […]

JavaScript: Export HTML Table to Excel With Custom File Name

Web browser wars hurt developers’ hearts. It is mostly about CSS, sometimes about JavaScript, HTML etc… Thus I know how it feels when you expect something to get done easily appears a lot more harder than you expected. Code below is tested only with Chrome (24+). It is making these processes: Gets the HTML code […]

PHP Coding Standards (pear.php.net)

https://pear.php.net/manual/en/standards.php Always use to delimit PHP code, not the <? ?> shorthand. Control statements should have one space between the control keyword and opening parenthesis, to distinguish them from function calls. You are strongly encouraged to always use curly braces even in situations where they are technically optional. Split long if statements onto several lines […]

Selecting Grouped Row Count When Using MySQL GROUP BY Column

You may have been using subqueries to get how many rows were grouped when using MySQL’s GROUP BY function. There’s a little trick that helps to get this number without using subqueries, more clean and faster (when the amount of rows get higher). Let’s assume we have a table contain folks from different cities. Like […]