answersLogoWhite

0

How mixed two text file in PHP?

User Avatar

Demon9992

Lvl 1
13y ago
Updated: 8/19/2019

This construction crashes when large files ! =(

while ($i

$i++;

$lines = file('key.txt');

$txt = ' '.rtrim($lines[$i],"\r\n").' ';

preg_match_all('/\x20/s', $outpost, $m, PREG_OFFSET_CAPTURE);

$n = rand(1, strlen($outpost));

$outpost = substr($outpost, 0, $m[0][$n][1]).$txt.substr($outpost, $m[0][$n][1] + 1);

}

User Avatar

Wiki User

13y ago

What else can I help you with?

Related Questions

What program is required to open a PHP file?

The first thing you would need to open up and run a PHP file would be to have a web server with PHP installed on your local development site like XAMPP, WAMP, or MAMP. Alternatively, you could open a PHP file in any text editor, like VS Code or Sublime Text, to view or edit the code, but to run the file, it needs to be executed from a server that has PHP support. To know more..connectinfosoft


How do you add text files to a MS Access database?

There are two methods to add a text file to a MS access Database.1) Link the text file. Go to File/Get External Data/ Link Tables. In the link file screen change the file type to Text file and then browse to the text file and select your text file. MS Access will prompt you to give the specs of the file when you are linking it. 2) Import the file to an access table. Go To File/Get external Data/ Import. In the screen change the file type at the bottom to text, and select your text file.


What PHP statement outputs text on the screen?

There are several different ways to output text on the screen in PHP two of the most common are echo and print. echo "Hello World!"; print ("Hello World!"); Would both print ... Hello World!


What are two examples of file formats that can be used when saving files?

Two examples are Text (.txt) and Rich Text (.rtf)


What is an explanation of the file modes briefly?

Two file modes are "text" and "binary". Text is used for human readable data, such as a C source file, or a notepad text file. Binary is used for computer readable data, such as an executable object file. Two other file modes are "sequential" and "random". Sequential is used when the file is accessed serially, from the beginning to the end, and can be used for both text and binary files. Random is used when the file is accessed non-serially, often jumping around from place to place. An example of random is a database file.


What are the different types of files and how End Of File of a full represented by a pointer?

There are two file types in C++ namely, text file and binary file. In text file EOF or end of file is represented by an end of file character having ASCII 26. In binary files EOF or end of file is represented by NULL in the file pointer


What do you do when a file you want is to big for Notepad?

Open the text file in WordPad. Otherwise, split the file into two or more separate files, and view them individually in Notepad.


What are the two modes of the php processor?

Copy and Interpret


Why we use javascript as we have a powerful scripting language php?

First of all, PHP is server side, Javascript is client side. You cannot detect mouse gestures or any clicks with PHP the same way you cannot read a file or modify it or process a form (unless you use AJAX of course). Also, although I love PHP, and it has useful extensions such as the GD library, PHP is not a very good language. Overall we use javascript and PHP because they are used for two completely different things.


How can you pass a JavaScript value into a PHP file?

JavaScript lives in the browser, PHP lives on the server.To pass a value from JavaScript to a PHP page, you can eitherdo an HTML form submituse AJAXIn both cases, the value is sent to the server and you write your PHP to handle it and send a response.The important thing is that the JavaScript value won't be available in PHP when you first generate the page, creating the page and handling the value submitted from the browser are two distinct steps.


What can you use to compare the differences between two text files?

Two text files can be compared using Textpad software. This is commonly used used to view text file like notepad. please let me know if this is not enough.


What is the difference between include and require in PHP?

The two functions are used to insert the content of a file into another PHP file before it is executed by the server. They are identical in every aspect, but they perform error handling in different ways. The include() function generates a warning (which does not halt execution) while the require() function generates a fatal error (which stops execution immediately).