Is there something wrong?


Posted on 16th Feb 2014 07:03 pm by admin

Hi all,

Just a quick question... can someone look at this code and see if something is wrong?

Code: $j = 1;
$vals = array();
$feedline = array();
foreach(explode($delimiter,$b) as $key => $values) {

if($j == $appsubcol2 || $j == $appsubcol3 || $j == $appsubcol4) {
$x = 1;
if(!empty($delimet2) && $j == $appsubcol2) {$del = $sdelimiter; $sdel = $sdel2; }
if(!empty($delimet3) && $j == $appsubcol3) {$del = $ssdelimiter; $sdel = $sdel3; }
if(!empty($delimet4) && $j == $appsubcol4) {$del = $sssdelimiter; $sdel = $sdel4; }

$subcount = count(explode($del,$values));
foreach(explode($del,$values) as $subdel) {
if($sdel[$x] == 1) {
$feedline[$j] = $subdel;
$j++;
} $x++;

}} else { $feedline[$j] = $values;
$j++; }

}The first itteration of the three if statments works great... when it gets to the second and third if statement, they don't explode....

No comments posted yet

Your Answer:

Login to answer
208 Like 31 Dislike
Previous forums Next forums
Other forums

SMTP server...
I recently found a tutorial online on SMTP authentification for sending emails from webpages, here i

Inserting multiple records from single form
I've found a number of threads that deal with this issue, but I'm new to php and coding language so

Reduce redundancies in switch functions?
Hello all! I somewhat new to PHP, and was wondering if anyone could give some suggestions on a swit

PHP Thumbnail Creation
Ok so i use this function to create thumbnails:

Code: function createthumb($name,$filename,$n

show the direct link into href
I want to display link on the page. i am fetching the data(URL) from database,actually before that i

php mysql script to find record
Hi,

Currently I have a simple table with 4 columns. A, B, C, D

If I want to find all

query help
Hi experts.

i have a table rep2 like this
PROD_COD ACCT_NO DUE_DAYS BALANCE

Problem with the Update command used with a sqldataadapter
I'm connected to a database on an SQL Server and I'm using a sqldataadapter, sqlconnection, sqldatas

turning an array into a string then poping it into a db
Hi im just wondering how you get a requested array into a single string then pop it into the db so f

If a form submits back to same page do you need to use $get
IM trying to pass page number and year that was selected back to the same page.

i have this c

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash