Nokia QT: How to lock the phone orientation
I’m playing with QT to make a couple of apps for Nokia phone, here the first snippet: “How to lock the phone orientation”, in this case I will lock in Portrait position, even when the user rotate the phone, the screen won’t rotate The complete code:
include "QWebView" fail?
You maybe want to do this: #include QWebView and you get an error like “QWebView: No such file or directory”, The solucion is simple, you need to add the reference to the library in you your_project.pro file, just write: QT += webkit Save and Run
PHP: How to make time more readable?
If you need to transform php time (seconds) to a more “friendly” format, this is perfect, you can transform “251″ to “4 minutes, 11 seconds”
PHP: Como solucionar "Call to undefined function: json_encode()"
En PHP 5.2 y siguientes estan disponibles las funciones json_encode() y json_decode() donde pasando una arrary asociativo se puede generar el JSON con los datos, si estamos usando una version anterior (ya sea la 5.0) estas librerias no estan disponibles. Por suerte podemos usar estas librerias para los usuario que todavian tengan versiones viejas de PHP jsonwrapper.tar Una vez descargadas solo necesitamos: require ‘jsonwrapper.php’;
jQuery Mobile!!!
jQuery oficialmente la version Mobile de sus librerias, una excelente noticia para quienes nos estamos orientando a esas plataformas. The jQuery project is really excited to announce the work that we’ve been doing to bring jQuery to mobile devices. Not only is the core jQuery library being improved to work across all of the major mobile platforms, but we’re also working to release a complete, unified, mobile UI framework. http://jquerymobile.com/2010/08/announcing-the-jquery-mobile-project/ [...]
Iphone Multitasking Video Demo
Video demostracion de como funciona el multitasking en el iphone con el OS4 (ya disponible para desarrolladores), se puede ver el taskbar con las apps corriendo, solo falta probar cuantas apps se banca en memoria… chan! Source: http://www.mobilecrunch.com/2010/04/08/first-video-of-iphone-multitasking/
MiniTip: PHP Show Errors
No es el tip que va a cambiar el mundo, pero siempre que lo necesito tengo que buscarlo por google, son dos simples lineas que activa el reporte de error de PHP donde el php.ini lo deshabilita por defecto. A veces cuando testeamos un PHP con errores, simplemente muestra la pagina en blanco, esta es una señal de que está desactivado el reporte de errores. Ejemplo Mostrar todos los errores. [...]