A few notes on this:
1. It would be better to combine your queries into one query to take a bit of strain off the MySql server and make this a little faster, for example:
A:
INSERT INTO `table`(id,name) VALUES(NULL,'R_T'),(NULL,'elrayyes'),(NULL,'Something');
will be faster than
B:
INSERT INTO `table`(id,name) VALUES(NULL,'R_T');
INSERT INTO `table`(id,name) VALUES(NULL,'elrayyes');
INSERT INTO `table`(id,name) VALUES(NULL,'Something');
- INSERT INTO `table`(id,name) VALUES(NULL,'R_T');
- INSERT INTO `table`(id,name) VALUES(NULL,'elrayyes');
- INSERT INTO `table`(id,name) VALUES(NULL,'Something');
Adjusting your PHP code to build one bigger query and then execute it would be better.
2. echo()ing is faster than print()ing ... This might be by miliseceonds, but if you have lots of places saving miliseconds at a time it might help a little on higher traffic pages.
3. Using single quotes around strings is faster than using double quotes, for example:
A:
echo 'Hello my name is R_T';
will be faster than
B:
echo "Hello my name is R_T";
Again, this is a really tiny difference measured in miliseconds, but on frequently accessed pages it might make a little difference. Note though that variables cannot be echo()d in single quoted strings, so the following will NOT work:
$username = 'R_T';
echo 'Hello my name is $username';
- $username = 'R_T';
- echo 'Hello my name is $username';
This will output: Hello my name is $username
Whereas the following WILL work:
$username = 'R_T';
echo "Hello my name is $username";
- $username = 'R_T';
- echo "Hello my name is $username";
This will output: Hello my name is R_T
4. Now, regarding your actual issue, do you have an example of the file you are importing somewhere so I can see what it looks like?
Let's leave all our *plum* where it is and go live in the jungle ...