Projekt

Obecné

Profil

« Předchozí | Další » 

Revize 1068

Přidáno uživatelem Michal Kliment před asi 13 roky(ů)

Oprava chyby pri editaci podsiti, viz http://vyuka.slfree.net/mod/forum/discuss.php?d=1754

Zobrazit rozdíly:

freenetis/branches/testing/application/vendors/unit_tester/unit_testing_config.xml
</input>
</values>
</method>
<method name="phone_invoice_user_state2" autogenerate="on">
<attributes>
<attribute name="item" default_value="" />
<attribute name="name" default_value="" />
</attributes>
<values>
<input>
<param value="" />
<param value="" />
</input>
</values>
</method>
<method name="phone_period_field" autogenerate="off">
<attributes>
<attribute name="item" default_value=""/>
freenetis/branches/testing/application/helpers/network.php
*/
public static function netmask2cidr($netmask)
{
if (!preg_match("/^\d+.\d+.\d+.\d+$/", $netmask))
if (!preg_match("/^\d+\.\d+\.\d+\.\d+$/", $netmask))
{
return false;
}
......
}
/**
* Converts netmask in CIDR format (eg. /24) to classic format (255.255.255.0)
* Converts netmask in CIDR format (eg. 24) to classic format (255.255.255.0)
*
* @author Michal Kliment
* @param string $cidr
......
*/
public static function cidr2netmask ($cidr)
{
if (!preg_match("/^\d+.\d+.\d+.\d+$/", $cidr))
if (!preg_match("/^\d+$/", $cidr))
{
return false;
}

Také k dispozici: Unified diff