I run into a strange bug with CakePHP 1.3.6. When debug mode set to 0 the browser don’t select the correct page encoding although the page header is set correctly. I don’t run into this bug with CakePHP 1.3.2. Any one has this problem?
CakePHP 1.3.6 debug mode and encoding
December 29, 2010AIR: IE changes Adobe .air files to .zip files when clicking to download
November 12, 2010The solution is in the server settings.
For Apache users add this line in “httpd.conf” :
AddType application/vnd.adobe.air-application-installer-package+zip .air
As always, I can developp if requested in the comments.
Flex PHP 5.1.6 and ZendAMF
September 1, 2010For those who are stuck with PHP 5.1.6 but still want to use ZendAMF it’s possible. You just have to avoid the new to php 5.2 “datetime” type. The trick is to convert date to timestamp interger to pass them over the wire.
I can develop if requested.
Wamp and SSL
August 30, 2010If you are looking for a way to set up SSL on your WAMP development environment, here is the solution:
http://www.webidsupport.com/forums/showthread.php?705-https-SSL-Under-WAMP
In my case setting the VirtualHost this way helped:
<VirtualHost 127.0.0.1:443>
instead of
<VirtualHost *:443>
If you still have errors don’t forget to check the errors and warnings in apache_error.log.
There is a lot of valuable info there.
Adobe Flex width height and scrollbar
August 23, 2010Here a little hack:
If you can’t get the scrollbar to show up on a container (Canvas, VBox, HBox) try to set the minHeight or minWidth. (Even with a very small value)
Flex DataGrid header background color
July 29, 2010if you try to set the DataGrid header background color for a target column, the solution is there:
http://ntt.cc/2009/02/18/set-background-color-for-headers-of-datagrid.html
Warning:
But it’s not perfect though. it doesn’t work when you use horizontal scroll.
Change DataGrid alternating cell background with an itemRenderer
July 29, 2010if you want to Change the DataGrid cell background with an itemRenderer, the solution is there:
If you want to get an alternating custom color, here a little hack:
g.beginFill(0xCC0033,0.02);
The second beginFill param is the alpha. By setting it low you get the alternating datagrid bg color and your custom item renderer bgcolor to blend, giving an alternating custom color background
It’s a hack but it works
CakePHP and static html pages
May 21, 2010So you are a crazy developer who understand everything about MVC etc.
But you work with designers who don’t want to hear about your view-layout-elements structure. All they want is to open static html pages of the site with dreamweaver and synchronize from there.
The solution: for complete static pages don’t use cake’s pages system. Just put mystaticpage.html file in the webroot and make links to it directly. It works just fine.
Designers will just synchronize the webroot and you can focus on the dynamic part.
Now if your top page is static too, you need to create a custom route.
Easy: create cake’s pages view and in the .ctp just use:
include “index.html”
PHP BUG with mb_convert_encoding EUC-JP and UTF-8
April 13, 2010This doesn’t work properly:
mb_convert_encoding($japtext, “UTF-8″, “EUC-JP”)
Instead you have to do this:
mb_convert_encoding(mb_convert_encoding($japtext,”sjis-win”,”EUC-JP”),”UTF-8″,”sjis-win”)
Strange but true. If you have any better solution, tell me.
Source:
http://www.asp-edita.jp/doda/one/doda5728_15.html
Flex TextInput focusOut callLater()
March 26, 2010If you use an Alert on focusOut from a TextInput that bring you back to the TextInput, use callLater() on a function that throw the Alert. It will stop bring you back to the TextInput