| @@ 333-343 (lines=11) @@ | ||
| 330 | * |
|
| 331 | * @return object |
|
| 332 | */ |
|
| 333 | public function add($value) |
|
| 334 | { |
|
| 335 | ||
| 336 | $this->date_interval_expression = str_replace( |
|
| 337 | $this->config[ 'date_simple' ], |
|
| 338 | $this->config[ 'date_interval' ], |
|
| 339 | $value |
|
| 340 | ); |
|
| 341 | ||
| 342 | $this->date_interval_expression = str_replace( |
|
| 343 | ' ', |
|
| 344 | '', |
|
| 345 | 'P' . $this->date_interval_expression |
|
| 346 | ); |
|
| @@ 363-373 (lines=11) @@ | ||
| 360 | * |
|
| 361 | * @return obejct |
|
| 362 | */ |
|
| 363 | public function sub($value) |
|
| 364 | { |
|
| 365 | ||
| 366 | $this->date_interval_expression = str_replace( |
|
| 367 | $this->config[ 'date_simple' ], |
|
| 368 | $this->config[ 'date_interval' ], |
|
| 369 | $value |
|
| 370 | ); |
|
| 371 | ||
| 372 | $this->date_interval_expression = str_replace( |
|
| 373 | ' ', |
|
| 374 | '', |
|
| 375 | 'P' . $this->date_interval_expression |
|
| 376 | ); |
|