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

Preventing blank or already entered values
Im trying to learn how to place a read file line by line and prevent duplicate entries and also BLAN

Logic question
im wondering what's the best method to do the above list:

it is for alliance @ MMORPG game

if description does not contain the following words
Hello everyone,

I am parsing a MS Excel (.xls) file and adding it's content to a mySQL databa

how to get different value in second view of webdynpro?
hello guys,

In ABAP webdynpro I am trying to create one application having two views.

ldap connection
We are using ldap to get user information from the domain controller. It was working before. Recentl

Line break?
Hi, I'm new to the forum and new to php. I'm not sure if I'm using the correct terminology so here i

PHP Code / Script To check weather the given email exists in a domain
Hi,

I want to implement the following in my web page

in sign up we will ask to enter u

j1inmis Ouput layout changes
Hi,

Can anybody tell how can j1inmis output layout can be changed so that vendor names ge

Help If user voted, block them
On my Prayer request site, i let users Click a button to Pray for somone that has posted a pray, i g

help need on ob_start()
Hi

I am a newbie in php, I have a code
Line number On/Off | Expand/Contract <?phpo

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