error_reporting(E_ALL);
ini_set('display_errors', 1);
You can remember the all Shakespeare’s sonnets, but not those 2 lines.
Mediaart provides professional website design and web development services.
error_reporting(E_ALL);
ini_set('display_errors', 1);
You can remember the all Shakespeare’s sonnets, but not those 2 lines.
Yii is a high-performance PHP framework, not so complicated like Symphony or Zend.
The graph below shows how efficient Yii is. We compared Yii with other PHP frameworks.
In the graph, RPS (request per second) describes how many requests an application can process per second. The higher the number, the more efficient a framework is.
As we can see that Yii outperforms all other frameworks in this comparison. The performance advantage of Yii is especially significant when the widely used APC extension is enabled.
all what you need ;)
To test this framework, i create an online CV – www.kasparaitis.lt.
I have seen it was easy and intresting.
Further development of this project and will write a more detailed description.
If you are looking framework, why not Yii? Easy for beginners and full of features for more advanced users.
You also have option of disabling the AjaxUI for modules or across the entire system.
From 6.3 version, SugarCrm have admin section for disabling the AjaxUI on a per module basis (/index.php?module=Administration&action=ConfigureAjaxUI).
It can also be done manually in the config override with a line like:
$sugar_config['addAjaxBannedModules'][] = "Acounts";
That would cause links to the Acounts module in SugarCrm no longer attempt to load via the AjaxUI, and use the normal URL structure.
If You want, you have also option of totally disabling the AjaxUI with the following code.
$sugar_config['disableAjaxUI']
Today’s chalenge: How to remove the duplicate values from a PHP array?
after short search i found solution array_unique.
How this function works:
<?php
$input = array(1, 2, 2, 3, 3, 4);
$result = array_unique($input);
var_dump($result); ?>
will output:
array(4) {
[0]=> int(1)
[1]=> int(2)
[3]=> int(3)
[5]=> int(4)
}
Remember: Output of array_unique() will have the same key of input array.
US people have been able to use the Google Currents app to read various websites with magazine-style layout.
Now other countries can finally get in on the act as well. Google has release version 1.1 of the app for Android and iOS.
New version makes the service available worldwide with support for 44 languages, adds a number of other improvements:
And the best – app is completely free, and adapts the layout to suit both phones and tablets.
Scan QR code below to download it for the platform of your choice.
Some times when working in PHP you need a way to convert an XML document into a serializable array. If you ever tried to serialize() and then unserialize() a SimpleXML or DOMDocument object, you know what I’m talking about.
Assume the following XML snippet:
<tv>
<show name="The Simpsons">
<husband>Homer</husband>
<wife>Marge</wife>
<kid>Bart</kid>
<kid>Lisa</kid>
<kid>Maggie</kid>
</show>
</tv>
I found quick but little dirty way to do convert such axml document to an array, using type casting and JSON functions. After this i can ensure there are no exotic values that would cause problems when unserializing:
<?php
$a = json_decode(json_encode((array) simplexml_load_string($tv)),1);
?>
After this we get:
Array
(
[show] => Array
(
[@attributes] => Array
(
[name] => The Simpsons
)
[husband
] =>Homer
[wife
] =>Marge
[kid] => Array ( [0] => Bart [1] => Lisa [2] =>) ) )
Maggie
DONE!
the Android apps creation tool is no longer being managed by Google. MIT worked up its own version.
Now you can go and log into the MIT App Inventor with valid Google ID.
App Inventor lets you develop applications for Android phones using a web browser and either a connected phone or emulator. The App Inventor servers store your work and help you keep track of your projects.
You build apps by working with:
I have dates in the following format (yyyymmdd, 18751104, 19140722) and i need normal date (yyyy mm dd, 1875 11 04, 1914 07 22).
1. first you can use strtotime and date functions (this will fail with dates before the Unix epoch at the start of 1970. )
<?php
// prints 1995 Oct 12
echo date("Y M d", strtotime("19951012"));
?>
2. Alternative which will work with dates before 1970
<?php // Returns the year as an offset since 1900, negative for years before
$parts = strptime("18951012", "%Y%m%d");
$year = $parts['tm_year'] + 1900; // 1895
$day = $parts['tm_mday']; // 12
$month = $parts['tm_mon']; // 10 ?>
3. simple method – date_parse_from_format
<?php $parsed_date = date_parse_from_format('Ymd', $date); ?>
4. substr because it’s probably the lightest way to do it
mktime(substr($date, 0, 4), substr($date, 4, 2), substr($date, 6, 2));
I hate this task: „Delete default value of an input text on click„. Many times i use code like this
<input type="text" value="email@email.com" name="email"
onblur="if (this.value == '') {this.value = 'email@email.com';}"
onfocus="if (this.value == 'email@email.com') {this.value = '';}" />
Forget about this! I would recommend you try HTML5 solution below which uses the placeholder attribut.
<input name="Email" type="text" value="" placeholder="email@email.com" />
How do you heat your home? If that is wood pellets – you are about to visit the right place www.greenpellets.nl. The goal of the project is to provide Dutch people with environmentally friendly and high quality fuel for pocket friendly prices. More to come.