14Aug

CodeIgniter Smiley Helper Internet Explorer Compatibility Issue

FILED IN codeigniter | php No Comments

Last week I had some compatibility issues with the CodeIgniter Smiley Helper, it was working on all browser but the holy Internet Explorer.

I am not sure if the bug was fixed already, so if you are having this issue, this is what i did to fix it.

Open: system/helpers/smiley_helper.php

Line 39:

document.selection.createRange().text = text;

For some reason, Internet explorer says there’s an error there, I assume it is because the variable text does not exist within the function so I changed ‘text’ for ‘smiley’.

document.selection.createRange().text = smiley;

And it worked, Internet Explorer 6+

,

23Oct

AMFPHP Browser issue: Function eregi_replace() is deprecated

FILED IN amfphp | php 13 Comments

Have anyone had this problem? When you try using amfphp 1.9 beta browser to test your methods, you get an error like this:

Error retrieving service info:
Function eregi_replace() is deprecated
C:\${Your_address}\amfphp\core\shared\util\MethodTable.php on line 513

Well, the thing is since amfphp has practically no support anymore, since a newer version hasn’t been released in.. months? years? Who knows..

I googled a bit and I found the solution on a french forum. Looks like amfphp is throws this error because since I am using php5 on my server, the MethodTable script is using a deprecated function which needs to be updated in order to be functional again.

All you have to do to is go to: /amfphp/core/shared/utils and open the script MethodTable.php

Find the line 505, if you’re using Notepad++ which I recommend developers to use since it is pretty handy and lightweight, just use the shortcut Ctrl + G, type in the line number and there you go.

Now, you need to replace these three lines:

$comment = eregi_replace(“\n[ \t]+”, “\n”, trim($comment));
$comment = str_replace(“\n”, “\\n”, trim($comment));
$comment = eregi_replace(“[\t ]+”, ” “, trim($comment));

By these

$comment = preg_replace(“`\n[ \t]+`U”, “\n”,trim($comment));
$comment = str_replace(“\n”, “\\n”, trim($comment));
$comment = preg_replace(“`[\t ]+`U”, ” “,trim($comment));

And problem solved.

As you see, eregi_replace() is the php function that was giving us troubles, and if you check the php documentation the first thing you’ll see is a big warning sign telling you that this function is deprecated.

If anyone understand french, you can check the forum post where I find the solution: here

,

21Oct

Useful information about Flex 4 Spark Containers

FILED IN flex No Comments

I was watching a video about Flex 4 Containers and Layout a few minutes ago and I thought I’d like to post some information about it here.

Did you know…

Spark contains the following Containers:

Non-skinnable containers

  • Group
  • DataGroup

These containers CAN NOT have visual skins applied to them. Their only purpose is for laying out controls or other containers.

Skinnable containers

  • SkinnableContainer
  • SkinnableDataContainer
  • Panel
  • Application

These containers CAN have visual skin applied to them. Their purpose is not only to laying out controls and other containers but also have custom look & feel.

Of these four skinnable containers, only the Panel container have a default visual skin, the other three require that you apply a skin class to them.

That’s all for now but I am planning on posting more about the SkinnableDataContainer and the DataGroup containers. So stay tuned!

19Oct

Flex 4 Grayscale Skin – Built using Photoshop and Flash Catalyst Beta 2

FILED IN flashcatalyst | flex 3 Comments

Like I promised, my skin for the basic flex 4 components.

After I finished this, I realized how powerful Flash Catalyst is, I am looking forward to post a tutorial about the basics.

The Flash plugin is required to view this object.

You can download the FXP file here: Flex Skin Grayscale

,

TOP