PHPÀàʵÀý½Ì³Ì£¨Ê®°Ë£©£ºÉè¼Æģʽ֮ģ°æģʽ
³éÏóÀàµÄÓ¦ÓþÍÊǵäÐ͵ÄÄ£°æģʽ£¬ÏÈÉùÃ÷Ò»¸ö²»Äܱ»ÊµÀý»¯µÄÄ£°æ£¬ÔÚ×ÓÀàÖÐÈ¥ÒÀÕÕÄ£°æʵÏÖ¾ßÌåµÄÓ¦Óá£
Ä£°æģʽʵÀý
ÎÒÃÇдÕâÑùÒ»¸öÓ¦Óãº
ÒøÐмÆËãÀûÏ¢£¬¶¼ÊÇÀûÂʳËÒÔ±¾½ðºÍ´æ¿îʱ¼ä£¬µ«¸÷ÖÖ´æ¿î·½Ê½¼ÆËãÀûÂʵķ½Ê½²»Í¬£¬ËùÒÔ£¬ÔÚÕË»§Õâ¸öÀàµÄÏà¹Ø·½·¨Àֻ´î³öËã·¨µÄ¹Ç¼Ü£¬µ«²»¾ßÌåʵÏÖ¡£¾ßÌåʵÏÖÓɸ÷¸ö×ÓÀàÀ´Íê³É¡£
<?php
//³ÌÐòÉè¼ÆģʽµÄÄ£¿é²¿·Ö
abstract class LoadAccount
{
//ÀûÏ¢£¬±¾½ð
protected $interest, $fund;
public function calculateInterest() {
//È¡µÃÀûÂÊ
$this->interest = getInterestRate();
//ÓÃÓÚ¼ÆËãÀûÏ¢µÄËã·¨£º±¾½ð*ÀûÂÊ£¬µ«ÊÇÀûÂʵÄË㷨ʵÏÖ²¢Ã»ÓÐÔÚÕâ¸öÀàÖÐʵÏÖ
$this->interest = $this->getFund() * $this->getInterstRate();
return $this->interest;
}
private function getFund() {
return $this->fund;
}
//.......
/*
* ²»Í¬ÀàÐ͵Ĵæ¿îµÄÀûÂʲ»Í¬£¬Òò´Ë£¬
* ²»ÔÚÕâ¸ö¸¸ÀàÖÐʵÏÖÂʵļÆËã·½·¨£¬
* ¶ø½«ËûÍƳٵ½×ÓÀàÖÐʵÏÖ
*/
protected abstract function getInterstRate();
}
?>
ËùÓкͼÆËãÀûÏ¢µÄÀ඼¼Ì³Ð×ÔÕâ¸öÀ࣬¶øÇÒ±ØÐëʵÏÖÆäÖÐµÄ getInterestRate() ·½·¨£¬ÕâÖÖÓ÷¨¾ÍÊÇÄ£°æģʽ¡£
Ïà¹ØÎĵµ£º
windowsÏÂ:
1.ÏÂÔØÓÃÓÚ Windows µÄ Instant Client Basic ³ÌÐò°ü:http://download.oracle.com/otn/nt/instantclient/111070/instantclient-basic-win32-11.1.0.7.0.zip
2.½âѹËõ
´´½¨Ò»¸ö×ÓĿ¼£¨ÀýÈ磬d:\oci£©£¬È»ºó´ÓѹËõÎļþÖи´ÖÆÒÔÏ¿⣺
oraociei10.dll
orannzsbb10.dll
oci.dll
µ½´ËĿ¼ÏÂ
´ò¿ªPHP.ini ......
ÔÚ±¾ÎÄÖУ¬ÎÒÃǽ«Ñ§Ï°ÈçºÎͨ¹ýPHP 5µÄÒ»¸ö»ù±¾³éÏóÀàʹÓÃÍâ¼üÔ¼ÊøÀ´¸üÐÂÁ½¸öInnoDB±íµÄÊý¾Ý¡£ ÎÒÃǽ«Í¨¹ý¾ßÌåʾÀýÀ´ËµÃ÷ÈçºÎͨ¹ý·þÎñÆ÷¶Ë½Å±¾ÓïÑÔÀ´Ê¹ÓÃÍâ¼üÔ¼Êø¡£
¡¡¡¡Ò»¡¢ÀûÓÃÍâ¼üÔ¼Êø¸üÐÂMySQLÖеÄÊý¾Ý
¡¡¡¡ÏÖÔÚ£¬×îÁ÷ÐеĿªÔ´¹ØϵÐÍÊý¾Ý¿â¹ÜÀíϵͳ·ÇMySQLĪÊô£¬¶øMySQLÓÖÖ§³Ö¶à¸ö´æ´¢ÒýÇ棬ÆäÖÐĬÈϵÄÒ²ÊÇËٶȽϿìµÄ´ ......
PHP£¬Ò»¸öǶÌ×µÄËõдÃû³Æ£¬ÊÇÓ¢Îij¬¼¶Îı¾Ô¤´¦ÀíÓïÑÔ£¨PHP:Hypertext Preprocessor£©µÄËõд¡£PHP ÊÇÒ»ÖÖ HTML ÄÚǶʽµÄÓïÑÔ£¬PHPÓë΢ÈíµÄASPÆÄÓм¸·ÖÏàËÆ£¬¶¼ÊÇÒ»ÖÖÔÚ·þÎñÆ÷¶ËÖ´ÐеÄǶÈëHTMLÎĵµµÄ½Å±¾ÓïÑÔ£¬ÓïÑԵķç¸ñÓÐÀàËÆÓÚCÓïÑÔ£¬ÏÖÔÚ±»ºÜ¶àµÄÍøÕ¾±à³ÌÈËÔ±¹ã·ºµÄÔËÓá£PHP ¶ÀÌصÄÓï·¨»ìºÏÁË C¡¢Java¡¢Perl ÒÔ¼° PHP ×Ô ......
Ç°¼¸ÌìÔÚFirebugÀ©Õ¹¿ª·¢Ò»ÎÄÖоÍÌáµ½¹ýFirephpÕâ¸ö»ùÓÚFirebugµÄ²å¼þ£¬Í¨¹ýʹÓÃFirephpÄã¿ÉÒÔÔÚFirebugµÄConsoleÀ¸Öп´µ½Òªµ÷ÊÔµÄÊý¾Ý£¬¶ø²»Ó°Ïìphp³ÌÐòµÄÕý³£Ö´ÐУ¬ËùÒÔ˵£¬ÕⶫÎ÷¶ÔÓÚAjax¿ª·¢ÊǺÜÓаïÖúµÄ£¡ÏÂÃæÒ»ÆðÀ´¿´ÏÂFirephpµÄʹÓ÷½·¨¡£
µÚÒ»²½£º°²×°
1.Èç¹ûÄãµÄFireFoxûÓÐFirebugÕâ¸ö²å¼þµÄ»°£¬Ê×ÏÈÒª°²×°Fire ......
Îö¹¹º¯Êý£ºµ±Ä³¸ö¶ÔÏó³ÉΪÀ¬»ø»òÕßµ±¶ÔÏó±»ÏÔʽÏú»ÙʱִÐС£
GC(Garbage Collector)
ÔÚPHPÖУ¬Ã»ÓÐÈκαäÁ¿Ö¸ÏòÕâ¸ö¶ÔÏóʱ£¬Õâ¸ö¶ÔÏó¾Í³ÉΪÀ¬»ø¡£PHP»á½«ÆäÔÚÄÚ´æÖÐÏú»Ù¡£ÕâÊÇPHPµÄGC(Garbage Collector)À¬»ø´¦Àí»úÖÆ£¬·ÀÖ¹ÄÚ´æÒç³ö¡£µ±Ò»¸öPHPÏ߳̽áÊøʱ£¬µ±Ç°Õ¼ÓõÄËùÓÐÄÚ´æ¿Õ¼ä¶¼»á±»Ïú»Ù£¬µ±Ç°³ÌÐòÖеÄËùÓжÔÏóͬÑù± ......