Archive : php

RSS feed
Open Sourcing @pushmail – An email app on SMS

Open Sourcing @pushmail – An email app on SMS

Hi all, I’m open sourcing my txtweb app @pushmail – An app that’ll send push email notifications via SMS. What is @pushmail It is an SMS app on the txtweb.com platform with which users can get instant email notifications via SMS. If they choose to, they can read full emails and reply to them. The user just has to setup a simple email forwarder.¬†http://suhastech.com/mail The “I [...]

[WAMP Server] Run PHP in Command line interface

Go to run –> type ‘cmd’ change directory to the PHP folder. You might have a different version. cd C:\wamp\bin\php\php5.3.5 Run your PHP command like “php -l file” etc.

How to fetch the new line / paragraph character “n” from a GET / POST request

Here’s a little code that I wrote to correctly fetch the newline character. By URL encoding “n” you get %OA which is not decoded back as a C style new line character “n”. So, we fetch the query string to manually decode it in the correct mechanism. This is a PHP example, the theory hold good for other languages as well. function get_string_parameters($string) { $result [...]

[Tiny Tip] Use is_numeric() instead of is_int() when you have a number as a string

If you have a number as a string is_int() won’t work. This will most probably clear your doubt. <?php var_dump(is_int(12)); var_dump(is_int("12")); ?> Output: bool(true) bool(false) <?php var_dump(is_numeric(56)); var_dump(is_numeric("56")); ?> Output: bool(true) bool(true) Happy Programming,
© 2011 Suhas Tech. All rights reserved.
Proudly powered by Wordpress.