PageRenderTime 37ms queryTime 31ms sortTime 48ms getByIdsTime 1106ms findMatchingLines 80ms

100+ results results for 'php feof' (37 ms)

Not the results you expected?
trackback.php https://bitbucket.org/pastor399/newcastleunifc.git | PHP | 372 lines
                    
1<?php
                    
2/**
                    
2/**
                    
3 * PHP Class to handle TrackBacks (send/ping, receive, retreive, detect, seed, etc...)
                    
4 * 
                    
4 * 
                    
5 * <code><?php
                    
6 * include('trackback_cls.php');
                    
11 * 
                    
12 * @version $Id: trackback_cls.php,v 1.2 2004/12/11 18:54:32 Ran Exp $
                    
13 * @copyright Copyright (c) 2004 Ran Aroussi (http://www.blogish.org)
                    
14 * @author Ran Aroussi <ran@blogish.org> 
                    
15 * @license http://opensource.org/licenses/gpl-license.php GNU General Public License (GPL)
                    
16 * 
                    
91        // Gather result
                    
92        while (!feof($tb_sock)) {
                    
93            $response .= fgets($tb_sock, 128);
                    
                
file.php https://github.com/boluak/lifefm-github.git | PHP | 379 lines
                    
1<?php
                    
2/**
                    
2/**
                    
3 * @version		$Id: file.php 10707 2008-08-21 09:52:47Z eddieajau $
                    
4 * @package		Joomla.Framework
                    
6 * @copyright	Copyright (C) 2005 - 2008 Open Source Matters. All rights reserved.
                    
7 * @license		GNU/GPL, see LICENSE.php
                    
8 * Joomla! is free software. This version may have been modified pursuant
                    
11 * other free or open source software licenses.
                    
12 * See COPYRIGHT.php for copyright notices and details.
                    
13 */
                    
257			// 2b: The length of the data is less than the max amount we want
                    
258			while (!feof($fh) && (!$amount || strlen($data) < $amount)) {
                    
259				$data .= fread($fh, $chunksize);
                    
304	 *
                    
305	 * @param string $src The name of the php (temporary) uploaded file
                    
306	 * @param string $dest The path (including filename) to move the uploaded file to
                    
                
recaptchalib.php https://bitbucket.org/Mainboarder/s2firewall.git | PHP | 277 lines
                    
1<?php
                    
2/*
                    
2/*
                    
3 * This is a PHP library that handles calling reCAPTCHA.
                    
4 *    - Documentation and latest version
                    
4 *    - Documentation and latest version
                    
5 *          http://recaptcha.net/plugins/php/
                    
6 *    - Get a reCAPTCHA API Key
                    
74        $http_request .= "Content-Length: " . strlen($req) . "\r\n";
                    
75        $http_request .= "User-Agent: reCAPTCHA/PHP\r\n";
                    
76        $http_request .= "\r\n";
                    
85
                    
86        while ( !feof($fs) )
                    
87                $response .= fgets($fs, 1160); // One TCP-IP packet
                    
215	if (! function_exists ("mcrypt_encrypt")) {
                    
216		die ("To use reCAPTCHA Mailhide, you need to have the mcrypt php module installed.");
                    
217	}
                    
                
HttpClient.php https://bitbucket.org/kudutest/moodlegit.git | PHP | 352 lines
                    
1<?php
                    
2/**
                    
25 */
                    
26require_once 'Zend/Http/Client.php';
                    
27
                    
100        if (!$fp) {
                    
101            require_once 'Zend/Gdata/App/InvalidArgumentException.php';
                    
102            throw new Zend_Gdata_App_InvalidArgumentException('Failed to open private key file for AuthSub.');
                    
105        $key = '';
                    
106        while (!feof($fp)) {
                    
107            $key .= fread($fp, 8192);
                    
115     *
                    
116     * In order to call this method, openssl must be enabled in your PHP
                    
117     * installation.  Otherwise, a Zend_Gdata_App_InvalidArgumentException
                    
126        if ($key != null && !function_exists('openssl_pkey_get_private')) {
                    
127            require_once 'Zend/Gdata/App/InvalidArgumentException.php';
                    
128            throw new Zend_Gdata_App_InvalidArgumentException(
                    
                
functions.recaptchalib.php https://github.com/dkobia/Garden.git | PHP | 278 lines
                    
1<?php
                    
2/*
                    
2/*
                    
3 * This is a PHP library that handles calling reCAPTCHA.
                    
4 *    - Documentation and latest version
                    
4 *    - Documentation and latest version
                    
5 *          http://recaptcha.net/plugins/php/
                    
6 *    - Get a reCAPTCHA API Key
                    
74        $http_request .= "Content-Length: " . strlen($req) . "\r\n";
                    
75        $http_request .= "User-Agent: reCAPTCHA/PHP\r\n";
                    
76        $http_request .= "\r\n";
                    
85
                    
86        while ( !feof($fs) )
                    
87                $response .= fgets($fs, 1160); // One TCP-IP packet
                    
216   if (! function_exists ("mcrypt_encrypt")) {
                    
217      die ("To use reCAPTCHA Mailhide, you need to have the mcrypt php module installed.");
                    
218   }
                    
                
backupdb.php https://gitlab.com/Conors99/ppm-1.8 | PHP | 484 lines
                    
1<?php
                    
2/**
                    
52
                    
53$page->add_breadcrumb_item($lang->database_backups, "index.php?module=tools-backupdb");
                    
54
                    
61		flash_message($lang->error_file_not_specified, 'error');
                    
62		admin_redirect("index.php?module=tools-backupdb");
                    
63	}
                    
81		$handle = fopen(MYBB_ADMIN_DIR.'backups/'.$file, 'rb');
                    
82		while(!feof($handle))
                    
83		{
                    
90		flash_message($lang->error_invalid_backup, 'error');
                    
91		admin_redirect("index.php?module=tools-backupdb");
                    
92	}
                    
98	{
                    
99		admin_redirect("index.php?module=tools-backupdb");
                    
100	}
                    
                
BodyTest.php https://gitlab.com/jatasya/testSlimfrmwk | PHP | 401 lines
                    
1<?php
                    
2/**
                    
4 *
                    
5 * @link      https://github.com/slimphp/Slim
                    
6 * @copyright Copyright (c) 2011-2015 Josh Lockhart
                    
6 * @copyright Copyright (c) 2011-2015 Josh Lockhart
                    
7 * @license   https://github.com/slimphp/Slim/blob/master/LICENSE.md (MIT License)
                    
8 */
                    
13
                    
14class BodyTest extends \PHPUnit_Framework_TestCase
                    
15{
                    
42    {
                    
43        $stream = fopen('php://temp', $mode);
                    
44        fwrite($stream, $this->text);
                    
81
                    
82        $this->assertEquals('php://temp', $body->getMetadata('uri'));
                    
83    }
                    
                
test_ext_network.cpp https://github.com/tmjnaid/hiphop-php.git | C++ | 266 lines
                    
2   +----------------------------------------------------------------------+
                    
3   | HipHop for PHP                                                       |
                    
4   +----------------------------------------------------------------------+
                    
6   +----------------------------------------------------------------------+
                    
7   | This source file is subject to version 3.01 of the PHP license,      |
                    
8   | that is bundled with this package in the file LICENSE, and is        |
                    
9   | available through the world-wide-web at the following url:           |
                    
10   | http://www.php.net/license/3_01.txt                                  |
                    
11   | If you did not receive a copy of the PHP license and are unable to   |
                    
12   | obtain it through the world-wide-web, please send a note to          |
                    
13   | license@php.net so we can mail you a copy immediately.               |
                    
14   +----------------------------------------------------------------------+
                    
172    StringBuffer response;
                    
173    while (!same(f_feof(f), true)) {
                    
174      Variant line = f_fgets(f, 128);
                    
                
ext_file.h https://github.com/tmjnaid/hiphop-php.git | C Header | 161 lines
                    
2   +----------------------------------------------------------------------+
                    
3   | HipHop for PHP                                                       |
                    
4   +----------------------------------------------------------------------+
                    
5   | Copyright (c) 2010 Facebook, Inc. (http://www.facebook.com)          |
                    
6   | Copyright (c) 1997-2010 The PHP Group                                |
                    
7   +----------------------------------------------------------------------+
                    
7   +----------------------------------------------------------------------+
                    
8   | This source file is subject to version 3.01 of the PHP license,      |
                    
9   | that is bundled with this package in the file LICENSE, and is        |
                    
10   | available through the world-wide-web at the following url:           |
                    
11   | http://www.php.net/license/3_01.txt                                  |
                    
12   | If you did not receive a copy of the PHP license and are unable to   |
                    
13   | obtain it through the world-wide-web, please send a note to          |
                    
14   | license@php.net so we can mail you a copy immediately.               |
                    
15   +----------------------------------------------------------------------+
                    
                
Subversion.php https://github.com/ChuguluGames/mediawiki-svn.git | PHP | 406 lines
                    
1<?php
                    
2
                    
83	 * existed since version 0.3 of the Pecl extension (per release notes).
                    
84	 * Nobody ever bothered filling in the documentation on php.net though.
                    
85	 * The function returns a big array of a bunch of info about the repository
                    
106			$out = '';
                    
107			while ( !feof( $fout ) ) {
                    
108				$out .= fgets( $fout );
                    
                
recaptchalib.php https://gitlab.com/juanito.abelo/nlmobile | PHP | 278 lines
                    
1<?php
                    
2
                    
3/*
                    
4 * This is a PHP library that handles calling reCAPTCHA.
                    
5 *    - Documentation and latest version
                    
5 *    - Documentation and latest version
                    
6 *          http://recaptcha.net/plugins/php/
                    
7 *    - Get a reCAPTCHA API Key
                    
75        $http_request .= "Content-Length: " . strlen($req) . "\r\n";
                    
76        $http_request .= "User-Agent: reCAPTCHA/PHP\r\n";
                    
77        $http_request .= "\r\n";
                    
86
                    
87        while ( !feof($fs) )
                    
88                $response .= fgets($fs, 1160); // One TCP-IP packet
                    
216	if (! function_exists ("mcrypt_encrypt")) {
                    
217		die ("To use reCAPTCHA Mailhide, you need to have the mcrypt php module installed.");
                    
218	}
                    
                
WindowsAzure.php https://github.com/necrogami/zf2.git | PHP | 448 lines
                    
1<?php
                    
2/**
                    
55    const RETURN_STRING = 2; // return data as string
                    
56    const RETURN_STREAM = 3; // return PHP stream
                    
57
                    
207            rewind($fpSource);
                    
208            while (!feof($fpSource)) {
                    
209                fwrite($fpDestination, fread($fpSource, 8192));
                    
                
recaptchalib.php https://gitlab.com/blueprintmrk/bladencountyrecords | PHP | 277 lines
                    
1<?php
                    
2/*
                    
2/*
                    
3 * This is a PHP library that handles calling reCAPTCHA.
                    
4 *    - Documentation and latest version
                    
4 *    - Documentation and latest version
                    
5 *          http://recaptcha.net/plugins/php/
                    
6 *    - Get a reCAPTCHA API Key
                    
74        $http_request .= "Content-Length: " . strlen($req) . "\r\n";
                    
75        $http_request .= "User-Agent: reCAPTCHA/PHP\r\n";
                    
76        $http_request .= "\r\n";
                    
85
                    
86        while ( !feof($fs) )
                    
87                $response .= fgets($fs, 1160); // One TCP-IP packet
                    
215	if (! function_exists ("mcrypt_encrypt")) {
                    
216		die ("To use reCAPTCHA Mailhide, you need to have the mcrypt php module installed.");
                    
217	}
                    
                
sql.inc.php https://gitlab.com/sylver.gocloud/gocloudasia-college-system-framework | PHP | 238 lines
                    
1<?php
                    
2if (!$error && $_POST["export"]) {
                    
71				list($found, $pos) = $match[0];
                    
72				if (!$found && $fp && !feof($fp)) {
                    
73					$query .= fread($fp, 1e5);
                    
82							$s = $match[0][0];
                    
83							if (!$s && $fp && !feof($fp)) {
                    
84								$query .= fread($fp, 1e5);
                    
186<form action="" method="post" enctype="multipart/form-data" id="form">
                    
187<?php
                    
188$execute = "<input type='submit' value='" . lang('Execute') . "' title='Ctrl+Enter'>";
                    
                
Process.php https://github.com/agustinc/SemdropsMobile.git | PHP | 372 lines
                    
1<?php
                    
2
                    
15 * Process is a thin wrapper around proc_* functions to ease
                    
16 * start independent PHP processes.
                    
17 *
                    
51        if (!function_exists('proc_open')) {
                    
52            throw new \RuntimeException('The Process class relies on proc_open, which is not available on your PHP installation.');
                    
53        }
                    
79     *
                    
80     * @param Closure|string|array $callback A PHP callback to run whenever there is some
                    
81     *                                       output available on STDOUT or STDERR
                    
106
                    
107        // Workaround for http://bugs.php.net/bug.php?id=51800
                    
108        if (strstr(PHP_OS, 'WIN')) {
                    
167                }
                    
168                if (false === $data || feof($pipe)) {
                    
169                    fclose($pipe);
                    
                
Server.php https://gitlab.com/robfrawley/php-memcached-admin | PHP | 513 lines
                    
1<?php
                    
2/**
                    
5 * @license   http://www.apache.org/licenses/LICENSE-2.0 Apache-2.0
                    
6 * @package   phpMemcachedAdmin
                    
7 */
                    
76        # Reading Results
                    
77        while((!feof($handle)))
                    
78        {
                    
                
Download.php https://bitbucket.org/dnejedly/eaparts.git | PHP | 307 lines
                    
1<?php
                    
2/**
                    
9 * It is also available through the world-wide-web at this URL:
                    
10 * http://opensource.org/licenses/osl-3.0.php
                    
11 * If you did not receive a copy of the license and are unable to
                    
23 * @copyright   Copyright (c) 2012 Magento Inc. (http://www.magentocommerce.com)
                    
24 * @license     http://opensource.org/licenses/osl-3.0.php  Open Software License (OSL 3.0)
                    
25 */
                    
140
                    
141                while (!feof($this->_handle)) {
                    
142                    $str = fgets($this->_handle, 1024);
                    
290        elseif ($this->_linkType == self::LINK_TYPE_URL) {
                    
291            while (!feof($handle)) {
                    
292                print fgets($handle, 1024);
                    
                
GenCRC32Section.c https://gitlab.com/envieidoc/Clover | C | 313 lines
                    
6which accompanies this distribution.  The full text of the license may be found at        
                    
7http://opensource.org/licenses/bsd-license.php                                            
                    
8                                                                                          
                    
192    fread (&Temp, sizeof (UINT8), 1, InputFile);
                    
193    while (!feof (InputFile)) {
                    
194      (*FileBuffer)[Size++] = Temp;
                    
                
CsvBulkLoader.php https://gitlab.com/djpmedia/silverstripe-framework | PHP | 453 lines
                    
1<?php
                    
2
                    
123            }
                    
124            print $failedMessage . PHP_EOL;
                    
125        } finally {
                    
184
                    
185        while (!feof($from)) {
                    
186            fwrite($to, fgets($from));
                    
                
class-zip.php https://gitlab.com/endomorphosis/falkenstein | PHP | 306 lines
                    
1<?php
                    
2
                    
107
                    
108			while ((!feof($pipes[1]) || !feof($pipes[2]) || (is_array($files) && count($files)>0)) && false !== ($changes = @stream_select($read, $write, $except, 0, 200000))) {
                    
109
                    
217	public function open($path, $flags = 0) {
                    
218		if(!class_exists('PclZip')) include_once(ABSPATH.'/wp-admin/includes/class-pclzip.php');
                    
219		if(!class_exists('PclZip')) {
                    
                
waveform.class.php https://gitlab.com/x33n/ampache | PHP | 321 lines
                    
1<?php
                    
2/* vim:set softtabstop=4 shiftwidth=4 expandtab: */
                    
49  *
                    
50  * https://github.com/afreiday/php-waveform-png
                    
51  *
                    
109                                    fwrite($tfp, $buf);
                    
110                                } while (!feof($fp));
                    
111
                    
150     * Great function slightly modified as posted by Minux at
                    
151     * http://forums.clantemplates.com/showthread.php?t=133805
                    
152     * @param string $input
                    
226          imagefilledrectangle($img, 0, 0, (int) ($data_size / $detail), $height, imagecolorallocate($img, $br, $bg, $bb));
                    
227        } while (!feof($handle) && $data_point < $data_size) {
                    
228            if ($data_point++ % $detail == 0) {
                    
                
chunk.php https://gitlab.com/hschoenburg/tlworks2 | PHP | 392 lines
                    
1<?php
                    
2
                    
2
                    
3include __DIR__ . "/XmlStreamReader/autoload.php";
                    
4
                    
92    $f = @fopen($file, "rb");       
                    
93    while (!@feof($f)) {
                    
94      $chunk = @fread($f, 1024);         
                    
234        else
                    
235           $path = 'php://filter/read=preprocessxml/resource=' . $this->file;
                    
236    }
                    
368
                    
369class preprocessXml_filter extends php_user_filter {    
                    
370
                    
                
sfFilesystem.class.php https://github.com/IDCI-Consulting/WebsiteEval.git | PHP | 487 lines
                    
1<?php
                    
2
                    
16 * @author     Fabien Potencier <fabien.potencier@symfony-project.com>
                    
17 * @version    SVN: $Id: sfFilesystem.class.php 31247 2010-10-26 12:26:15Z fabien $
                    
18 */
                    
304    $err = '';
                    
305    while (!feof($pipes[1]) || !feof($pipes[2]))
                    
306    {
                    
                
Database.php https://github.com/ckdimka/core.git | PHP | 419 lines
                    
1<?php
                    
2// vim: set ts=4 sw=4 sts=4 et:
                    
11 * It is also available through the world-wide-web at this URL:
                    
12 * http://opensource.org/licenses/osl-3.0.php
                    
13 * If you did not receive a copy of the license and are unable to
                    
16 *
                    
17 * PHP version 5.3.0
                    
18 *
                    
21 * @copyright Copyright (c) 2011 Creative Development LLC <info@cdev.ru>. All rights reserved
                    
22 * @license   http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
                    
23 * @link      http://www.litecommerce.com/
                    
356
                    
357            while ($result && !feof($fp)) {
                    
358
                    
365
                    
366                } while (substr($c, $endPos) != PHP_EOL && !feof($fp));
                    
367
                    
                
progressive_parser.class.php https://github.com/kpike/moodle.git | PHP | 283 lines
                    
1<?php
                    
2
                    
51 *
                    
52 * TODO: Finish phpdocs
                    
53 */
                    
55
                    
56    protected $xml_parser; // PHP's low level XML SAX parser
                    
57    protected $file;       // full path to file being progressively parsed | => mutually exclusive
                    
136            while ($buffer = fread($fh, 8192)) {
                    
137                $this->parse($buffer, feof($fh));
                    
138            }
                    
                
class.utils.php https://gitlab.com/sokeara/Tribal_Education | PHP | 351 lines
                    
1<?php
                    
2// Exit if accessed directly
                    
95    /** 
                    
96     *  PHP_SAPI for fcgi requires a data flush of at least 256
                    
97     *  bytes every 40 seconds or else it forces a script hault
                    
112
                    
113        while (!feof($sp)) {
                    
114            $buffer = fread($sp, 512);  // use a buffer of 512 bytes
                    
327		//FALL BACK: Windows XP has bug with glob, 
                    
328		//add secondary check for PHP lameness
                    
329		if ($dh = opendir('.')) 
                    
                
ext_std_file.h https://gitlab.com/Blueprint-Marketing/hhvm | C Header | 350 lines
                    
2   +----------------------------------------------------------------------+
                    
3   | HipHop for PHP                                                       |
                    
4   +----------------------------------------------------------------------+
                    
5   | Copyright (c) 2010-2014 Facebook, Inc. (http://www.facebook.com)     |
                    
6   | Copyright (c) 1997-2010 The PHP Group                                |
                    
7   +----------------------------------------------------------------------+
                    
7   +----------------------------------------------------------------------+
                    
8   | This source file is subject to version 3.01 of the PHP license,      |
                    
9   | that is bundled with this package in the file LICENSE, and is        |
                    
10   | available through the world-wide-web at the following url:           |
                    
11   | http://www.php.net/license/3_01.txt                                  |
                    
12   | If you did not receive a copy of the PHP license and are unable to   |
                    
13   | obtain it through the world-wide-web, please send a note to          |
                    
14   | license@php.net so we can mail you a copy immediately.               |
                    
15   +----------------------------------------------------------------------+
                    
                
class-wp-filesystem-ftpext.php https://gitlab.com/endomorphosis/reservationtelco | PHP | 387 lines
                    
1<?php
                    
2/**
                    
27		if ( ! extension_loaded('ftp') ) {
                    
28			$this->errors->add('no_ftp_ext', __('The ftp PHP extension is not available'));
                    
29			return false;
                    
106
                    
107		while ( ! feof($temp) )
                    
108			$contents .= fread($temp, 8192);
                    
                
acm_file.php https://github.com/naderman/phpbb-orchestra.git | PHP | 732 lines
                    
5* @version $Id$
                    
6* @copyright (c) 2005, 2009 phpBB Group
                    
7* @license http://opensource.org/licenses/gpl-license.php GNU Public License
                    
83				global $phpbb_root_path;
                    
84				include($phpbb_root_path . 'includes/functions.' . $phpEx);
                    
85			}
                    
325		{
                    
326			global $phpEx;
                    
327			return file_exists($this->cache_dir . 'data' . $var_name . ".$phpEx");
                    
699				global $phpbb_root_path;
                    
700				include($phpbb_root_path . 'includes/functions.' . $phpEx);
                    
701			}
                    
718			global $phpbb_root_path, $phpEx;
                    
719			include($phpbb_root_path . 'includes/functions.' . $phpEx);
                    
720		}
                    
                
ideal.class.php https://bitbucket.org/anneivycat/ebcookhouse.git | PHP | 466 lines
                    
1<?php
                    
2/*-----------------------------------------------------------------------
                    
242
                    
243		while (!feof($fp)) {
                    
244			$buf .= fgets($fp, 128);
                    
                
class-wp-filesystem-ftpext.php https://gitlab.com/thisishayat/itv-2016 | PHP | 602 lines
                    
1<?php
                    
2/**
                    
30		if ( ! extension_loaded('ftp') ) {
                    
31			$this->errors->add('no_ftp_ext', __('The ftp PHP extension is not available'));
                    
32			return;
                    
127
                    
128		while ( ! feof($temp) )
                    
129			$contents .= fread($temp, 8192);
                    
                
Cache_File.php https://gitlab.com/karlen/ayo_wp | PHP | 455 lines
                    
1<?php
                    
2namespace W3TC;
                    
117		@fputs( $fp, pack( 'L', $expires_at ) );
                    
118		@fputs( $fp, '<?php exit; ?>' );
                    
119		@fputs( $fp, @serialize( $var ) );
                    
184
                    
185				while ( !@feof( $fp ) ) {
                    
186					$data .= @fread( $fp, 4096 );
                    
315
                    
316		$path = sprintf( '%s/%s/%s.php', substr( $hash, 0, 3 ), substr( $hash, 3, 3 ), $hash );
                    
317
                    
409		@fputs( $fp, pack( 'L', $expires_at ) );
                    
410		@fputs( $fp, '<?php exit; ?>' );
                    
411		@fputs( $fp, (int)$value );
                    
                
Memcacheq.php https://github.com/Exercise/zf2.git | PHP | 418 lines
                    
1<?php
                    
2/**
                    
378     *
                    
379     * The memcache functions by php cannot handle all types of requests
                    
380     * supported by MemcacheQ
                    
403        $continue_reading = true;
                    
404        while (!feof($this->_socket) && $continue_reading) {
                    
405            $resp = trim(fgets($this->_socket, 1024));
                    
                
Stream.php https://gitlab.com/ealexis.t/trends | PHP | 245 lines
                    
1<?php
                    
2namespace GuzzleHttp\Psr7;
                    
6/**
                    
7 * PHP stream implementation.
                    
8 *
                    
175    {
                    
176        return !$this->stream || feof($this->stream);
                    
177    }
                    
                
SocketHandler.php https://gitlab.com/Anas7232/Layout-Changes | PHP | 379 lines
                    
19 * @author Pablo de Leon Belloc <pablolb@gmail.com>
                    
20 * @see    http://php.net/manual/en/function.fsockopen.php
                    
21 */
                    
100     *
                    
101     * @see http://php.net/manual/en/function.fsockopen.php
                    
102     */
                    
113     *
                    
114     * @see http://php.net/manual/en/function.stream-set-timeout.php
                    
115     */
                    
226     *
                    
227     * @see http://php.net/manual/en/function.stream-set-timeout.php
                    
228     */
                    
239     *
                    
240     * @see http://php.net/manual/en/function.stream-set-chunk-size.php
                    
241     */
                    
                
users.php http://yt-cache.googlecode.com/svn/trunk/ | PHP | 214 lines
                    
1<?php
                    
2
                    
7
                    
8require_once "phprd/error-log/error.php";
                    
9
                    
16	
                    
17	public function __construct($storage_engine="mysql",$mysql_server="localhost",$mysql_username="root",$mysql_password="",$mysql_db="phprd",$mysql_table="users") {
                    
18        $this->error=ErrorHandler::singleton();
                    
42	public function login_http($realm="Restricted") {
                    
43		if (isset($_SERVER['PHP_AUTH_USER']) && isset($_SERVER['PHP_AUTH_PW'])) {
                    
44    	$username = mysql_escape_string(trim($_SERVER['PHP_AUTH_USER']));
                    
44    	$username = mysql_escape_string(trim($_SERVER['PHP_AUTH_USER']));
                    
45    	$password = mysql_escape_string(trim($_SERVER['PHP_AUTH_PW']));
                    
46    	$r=$this->login_user($username,$password);
                    
100		$fh=fopen($userdb,"r");			//open db in read-only mode
                    
101		while (!feof($fh))
                    
102			$users.=fread($fh,999999);	//read all accounts-warning, very big userdb can eat alot of mem
                    
                
class-ai1wm-extractor.php https://gitlab.com/haque.mdmanzurul/roadskill | PHP | 296 lines
                    
1<?php
                    
2
                    
84		if ( $block === $this->eof ) {
                    
85			// we reached end of file, set the pointer to the end of the file so that feof returns true
                    
86			@fseek( $this->file_handle, 1, SEEK_END );
                    
146			if ( $block === $this->eof ) {
                    
147				// we reached end of file, set the pointer to the end of the file so that feof returns true
                    
148				@fseek( $this->file_handle, 1, SEEK_END );
                    
278	public function has_not_reached_eof() {
                    
279		return ! feof( $this->file_handle );
                    
280	}
                    
                
class.p3-profiler-reader.php https://gitlab.com/mattswann/launch-housing | PHP | 374 lines
                    
1<?php
                    
2if ( !defined('P3_PATH') )
                    
62	/**
                    
63	 * Number of plugin related function calls (does not include php internal
                    
64	 * calls due to a limitation of how the tick handler works)
                    
159		// a visit is recorded, a new line is added to the file.		
                    
160		while ( !feof( $fp ) ) {
                    
161			$line = fgets( $fp );
                    
197				$this->report_date = strtotime( $o->date );
                    
198				$scheme            = parse_url( $o->url, PHP_URL_SCHEME );
                    
199				$host              = parse_url( $o->url, PHP_URL_HOST );
                    
199				$host              = parse_url( $o->url, PHP_URL_HOST );
                    
200				$path              = parse_url( $o->url, PHP_URL_PATH );
                    
201				$this->report_url  = sprintf( '%s://%s%s', $scheme, $host, $path );
                    
328			$possible_paths = array(
                    
329				WP_PLUGIN_DIR . "/$plugin.php",
                    
330				WP_PLUGIN_DIR . "/$plugin/$plugin.php",
                    
                
Process.php https://bitbucket.org/hanutimes/hanutimes.git | PHP | 379 lines
                    
1<?php
                    
2
                    
30 * Process is a thin wrapper around proc_* functions to ease
                    
31 * start independent PHP processes.
                    
32 *
                    
66        if (!function_exists('proc_open')) {
                    
67            throw new \RuntimeException('The Process class relies on proc_open, which is not available on your PHP installation.');
                    
68        }
                    
94     *
                    
95     * @param Closure|string|array $callback A PHP callback to run whenever there is some
                    
96     *                                       output available on STDOUT or STDERR
                    
174                }
                    
175                if (false === $data || feof($pipe)) {
                    
176                    fclose($pipe);
                    
                
akismet.php https://github.com/micz/elencode.git | PHP | 309 lines
                    
1<?php
                    
2/*
                    
28		<div>
                    
29			<input class="text" name="akismet_key" id="akismet_key" value="<?php bb_form_option('akismet_key'); ?>" />
                    
30			<p><?php _e('You do not need a key to run bbPress, but if you want to take advantage of Akismet\'s powerful spam blocking, you\'ll need one.'); ?></p>
                    
30			<p><?php _e('You do not need a key to run bbPress, but if you want to take advantage of Akismet\'s powerful spam blocking, you\'ll need one.'); ?></p>
                    
31			<p><?php _e('You can get an Akismet key at <a href="http://wordpress.com/api-keys/">WordPress.com</a>') ?></p>
                    
32		</div>
                    
41</form>
                    
42<?php
                    
43}
                    
105
                    
106		while ( !feof($fs) )
                    
107			$response .= fgets($fs, 1160); // One TCP-IP packet
                    
272	if ( !bb_akismet_verify_key( bb_get_option( 'akismet_key' ) ) ) : ?>
                    
273<div class="error"><p><?php printf(__('The API key you have specified is invalid.  Please double check the <strong>Akismet Key</strong> set in <a href="%s">Akismet configuration</a>.  If you don\'t have an API key yet, you can get one at <a href="%s">WordPress.com</a>.'), 'admin-base.php?plugin=bb_ksd_configuration_page', 'http://wordpress.com/api-keys/'); ?></p></div>
                    
274<?php	endif;
                    
                
upload.php https://github.com/edpanameno/cms.git | PHP | 336 lines
                    
1<?php if (!defined('PmWiki')) exit();
                    
2/*  Copyright 2004-2010 Patrick R. Michaud (pmichaud@pobox.com)
                    
5    by the Free Software Foundation; either version 2 of the License, or
                    
6    (at your option) any later version.  See pmwiki.php for full details.
                    
7
                    
10        $EnableUpload = 1;
                    
11    in config.php.  In addition, an upload password must be set, as
                    
12    the default is to lock uploads.  In some configurations it may also
                    
201  if ($fp) {
                    
202    while (!feof($fp)) echo fread($fp, 4096);
                    
203    flush();
                    
                
File.php https://bitbucket.org/sevenly/magento-ce.git | PHP | 274 lines
                    
1<?php
                    
2/**
                    
9* It is also available through the world-wide-web at this URL:
                    
10* http://opensource.org/licenses/osl-3.0.php
                    
11* If you did not receive a copy of the license and are unable to
                    
23* @copyright   Copyright (c) 2010 Magento Inc. (http://www.magentocommerce.com)
                    
24* @license     http://opensource.org/licenses/osl-3.0.php  Open Software License (OSL 3.0)
                    
25*/
                    
232    {
                    
233        return feof($this->_fileHandler);
                    
234    }
                    
                
start.html https://github.com/whitypig/emacs-cppref.git | HTML | 212 lines
                    
14<meta name="keywords" content="c,io,start" />
                    
15<link rel="search" type="application/opensearchdescription+xml" href="/wiki/lib/exe/opensearch.php" title="C++ Reference" />
                    
16<link rel="start" href="/wiki/" />
                    
17<link rel="contents" href="/wiki/c/io/start?do=index" title="Index" />
                    
18<link rel="alternate" type="application/rss+xml" title="Recent Changes" href="/wiki/feed.php" />
                    
19<link rel="alternate" type="application/rss+xml" title="Current Namespace" href="/wiki/feed.php?mode=list&amp;ns=c:io" />
                    
22<link rel="alternate" type="text/plain" title="Wiki Markup" href="/wiki/_export/raw/c/io/start" />
                    
23<link rel="stylesheet" media="all" type="text/css" href="/wiki/lib/exe/css.php?s=all&amp;t=custom1" />
                    
24<link rel="stylesheet" media="screen" type="text/css" href="/wiki/lib/exe/css.php?t=custom1" />
                    
24<link rel="stylesheet" media="screen" type="text/css" href="/wiki/lib/exe/css.php?t=custom1" />
                    
25<link rel="stylesheet" media="print" type="text/css" href="/wiki/lib/exe/css.php?s=print&amp;t=custom1" />
                    
26<script type="text/javascript" charset="utf-8" src="/wiki/lib/exe/js.php?edit=0&amp;write=1" ></script>
                    
72	<tr class="row2">
                    
73		<td class="col0"><a href="../../c/io/feof.html" class="wikilink1" title="c:io:feof">feof</a></td><td class="col1">true if at the end-of-file</td>
                    
74	</tr>
                    
                
Stream.php https://gitlab.com/reasonat/test8 | PHP | 328 lines
                    
1<?php
                    
2/**
                    
133
                    
134        return feof($this->resource);
                    
135    }
                    
                
file.php https://github.com/cholalabs/CholaApps2.0.git | PHP | 448 lines
                    
1<?php
                    
2/**
                    
2/**
                    
3 * @version		$Id: file.php 20196 2011-01-09 02:40:25Z ian $
                    
4 * @package		Chola.Framework
                    
204		//Check src path
                    
205		if (!is_readable($src)) { // && !is_writable($src)) { // file may not be writable by php if via ftp!
                    
206			return JText::_('JLIB_FILESYSTEM_CANNOT_FIND_SOURCE_FILE');
                    
291			// 2b: The length of the data is less than the max amount we want
                    
292			while (!feof($fh) && (!$amount || strlen($data) < $amount)) {
                    
293				$data .= fread($fh, $chunksize);
                    
353	 *
                    
354	 * @param string $src The name of the php (temporary) uploaded file
                    
355	 * @param string $dest The path (including filename) to move the uploaded file to
                    
                
class-wp-filesystem-ftpext.php https://gitlab.com/morganestes/wordpress-develop | PHP | 594 lines
                    
1<?php
                    
2/**
                    
27		if ( ! extension_loaded( 'ftp' ) ) {
                    
28			$this->errors->add( 'no_ftp_ext', __( 'The ftp PHP extension is not available' ) );
                    
29			return;
                    
138
                    
139		while ( ! feof( $temp ) ) {
                    
140			$contents .= fread( $temp, 8192 );
                    
                
File.php https://github.com/speedupmate/Magento-CE-Mirror.git | PHP | 274 lines
                    
1<?php
                    
2/**
                    
9 * It is also available through the world-wide-web at this URL:
                    
10 * http://opensource.org/licenses/osl-3.0.php
                    
11 * If you did not receive a copy of the license and are unable to
                    
23 * @copyright  Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com)
                    
24 * @license    http://opensource.org/licenses/osl-3.0.php  Open Software License (OSL 3.0)
                    
25 */
                    
232    {
                    
233        return feof($this->_fileHandler);
                    
234    }
                    
                
fileio.cpp https://github.com/o1iver/Code-Backup.git | C++ | 620 lines
                    
62as_value fileio_ftell(const fn_call& fn);
                    
63as_value fileio_feof(const fn_call& fn);
                    
64as_value fileio_fseek(const fn_call& fn);
                    
69// Maybe this should be moved to a dedicated extension and a different class? 
                    
70// The scandir() syntax comes from PHP, since the C syntax is not quite 
                    
71// applicable in ActionScript.
                    
100    bool asyncmode(bool async); 
                    
101    bool feof();
                    
102    bool unlink(const std::string &filespec);
                    
129    obj.init_member("asyncmode", gl.createFunction(fileio_asyncmode));
                    
130    obj.init_member("feof", gl.createFunction(fileio_feof));
                    
131    obj.init_member("fclose", gl.createFunction(fileio_fclose));
                    
239bool
                    
240FileIO::feof()
                    
241{
                    
                
excel.php https://github.com/toxik/SportsNews.git | PHP | 235 lines
                    
1<?php
                    
2/**
                    
7 * This is used to export associative array data directly to MS-Excel
                    
8 * @requires    PHP 4 >= 4.3.2
                    
9 * @author      Ignatius Teo            <ignatius@act28.com>
                    
12 * @date        20 Jan 2005
                    
13 * $Id: excel.php,v 1.3 2005/01/20 09:58:58 Owner Exp $
                    
14 */
                    
35	 * @returns	void
                    
36	 * @see		http://www.phpdig.net/ref/rn45re877.html
                    
37	 */
                    
107    {
                    
108        if (is_resource($this->fp) && !feof($this->fp))
                    
109        {
                    
226        {
                    
227            $eof = feof($this->fp);
                    
228        }
                    
                
helper.php https://bitbucket.org/gnomeontherun/square-one.git | PHP | 292 lines
                    
1<?php
                    
2/**
                    
39
                    
40		// Capture PHP errors
                    
41		$php_errormsg = 'Error Unknown';
                    
50		$inputHandle = @ fopen($url, "r");
                    
51		$error = strstr($php_errormsg, 'failed to open stream:');
                    
52		if (!$inputHandle)
                    
80
                    
81		while (!feof($inputHandle))
                    
82		{
                    
85			{
                    
86				JError::raiseWarning(44, JText::sprintf('JLIB_INSTALLER_ERROR_FAILED_READING_NETWORK_RESOURCES', $php_errormsg));
                    
87				return false;
                    
99
                    
100		// bump the max execution time because not using built in php zip libs are slow
                    
101		@set_time_limit(ini_get('max_execution_time'));
                    
                
mailtrafficlib.php https://bitbucket.org/Nemcio/kloxo-mr.git | PHP | 183 lines
                    
1<?php 
                    
2
                    
44	$count = 0;
                    
45	while(!feof($fp)) {
                    
46		$count++;
                    
169
                    
170	while(!feof($fp)) {
                    
171		$string = fgets($fp);
                    
                
function.fgets.html https://bitbucket.org/thncr/manuals.git | HTML | 178 lines
                    
11 <div class="up"><a href="ref.filesystem.html">Filesystem 函数</a></div>
                    
12 <div class="home"><a href="index.html">PHP Manual</a></div>
                    
13</div><hr /><div id="function.fgets" class="refentry">
                    
15  <h1 class="refname">fgets</h1>
                    
16  <p class="verinfo">(PHP 4, PHP 5)</p><p class="refpurpose"><span class="refname">fgets</span> &mdash; <span class="dc-title">从文件指针中读取一行</span></p>
                    
17
                    
62       <p class="para">
                    
63PHP 4.3 开始,忽略掉
                    
64    length 则行的长度被假定为 1024,将继续从流中读取数据直到行结束。如果文件中的大多数行都大于
                    
132<div class="phpcode"><code><span style="color: #000000">
                    
133<span style="color: #0000BB">&lt;?php<br />$handle&nbsp;</span><span style="color: #007700">=&nbsp;@</span><span style="color: #0000BB">fopen</span><span style="color: #007700">(</span><span style="color: #DD0000">"/tmp/inputfile.txt"</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">"r"</span><span style="color: #007700">);<br />if&nbsp;(</span><span style="color: #0000BB">$handle</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;while&nbsp;((</span><span style="color: #0000BB">$buffer&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">fgets</span><span style="color: #007700">(</span><span style="color: #0000BB">$handle</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">4096</span><span style="color: #007700">))&nbsp;!==&nbsp;</span><span style="color: #0000BB">false</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo&nbsp;</span><span style="color: #0000BB">$buffer</span><span style="color: #007700">;<br />&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;if&nbsp;(!</span><span style="color: #0000BB">feof</span><span style="color: #007700">(</span><span style="color: #0000BB">$handle</span><span style="color: #007700">))&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo&nbsp;</span><span style="color: #DD0000">"Error:&nbsp;unexpected&nbsp;fgets()&nbsp;fail\n"</span><span style="color: #007700">;<br />&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">fclose</span><span style="color: #007700">(</span><span style="color: #0000BB">$handle</span><span style="color: #007700">);<br />}<br /></span><span style="color: #0000BB">?&gt;</span>
                    
134</span>
                    
144  <h3 class="title">注释</h3>
                    
145  <blockquote class="note"><p><strong class="note">Note</strong>: <span class="simpara">在读取在 Macintosh 电脑中或由其创建的文件时, 如果 PHP
                    
146不能正确的识别行结束符,启用运行时配置可选项 <a href="filesystem.configuration.html#ini.auto-detect-line-endings" class="link">auto_detect_line_endings</a>
                    
                
update_check.php https://github.com/robertleeplummerjr/bluebox.git | PHP | 107 lines
                    
1<?PHP
                    
2/**
                    
12if ($rfh) {
                    
13	while (!feof($rfh)) {
                    
14		$line = fgets($rfh);
                    
                
Data.php https://bitbucket.org/acidel/buykoala.git | PHP | 178 lines
                    
1<?php
                    
2/**
                    
9 * It is also available through the world-wide-web at this URL:
                    
10 * http://opensource.org/licenses/osl-3.0.php
                    
11 * If you did not receive a copy of the license and are unable to
                    
25 * @copyright  Copyright (c) 2011 Fontis Pty. Ltd. (http://www.fontis.com.au)
                    
26 * @license    http://opensource.org/licenses/osl-3.0.php  Open Software License (OSL 3.0)
                    
27 */
                    
65        $http_request .= "Content-Length: " . strlen($req) . "\r\n";
                    
66        $http_request .= "User-Agent: reCAPTCHA/PHP\r\n";
                    
67        $http_request .= "\r\n";
                    
76
                    
77        while ( !feof($fs) )
                    
78            $response .= fgets($fs, 1160); // One TCP-IP packet
                    
                
bankart_diners.SecureResource.php https://gitlab.com/jo0054/bankart-opencart | PHP | 433 lines
                    
1<?php
                    
2/******************************************************************************
                    
3*
                    
4* File:         SecureResource.php
                    
5* Description:  Razred SecureResource je namenjen dekripciji podatkov iz
                    
9* Modified:     01.12.2008
                    
10* Language:     PHP (v 5.2.6)
                    
11*               Extensions: ZIP
                    
11*               Extensions: ZIP
                    
12* Package:      paymentpipephp (testna koda ze testiranje spletnih transakcij)
                    
13*
                    
99		$stringData = '';
                    
100        while (!feof($zip))
                    
101        {
                    
                
smarty_internal_data.php https://gitlab.com/mike_tm555/batiste | PHP | 404 lines
                    
1<?php
                    
2/**
                    
389        if ($fp) {
                    
390            while (!feof($fp) && ($current_line = fgets($fp)) !== false) {
                    
391                $_result .= $current_line;
                    
                
File.php https://gitlab.com/LisovyiEvhenii/ismextensions | PHP | 198 lines
                    
1<?php
                    
2/**
                    
23/** Zend_Pdf_FileParserDataSource */
                    
24#require_once 'Zend/Pdf/FileParserDataSource.php';
                    
25
                    
77        if (! (is_file($filePath) || is_link($filePath))) {
                    
78            #require_once 'Zend/Pdf/Exception.php';
                    
79            throw new Zend_Pdf_Exception("Invalid file path: $filePath",
                    
82        if (! is_readable($filePath)) {
                    
83            #require_once 'Zend/Pdf/Exception.php';
                    
84            throw new Zend_Pdf_Exception("File is not readable: $filePath",
                    
87        if (($this->_size = @filesize($filePath)) === false) {
                    
88            #require_once 'Zend/Pdf/Exception.php';
                    
89            throw new Zend_Pdf_Exception("Error while obtaining file size: $filePath",
                    
92        if (($this->_fileResource = @fopen($filePath, 'rb')) === false) {
                    
93            #require_once 'Zend/Pdf/Exception.php';
                    
94            throw new Zend_Pdf_Exception("Cannot open file for reading: $filePath",
                    
                
ext_std_file.h https://gitlab.com/0072016/0072016-PHP.LLC | C Header | 350 lines
                    
2   +----------------------------------------------------------------------+
                    
3   | HipHop for PHP                                                       |
                    
4   +----------------------------------------------------------------------+
                    
5   | Copyright (c) 2010-2015 Facebook, Inc. (http://www.facebook.com)     |
                    
6   | Copyright (c) 1997-2010 The PHP Group                                |
                    
7   +----------------------------------------------------------------------+
                    
7   +----------------------------------------------------------------------+
                    
8   | This source file is subject to version 3.01 of the PHP license,      |
                    
9   | that is bundled with this package in the file LICENSE, and is        |
                    
10   | available through the world-wide-web at the following url:           |
                    
11   | http://www.php.net/license/3_01.txt                                  |
                    
12   | If you did not receive a copy of the PHP license and are unable to   |
                    
13   | obtain it through the world-wide-web, please send a note to          |
                    
14   | license@php.net so we can mail you a copy immediately.               |
                    
15   +----------------------------------------------------------------------+
                    
                
generate-includes.php https://gitlab.com/Griffolion/Game-Embargo-Tracker | PHP | 192 lines
                    
137// stub
                    
138$php = "<?php
                    
139
                    
164echo "Writing HTMLPurifier.includes.php... ";
                    
165file_put_contents('HTMLPurifier.includes.php', $php);
                    
166echo "done!\n";
                    
167
                    
168$php = "<?php
                    
169
                    
184foreach ($files as $file) {
                    
185    $php .= "require_once \$__dir . '/$file';" . PHP_EOL;
                    
186}
                    
188echo "Writing HTMLPurifier.safe-includes.php... ";
                    
189file_put_contents('HTMLPurifier.safe-includes.php', $php);
                    
190echo "done!\n";
                    
                
update.php https://github.com/rietn/minima.git | PHP | 180 lines
                    
1<?php
                    
2/**
                    
2/**
                    
3 * @version		$Id: update.php 20196 2011-01-09 02:40:25Z ian $
                    
4 * @package		Joomla.Framework
                    
6 * @copyright	Copyright (C) 2005 - 2011 Open Source Matters, Inc. All rights reserved.
                    
7 * @license		GNU General Public License, see LICENSE.php
                    
8 */
                    
169		{
                    
170			if (!xml_parse($this->xml_parser, $data, feof($fp)))
                    
171			{
                    
                
PHPTemp.php https://gitlab.com/tonmoy1a/bitm-php-batch-26 | PHP | 206 lines
                    
22 * @package    PHPExcel_CachedObjectStorage
                    
23 * @copyright  Copyright (c) 2006 - 2014 PHPExcel (http://www.codeplex.com/PHPExcel)
                    
24 * @license    http://www.gnu.org/licenses/old-licenses/lgpl-2.1.txt	LGPL
                    
29/**
                    
30 * PHPExcel_CachedObjectStorage_PHPTemp
                    
31 *
                    
33 * @package    PHPExcel_CachedObjectStorage
                    
34 * @copyright  Copyright (c) 2006 - 2014 PHPExcel (http://www.codeplex.com/PHPExcel)
                    
35 */
                    
35 */
                    
36class PHPExcel_CachedObjectStorage_PHPTemp extends PHPExcel_CachedObjectStorage_CacheBase implements PHPExcel_CachedObjectStorage_ICache {
                    
37
                    
78     * @param	string			$pCoord		Coordinate address of the cell to update
                    
79     * @param	PHPExcel_Cell	$cell		Cell to update
                    
80	 * @return	PHPExcel_Cell
                    
                
tinymce-advanced.php https://bitbucket.org/murtuza88/carolina-home-stone.git | PHP | 312 lines
                    
1<?php
                    
2/*
                    
66
                    
67		@include_once('tadv_defaults.php');
                    
68
                    
99	
                    
100		while ( ! feof($fp) )
                    
101			$content .= fgets($fp);
                    
240</script>
                    
241<?php
                    
242		}
                    
284
                    
285			$langs["$plugin"] = $langpath . $plugin . '/langs/langs.php';
                    
286		}
                    
298		tadv_paths();
                    
299		include_once( TADV_PATH . 'tadv_admin.php');
                    
300	}
                    
                
console.php https://gitlab.com/BeS/io.schiessle.org | PHP | 169 lines
                    
1#!/usr/bin/env php
                    
2<?php
                    
25$helptext = <<<ENDOFHELP
                    
26console.php - provide an interactive PHP interpreter for testing
                    
27
                    
64/**
                    
65 * On Unix-like systems where PHP readline extension isn't present,
                    
66 * -cough- Mac OS X -cough- we can shell out to bash to do it for us.
                    
104    // Fallback... we'll have no editing controls, EWWW
                    
105    if (feof(STDIN)) {
                    
106        return false;
                    
115{
                    
116    print "Welcome to GNU social's interactive PHP console!\n";
                    
117    print "Type some PHP code and it'll execute...\n";
                    
124    print "\n";
                    
125    print "Note that PHP is cranky and you can easily kill your session by mistyping.\n";
                    
126    print "\n";
                    
                
File.php https://bitbucket.org/jonbiard/nucleus.git | PHP | 233 lines
                    
1<?php
                    
2/**
                    
37     * @param string $path The file path
                    
38     * @param string $mode The mode (see PHP's fopen() function)
                    
39     *
                    
88    {
                    
89        return @feof($this->fh);
                    
90    }
                    
                
tidy.php https://github.com/socialplanning/oc-js.git | PHP | 179 lines
                    
1<?php
                    
2  /** This PHP file is intended for use with XMLHTTPRequest from Xinha
                    
71    $result = '';
                    
72    while(!feof($socket))
                    
73    {
                    
102  {
                    
103    // PHP's urldecode doesn't understand %uHHHH for unicode
                    
104    $_REQUEST['content'] = preg_replace('/%u([a-f0-9]{4,4})/ei', 'utf8_chr(0x$1)', $_REQUEST['content']);
                    
161      ?>
                    
162      {action:'setHTML',value:'<?php echo js_encode($content) ?>'};
                    
163      <?php
                    
168      {action:'alert',value:'Tidy failed.  Check your HTML for syntax errors.'};
                    
169      <?php
                    
170    }
                    
175    {action:'alert',value:"You don't have anything to tidy!"}
                    
176    <?php
                    
177  }
                    
                
vnstat.php https://gitlab.com/billyprice1/QuickBox | PHP | 136 lines
                    
1<?php
                    
2
                    
7
                    
8    if (isset($_SERVER['PHP_SELF'])) {
                    
9	   $script = $_SERVER['PHP_SELF'];
                    
58            $buffer = '';
                    
59            while (!feof($fd)) {
                    
60                $buffer .= fgets($fd);
                    
                
dropbox52.php https://gitlab.com/megathrone86/SoftwareProjects | PHP | 460 lines
                    
1<?php
                    
2
                    
4 * Class dropbox52ModelBup
                    
5 * This class uses only with PHP on 32bit system or with PHP 5.2.x
                    
6 * @package Dropbox\Models
                    
206
                    
207                while(!feof($pointer)) {
                    
208                    fseek($pointer, $totalSize);
                    
371    public function isSessionStarted() {
                    
372        if (version_compare(PHP_VERSION, '5.4.0', '>=')) {
                    
373            return session_status() === PHP_SESSION_NONE ? false : true;
                    
433    {
                    
434        return parse_url(get_bloginfo('wpurl'), PHP_URL_HOST);
                    
435    }
                    
                
ref.filesystem.html https://bitbucket.org/thncr/manuals.git | HTML | 678 lines
                    
11 <div class="up"><a href="book.filesystem.html">Filesystem</a></div>
                    
12 <div class="home"><a href="index.html">PHP Manual</a></div>
                    
13</div><hr /><div id="ref.filesystem" class="reference">
                    
670
                    
671<h2>Table of Contents</h2><ul class="chunklist chunklist_reference"><li><a href="function.basename.html">basename</a> — 返回路径中的文件名部分</li><li><a href="function.chgrp.html">chgrp</a> — 改变文件所属的组</li><li><a href="function.chmod.html">chmod</a> — 改变文件模式</li><li><a href="function.chown.html">chown</a> — 改变文件的所有者</li><li><a href="function.clearstatcache.html">clearstatcache</a> — 清除文件状态缓存</li><li><a href="function.copy.html">copy</a> — 拷贝文件</li><li><a href="function.delete.html">delete</a> — 参见 unlink 或 unset</li><li><a href="function.dirname.html">dirname</a> — 返回路径中的目录部分</li><li><a href="function.disk-free-space.html">disk_free_space</a> — 返回目录中的可用空间</li><li><a href="function.disk-total-space.html">disk_total_space</a> — 返回一个目录的磁盘总大小</li><li><a href="function.diskfreespace.html">diskfreespace</a> — disk_free_space 的别名</li><li><a href="function.fclose.html">fclose</a> — 关闭一个已打开的文件指针</li><li><a href="function.feof.html">feof</a> — 测试文件指针是否到了文件结束的位置</li><li><a href="function.fflush.html">fflush</a> — 将缓冲内容输出到文件</li><li><a href="function.fgetc.html">fgetc</a> — 从文件指针中读取字符</li><li><a href="function.fgetcsv.html">fgetcsv</a> — 从文件指针中读入一行并解析 CSV 字段</li><li><a href="function.fgets.html">fgets</a> — 从文件指针中读取一行</li><li><a href="function.fgetss.html">fgetss</a> — 从文件指针中读取一行并过滤掉 HTML 标记</li><li><a href="function.file-exists.html">file_exists</a> — 检查文件或目录是否存在</li><li><a href="function.file-get-contents.html">file_get_contents</a> — 将整个文件读入一个字符串</li><li><a href="function.file-put-contents.html">file_put_contents</a> — 将一个字符串写入文件</li><li><a href="function.file.html">file</a> — 把整个文件读入一个数组中</li><li><a href="function.fileatime.html">fileatime</a> — 取得文件的上次访问时间</li><li><a href="function.filectime.html">filectime</a> — 取得文件的 inode 修改时间</li><li><a href="function.filegroup.html">filegroup</a> — 取得文件的组</li><li><a href="function.fileinode.html">fileinode</a> — 取得文件的 inode</li><li><a href="function.filemtime.html">filemtime</a> — 取得文件修改时间</li><li><a href="function.fileowner.html">fileowner</a> — 取得文件的所有者</li><li><a href="function.fileperms.html">fileperms</a> — 取得文件的权限</li><li><a href="function.filesize.html">filesize</a> — 取得文件大小</li><li><a href="function.filetype.html">filetype</a> — 取得文件类型</li><li><a href="function.flock.html">flock</a> — 轻便的咨询文件锁定</li><li><a href="function.fnmatch.html">fnmatch</a> — 用模式匹配文件名</li><li><a href="function.fopen.html">fopen</a> — 打开文件或者 URL</li><li><a href="function.fpassthru.html">fpassthru</a> — 输出文件指针处的所有剩余数据</li><li><a href="function.fputcsv.html">fputcsv</a> — 将行格式化为 CSV 并写入文件指针</li><li><a href="function.fputs.html">fputs</a> — fwrite 的别名</li><li><a href="function.fread.html">fread</a> — 读取文件(可安全用于二进制文件)</li><li><a href="function.fscanf.html">fscanf</a> — 从文件中格式化输入</li><li><a href="function.fseek.html">fseek</a> — 在文件指针中定位</li><li><a href="function.fstat.html">fstat</a> — 通过已打开的文件指针取得文件信息</li><li><a href="function.ftell.html">ftell</a> — 返回文件指针读/写的位置</li><li><a href="function.ftruncate.html">ftruncate</a> — 将文件截断到给定的长度</li><li><a href="function.fwrite.html">fwrite</a> — 写入文件(可安全用于二进制文件)</li><li><a href="function.glob.html">glob</a> — 寻找与模式匹配的文件路径</li><li><a href="function.is-dir.html">is_dir</a> — 判断给定文件名是否是一个目录</li><li><a href="function.is-executable.html">is_executable</a> — 判断给定文件名是否可执行</li><li><a href="function.is-file.html">is_file</a> — 判断给定文件名是否为一个正常的文件</li><li><a href="function.is-link.html">is_link</a> — 判断给定文件名是否为一个符号连接</li><li><a href="function.is-readable.html">is_readable</a> — 判断给定文件名是否可读</li><li><a href="function.is-uploaded-file.html">is_uploaded_file</a> — 判断文件是否是通过 HTTP POST 上传的</li><li><a href="function.is-writable.html">is_writable</a> — 判断给定的文件名是否可写</li><li><a href="function.is-writeable.html">is_writeable</a> — is_writable 的别名</li><li><a href="function.lchgrp.html">lchgrp</a> — Changes group ownership of symlink</li><li><a href="function.lchown.html">lchown</a> — Changes user ownership of symlink</li><li><a href="function.link.html">link</a> — 建立一个硬连接</li><li><a href="function.linkinfo.html">linkinfo</a> — 获取一个连接的信息</li><li><a href="function.lstat.html">lstat</a> — 给出一个文件或符号连接的信息</li><li><a href="function.mkdir.html">mkdir</a> — 新建目录</li><li><a href="function.move-uploaded-file.html">move_uploaded_file</a> — 将上传的文件移动到新位置</li><li><a href="function.parse-ini-file.html">parse_ini_file</a> — 解析一个配置文件</li><li><a href="function.parse-ini-string.html">parse_ini_string</a> — Parse a configuration string</li><li><a href="function.pathinfo.html">pathinfo</a> — 返回文件路径的信息</li><li><a href="function.pclose.html">pclose</a> — 关闭进程文件指针</li><li><a href="function.popen.html">popen</a> — 打开进程文件指针</li><li><a href="function.readfile.html">readfile</a> — 输出一个文件</li><li><a href="function.readlink.html">readlink</a> — 返回符号连接指向的目标</li><li><a href="function.realpath-cache-get.html">realpath_cache_get</a> — Get realpath cache entries</li><li><a href="function.realpath-cache-size.html">realpath_cache_size</a> — Get realpath cache size</li><li><a href="function.realpath.html">realpath</a> — 返回规范化的绝对路径名</li><li><a href="function.rename.html">rename</a> — 重命名一个文件或目录</li><li><a href="function.rewind.html">rewind</a> — 倒回文件指针的位置</li><li><a href="function.rmdir.html">rmdir</a> — 删除目录</li><li><a href="function.set-file-buffer.html">set_file_buffer</a> — stream_set_write_buffer 的别名</li><li><a href="function.stat.html">stat</a> — 给出文件的信息</li><li><a href="function.symlink.html">symlink</a> — 建立符号连接</li><li><a href="function.tempnam.html">tempnam</a> — 建立一个具有唯一文件名的文件</li><li><a href="function.tmpfile.html">tmpfile</a> — 建立一个临时文件</li><li><a href="function.touch.html">touch</a> — 设定文件的访问和修改时间</li><li><a href="function.umask.html">umask</a> — 改变当前的 umask</li><li><a href="function.unlink.html">unlink</a> — 删除文件</li></ul>
                    
672</div>
                    
676 <div class="up"><a href="book.filesystem.html">Filesystem</a></div>
                    
677 <div class="home"><a href="index.html">PHP Manual</a></div>
                    
678</div></body></html>
                    
                
shitja.php https://bitbucket.org/galanx/faturimi.git | PHP | 418 lines
                    
1<?php
                    
2	class Negenet_Shitja_Controller extends Base_Controller{
                    
64				$file = fopen($path.$filename,"r");
                    
65				while(!feof($file)){
                    
66					$string = fgets($file);
                    
                
class-destination-folder.php https://gitlab.com/pankajmohale/chef2go | PHP | 250 lines
                    
1<?php
                    
2/**
                    
28		?>
                    
29    <h3 class="title"><?php esc_html_e( 'Backup settings', 'backwpup' ); ?></h3>
                    
30    <p></p>
                    
32        <tr>
                    
33            <th scope="row"><label for="idbackupdir"><?php esc_html_e( 'Folder to store backups in', 'backwpup' ); ?></label></th>
                    
34            <td>
                    
34            <td>
                    
35                <input name="backupdir" id="idbackupdir" type="text" value="<?php echo esc_attr( BackWPup_Option::get( $jobid, 'backupdir' ) ); ?>" class="regular-text" />
                    
36            </td>
                    
38        <tr>
                    
39            <th scope="row"><?php esc_html_e( 'File Deletion', 'backwpup' ); ?></th>
                    
40            <td>
                    
40            <td>
                    
41	            <?php
                    
42	            if ( BackWPup_Option::get( $jobid, 'backuptype' ) === 'archive' ) {
                    
                
dumpTextPass.php https://github.com/sunnysujan/wikireader.git | PHP | 525 lines
                    
1<?php
                    
2/**
                    
89	function stream_eof() {
                    
90		return feof( $this->stream );
                    
91	}
                    
103	var $prefetch = null;
                    
104	var $input = "php://stdin";
                    
105	var $history = WikiExporter::FULL;
                    
112	
                    
113	var $php = "php";
                    
114	var $spawn = false;
                    
169			if( $val ) {
                    
170				$this->php = $val;
                    
171			}
                    
508
                    
509Usage: php dumpTextPass.php [<options>]
                    
510Options:
                    
                
admin.php https://github.com/tmccormi/openemr.git | PHP | 182 lines
                    
1<?php
                    
2include_once('../../globals.php');
                    
3?>
                    
4<?php
                    
5if ($_POST['export']) {
                    
48?>
                    
49<?php
                    
50    $fname = '';
                    
66    $content = '';
                    
67    while (!feof($handle)) {
                    
68        $buffer = fgets($handle);
                    
171<p>
                    
172<?php xl("Click 'export' to export your Category, Subcategory, Item, Content data to a text file. Any resemblance of this file to an XML file is purely coincidental. The opening and closing tags must be on the same line, they must be lowercase with no spaces. To import, browse for a file and click 'import'. If the data is completely different, it will merge with your existing data. If there are similar item names, The old one will be kept and the new one saved with a number added to the end.", "e"); ?>
                    
173<?php xl("This feature is very experimental and not fully tested. Use at your own risk!", "e"); ?>
                    
176<input type="hidden" name="MAX_FILE_SIZE" value="12000000" />
                    
177<?php xl('Send this file', 'e'); ?>: <input type="file" name="userfile"/>
                    
178<input type="submit" name="import" value='<?php xl("Import", "e"); ?>'/>
                    
                
googlespell.php https://bitbucket.org/pastor399/newcastleunifc.git | PHP | 170 lines
                    
1<?php
                    
2/**
                    
101				$xml = "";
                    
102				while (!feof($fp))
                    
103					$xml .= fgets($fp, 128);
                    
                
streams.php https://github.com/sharpmachine/wakeupmedia.com.git | PHP | 209 lines
                    
1<?php
                    
2/**
                    
5 *
                    
6 * @version $Id: streams.php 597 2011-01-16 20:14:36Z nbachiyski $
                    
7 * @package pomo
                    
127	
                    
128	function feof() {
                    
129		return feof($this->_f);
                    
137		$all = '';
                    
138		while ( !$this->feof() )
                    
139			$all .= $this->read(4096);
                    
                
WinFsStreamWrapper.php https://gitlab.com/oytunistrator/92five | PHP | 400 lines
                    
1<?php // vi: set fenc=utf-8 ts=4 sw=4 et:
                    
2/*
                    
18 *
                    
19 * See also https://code.google.com/p/php-wfio/ for a PHP extension
                    
20 * and comments on http://www.rooftopsolutions.nl/blog/filesystem-encoding-and-php
                    
214    {
                    
215        return feof($this->handle);
                    
216    }
                    
                
SMTP.php https://gitlab.com/staging06/myproject | PHP | 452 lines
                    
1<?php
                    
2
                    
10
                    
11require_once dirname(__FILE__) . "/../ClassLoader.php";
                    
12Swift_ClassLoader::load("Swift_ConnectionBase");
                    
211   * See the constants ENC_TLS, ENC_SSL and ENC_OFF
                    
212   * NOTE: PHP needs to have been compiled with OpenSSL for SSL and TLS to work
                    
213   * NOTE: Some PHP installations will not have the TLS stream wrapper
                    
231   * Read a full response from the buffer
                    
232   * inner !feof() patch provided by Christian Rodriguez:
                    
233   * <a href="http://www.flyspray.org/">www.flyspray.org</a>
                    
242    $line = 0;
                    
243    while (!feof($this->handle))
                    
244    {
                    
359      {
                    
360		if (preg_match("/^[A-Za-z0-9-]+\\.php\$/", $file) && $file != "index.php")
                    
361        {
                    
                
akismet.php https://bitbucket.org/pastor399/newcastleunifc.git | PHP | 402 lines
                    
1<?php
                    
2/**
                    
4 * @copyright	Copyright (C) 2010 Stack Ideas Private Limited. All rights reserved.
                    
5 * @license		GNU/GPL, see LICENSE.php
                    
6 *
                    
10 * other free or open source software licenses.
                    
11 * See COPYRIGHT.php for copyright notices and details.
                    
12 */
                    
18 *
                    
19 * Akismet PHP4 class
                    
20 *
                    
44 * @author Bret Kuhns {@link www.bretkuhns.com}
                    
45 * @link http://code.google.com/p/akismet-php4
                    
46 * @version 0.3.5
                    
46 * @version 0.3.5
                    
47 * @license http://www.opensource.org/licenses/mit-license.php MIT License
                    
48 */
                    
                
Worldpay.php https://bitbucket.org/anneivycat/ebcookhouse.git | PHP | 177 lines
                    
1<?php
                    
2
                    
72
                    
73			$errors = "\nUsing BUILT-IN PHP curl methods\n";
                    
74			// Run through the posted array
                    
158				// loop through the response from the server and append to variable
                    
159				while (!feof($fp)) {
                    
160					$this->ipnResponse .= fgets($fp, 1024);
                    
                
st_upload.php https://github.com/hendrowicaksono/s3st12-soap.git | PHP | 110 lines
                    
1<?php
                    
2/**
                    
23// main system configuration
                    
24require '../../../sysconfig.inc.php';
                    
25// start the session
                    
25// start the session
                    
26require SENAYAN_BASE_DIR.'admin/default/session.inc.php';
                    
27require SENAYAN_BASE_DIR.'admin/default/session_check.inc.php';
                    
45if (isset($_POST['stUpload']) && isset($_FILES['stFile'])) {
                    
46    require SIMBIO_BASE_DIR.'simbio_FILE/simbio_file_upload.inc.php';
                    
47    // create upload object
                    
68        $i = 0;
                    
69        while (!feof($stfile)) {
                    
70            $curr_time = date('Y-m-d H:i:s');
                    
101    <?php echo __('STOCK TAKE UPLOAD - Upload a plain text file (.txt) containing list of Item Code to stock take. Each Item Code separated by line.'); ?><hr />
                    
102    <form name="uploadForm" method="post" enctype="multipart/form-data" action="<?php echo MODULES_WEB_ROOT_DIR.'stock_take/st_upload.php'; ?>" target="uploadAction" style="display: inline;">
                    
103    <?php echo __(' File'); //mfc ?>: <input type="file" name="stFile" id="stFile" /> Maximum <?php echo $sysconf['max_upload']; ?> KB
                    
                
ajaximage.php https://bitbucket.org/antonyravel/cape-resorts.git | PHP | 169 lines
                    
1
                    
2<?php
                    
3$path = dirname(__FILE__)."/uploads/";
                    
36	{
                    
37		$path = parse_url($src_file, PHP_URL_PATH);
                    
38		$abs_path = $_SERVER['DOCUMENT_ROOT'].$path;
                    
83	$row = 1;
                    
84	while (!feof($file_handle) ) 
                    
85	{
                    
                
File.php https://github.com/EthanBlast/Glam-Star-Life.git | PHP | 237 lines
                    
1<?php
                    
2
                    
9 */
                    
10require_once W3TC_LIB_W3_DIR . '/Cache/Base.php';
                    
11
                    
31    /**
                    
32     * PHP5 constructor
                    
33     *
                    
42    /**
                    
43     * PHP4 constructor
                    
44     *
                    
139                            
                    
140                            while (!@feof($fp)) {
                    
141                                $data .= @fread($fp, 4096);
                    
                
albums.php https://github.com/benrhughes/PicasaAlbums.git | PHP | 151 lines
                    
1<?php
                    
2/*------------------------------------------------------------------------------
                    
2/*------------------------------------------------------------------------------
                    
3| Albums.php
                    
4|
                    
11| XML parsing logic from 
                    
12|	http://www.sitepoint.com/article/php-xml-parsing-rss-1-0
                    
13|
                    
34
                    
35$target = "PicasaBox.php/?album="; //URL to pass the name of the album to for the links
                    
36
                    
99while ($data = fread($fp, 4096))
                    
100	xml_parse($xml_parser, $data, feof($fp))
                    
101		or die(sprintf("XML error: %s at line %d", 
                    
                
Config.php https://github.com/srhinow/myContaoSearchPortal.git | PHP | 315 lines
                    
1<?php if (!defined('TL_ROOT')) die('You cannot access this file directly!');
                    
2
                    
22 *
                    
23 * PHP version 5
                    
24 * @copyright  Leo Feyer 2005-2011
                    
90	{
                    
91		include(TL_ROOT . '/system/config/config.php');
                    
92		include(TL_ROOT . '/system/config/localconfig.php');
                    
96		{
                    
97			$strFile = sprintf('%s/system/modules/%s/config/config.php', TL_ROOT, $strModule);
                    
98			@include($strFile);
                    
100
                    
101		include(TL_ROOT . '/system/config/localconfig.php');
                    
102
                    
104		$strMode = 'top';
                    
105		$resFile = fopen(TL_ROOT . '/system/config/localconfig.php', 'rb');
                    
106
                    
                
QuestionHelper.php https://gitlab.com/Isaki/le331.fr | PHP | 446 lines
                    
1<?php
                    
2
                    
104     *
                    
105     * This method is public for PHP 5.3 compatibility, it should be private.
                    
106     *
                    
223        // Read a keypress
                    
224        while (!feof($inputStream)) {
                    
225            $c = fread($inputStream, 1);
                    
                
function.fetch.php https://github.com/jacknicole/sugarcrm_dev.git | PHP | 253 lines
                    
1<?php
                    
2
                    
16
                    
17r51443 - 2009-10-12 13:34:36 -0700 (Mon, 12 Oct 2009) - jmertic - Bug 33332 - Made application PHP 5.3 compliant with E_DEPRECATED warnings on by:
                    
18- Changing all ereg function to either preg or simple string based ones
                    
25
                    
26r10971 - 2006-01-12 14:58:30 -0800 (Thu, 12 Jan 2006) - chris - Bug 4128: updating Smarty templates to 2.6.11, a version supposedly that plays better with PHP 5.1
                    
27
                    
46 * Purpose:  fetch file, web or ftp data and display results
                    
47 * @link http://smarty.php.net/manual/en/language.function.fetch.php {fetch}
                    
48 *       (Smarty online manual)
                    
64        $_params = array('resource_type' => 'file', 'resource_name' => $params['file']);
                    
65        require_once(SMARTY_CORE_DIR . 'core.is_secure.php');
                    
66        if(!smarty_core_is_secure($_params, $smarty)) {
                    
72        if($fp = @fopen($params['file'],'r')) {
                    
73            while(!feof($fp)) {
                    
74                $content .= fgets ($fp,4096);
                    
                
Maildir.php https://github.com/bhaumik25/zend-framework.git | PHP | 301 lines
                    
1<?php
                    
2/**
                    
23 */
                    
24require_once 'Zend/Mail/Storage/Abstract.php';
                    
25
                    
28 */
                    
29require_once 'Zend/Mail/Message.php';
                    
30
                    
33 */
                    
34require_once 'Zend/Mail/Storage/Exception.php';
                    
35
                    
150        $content = '';
                    
151        while (!feof($fh)) {
                    
152            $line = fgets($fh);
                    
179
                    
180        while (!feof($fh)) {
                    
181            $line = fgets($fh);
                    
                
klonecpp.php https://bitbucket.org/pombredanne/spip-zone-treemap.git | PHP | 310 lines
                    
1<?php
                    
2/*************************************************************************************
                    
2/*************************************************************************************
                    
3 * klonecpp.php
                    
4 * --------
                    
83            'putchar', 'puts', 'ungetc', 'fread', 'fwrite', 'fseek', 'ftell', 'rewind',
                    
84            'fgetpos', 'fsetpos', 'clearerr', 'feof', 'ferror', 'perror', 'abs', 'labs',
                    
85            'div', 'ldiv', 'atof', 'atoi', 'atol', 'strtod', 'strtol', 'strtoul', 'calloc',
                    
                
VarnishAdminSocket.php https://github.com/arjenschat/php-varnish.git | PHP | 281 lines
                    
1<?php
                    
2/**
                    
143        // code should be on first line, so we should get it in one chunk
                    
144        while ( ! feof($this->fp) ) {
                    
145            $response = fgets( $this->fp, 1024 );
                    
161        $response = '';
                    
162        while ( ! feof($this->fp) && strlen($response) < $len ) {
                    
163            $response .= fgets( $this->fp, 1024 );
                    
                
vfsStreamWrapperFileTestCase.php https://gitlab.com/Japang-Jawara/jawara-penilaian | PHP | 457 lines
                    
1<?php
                    
2/**
                    
10namespace org\bovigo\vfs;
                    
11require_once __DIR__ . '/vfsStreamWrapperBaseTestCase.php';
                    
12/**
                    
122        $this->assertEquals(0, ftell($fp));
                    
123        $this->assertFalse(feof($fp));
                    
124        $this->assertEquals(0, fseek($fp, 2));
                    
129        $this->assertEquals(6, ftell($fp));
                    
130        $this->assertTrue(feof($fp));
                    
131        $this->assertEquals(0, fseek($fp, 2));
                    
131        $this->assertEquals(0, fseek($fp, 2));
                    
132        $this->assertFalse(feof($fp));
                    
133        $this->assertEquals(2, ftell($fp));
                    
                
QuestionHelper.php https://gitlab.com/imamul68e/137619_PHP31 | PHP | 449 lines
                    
1<?php
                    
2
                    
223        // Read a keypress
                    
224        while (!feof($inputStream)) {
                    
225            $c = fread($inputStream, 1);
                    
                
Reader.php https://gitlab.com/mmerian/csv.git | PHP | 429 lines
                    
1<?php
                    
2/****************************
                    
356    /**
                    
357     * (non-PHPdoc)
                    
358     * @see Iterator::current()
                    
389    /**
                    
390     * (non-PHPdoc)
                    
391     * @see Iterator::rewind()
                    
403    /**
                    
404     * (non-PHPdoc)
                    
405     * @see Iterator::valid()
                    
408    {
                    
409        return (! feof($this->fp));
                    
410    }
                    
412    /**
                    
413     * (non-PHPdoc)
                    
414     * @see Iterator::next()
                    
                
generate-api-docs.c https://gitlab.com/libvirt/libvirt-php.git | C | 316 lines
                    
186        if (!fgets(line, sizeof(line), fp)) {
                    
187            if (feof(fp))
                    
188                break;
                    
219
                    
220    fprintf(fp,"<h1>%s API Reference guide</h1>\n\n    <h3>Functions</h3>\n\n    <!-- Links -->\n", (private == 0) ? "PHP" : "Developer's");
                    
221    fprintf(fp, "<pre>Total number of functions: %d. Functions supported are:<br /><br />\n", count_functions(function_number, private));
                    
                
Maildir.php https://gitlab.com/LisovyiEvhenii/ismextensions | PHP | 475 lines
                    
1<?php
                    
2/**
                    
26 */
                    
27#require_once 'Zend/Mail/Storage/Abstract.php';
                    
28
                    
31 */
                    
32#require_once 'Zend/Mail/Message/File.php';
                    
33
                    
36 */
                    
37#require_once 'Zend/Mail/Storage.php';
                    
38
                    
124             */
                    
125            #require_once 'Zend/Mail/Storage/Exception.php';
                    
126            throw new Zend_Mail_Storage_Exception('id does not exist');
                    
136             */
                    
137            #require_once 'Zend/Mail/Storage/Exception.php';
                    
138            throw new Zend_Mail_Storage_Exception('field does not exist');
                    
                
Maildir.php https://github.com/bhaumik25/zend-framework.git | PHP | 222 lines
                    
1<?php
                    
2/**
                    
23 */
                    
24require_once 'Zend/Mail/Abstract.php';
                    
25
                    
28 */
                    
29require_once 'Zend/Mail/Message.php';
                    
30
                    
33 */
                    
34require_once 'Zend/Mail/Exception.php';
                    
35
                    
123        $fh = fopen($this->_files[$id - 1]['filename'], 'r');
                    
124        while(!feof($fh) && ($inHeader || $bodyLines--)) {
                    
125            $line = fgets($fh);
                    
                
File.php https://bitbucket.org/rybadour/todo_list_site.git | PHP | 241 lines
                    
1<?php defined('SYSPATH') OR die('No direct script access.');
                    
2/**
                    
14	 * Attempt to get the mime type from a file. This method is horribly
                    
15	 * unreliable, due to PHP being horribly unreliable when it comes to
                    
16	 * determining the mime type of a file.
                    
68	 *
                    
69	 * @param   string  $extension  php, pdf, txt, etc
                    
70	 * @return  string  mime type on success
                    
168
                    
169		while ( ! feof($file))
                    
170		{
                    
227
                    
228			while ( ! feof($piece))
                    
229			{
                    
                
Jpeg.php https://github.com/kervin/kyzstudio.git | PHP | 152 lines
                    
1<?php
                    
2/**
                    
18 * @license    http://framework.zend.com/license/new-bsd     New BSD License
                    
19 * @version    $Id: Jpeg.php 23395 2010-11-19 15:30:47Z alexander $
                    
20 */
                    
23/** Internally used classes */
                    
24#require_once 'Zend/Pdf/Element/Name.php';
                    
25#require_once 'Zend/Pdf/Element/Numeric.php';
                    
28/** Zend_Pdf_Resource_Image */
                    
29#require_once 'Zend/Pdf/Resource/Image.php';
                    
30
                    
53        if (!function_exists('gd_info')) {
                    
54            #require_once 'Zend/Pdf/Exception.php';
                    
55            throw new Zend_Pdf_Exception('Image extension is not installed.');
                    
60             (!isset($gd_options['JPEG Support']) || $gd_options['JPEG Support'] != true)  ) {
                    
61            #require_once 'Zend/Pdf/Exception.php';
                    
62            throw new Zend_Pdf_Exception('JPG support is not configured properly.');
                    
                
group.php https://bitbucket.org/lvandervelde/vingi.git | PHP | 318 lines
                    
1<?php
                    
2
                    
49    /**
                    
50     * Returns a image given to a corrospekoefeofd group
                    
51     * @param unknown $mediaId
                    
                
file.php https://bitbucket.org/pastor399/newcastleunifc.git | PHP | 540 lines
                    
1<?php
                    
2/**
                    
342			 */
                    
343			while (!feof($fh) && (!$amount || strlen($data) < $amount))
                    
344			{
                    
415	 *
                    
416	 * @param   string   $src          The name of the php (temporary) uploaded file
                    
417	 * @param   string   $dest         The path (including filename) to move the uploaded file to
                    
                
Socket.php https://github.com/shafiqissani/ASTRA-College-Website.git | PHP | 326 lines
                    
1<?php
                    
2//
                    
3// +----------------------------------------------------------------------+
                    
4// | PHP version 4.0                                                      |
                    
5// +----------------------------------------------------------------------+
                    
5// +----------------------------------------------------------------------+
                    
6// | Copyright (c) 1997-2001 The PHP Group                                |
                    
7// +----------------------------------------------------------------------+
                    
7// +----------------------------------------------------------------------+
                    
8// | This source file is subject to version 2.0 of the PHP license,       |
                    
9// | that is bundled with this package in the file LICENSE, and is        |
                    
10// | available at through the world-wide-web at                           |
                    
11// | http://www.php.net/license/2_02.txt.                                 |
                    
12// | If you did not receive a copy of the PHP license and are unable to   |
                    
13// | obtain it through the world-wide-web, please send a note to          |
                    
14// | license@php.net so we can mail you a copy immediately.               |
                    
15// +----------------------------------------------------------------------+
                    
                
FS.php https://github.com/wrlee/gallery3-contrib.git | PHP | 180 lines
                    
1<?php
                    
2
                    
5 *
                    
6 * This Lock Manager stores all its data in the filesystem. By default it will do this in PHP's standard temporary session directory,
                    
7 * but this can be overriden by specifiying an alternative path in the contructor
                    
142        // Reading data until the eof
                    
143        while(!feof($handle)) {
                    
144            $data.=fread($handle,8192);
                    
                
FileByteStream.php https://gitlab.com/fiesta-framework/Documentation | PHP | 229 lines
                    
1<?php
                    
2
                    
84        $fp = $this->_getReadHandle();
                    
85        if (!feof($fp)) {
                    
86            if ($this->_quotes) {
                    
95            // If we read one byte after reaching the end of the file
                    
96            // feof() will return false and an empty string is returned
                    
97            if ($bytes === '' && feof($fp)) {
                    
207    {
                    
208        if ($tmpFile = fopen('php://temp/maxmemory:4096', 'w+b')) {
                    
209            /* We have opened a php:// Stream Should work without problem */
                    
212        } else {
                    
213            throw new Swift_IoException('Unable to copy the file to make it seekable, sys_temp_dir is not writable, php://memory not available');
                    
214        }
                    
221        fseek($tmpFile, 0, SEEK_SET);
                    
222        while (!feof($source)) {
                    
223            fwrite($tmpFile, fread($source, 4096));
                    
                
cake_socket.php https://github.com/cgajardo/repositorium.git | PHP | 304 lines
                    
1<?php
                    
2/**
                    
4 *
                    
5 * PHP versions 4 and 5
                    
6 *
                    
6 *
                    
7 * CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
                    
8 * Copyright 2005-2010, Cake Software Foundation, Inc. (http://cakefoundation.org)
                    
13 * @copyright     Copyright 2005-2010, Cake Software Foundation, Inc. (http://cakefoundation.org)
                    
14 * @link          http://cakephp.org CakePHP(tm) Project
                    
15 * @package       cake
                    
16 * @subpackage    cake.cake.libs
                    
17 * @since         CakePHP(tm) v 1.2.0
                    
18 * @license       MIT License (http://www.opensource.org/licenses/mit-license.php)
                    
233
                    
234		if (!feof($this->connection)) {
                    
235			$buffer = fread($this->connection, $length);
                    
                
 

Source

Language