![]() |
join('')
Dear Sirs and or Madaams,
I need to write a file from @fields. I need the file to look like... $bgcolor = "black"; $textcolor = "black"; etc... or $bgcolor = "black"; $textcolor = "black"; @fields = split (/\|/, $line); foreach $field (@user_field_order) { This is what I have but it's not putting the >>";\n\n<< after each item @fields and the $field is printing as $field and it's creating a list foreach $field (@user_field_order) $list .= join('\$$field = \"' => @fields => '\"\; \n\n '); } Any help is appreciated and thanks in advance for your help. |
Re: join('')
Your question is a little unclear. You have an array @fields. Are the
elements of the array supposed to represent each line in a file ? Or, is each array element multiple lines that must be split on the '\n' ? Also, how does @user_field_order relate to @fields ?? Please clarify. "Todd Anderson" <todd@asgweb.net> wrote in message news:3F60E35C.1CB1A2B8@asgweb.net... > Dear Sirs and or Madaams, > I need to write a file from @fields. I need the file to look like... > $bgcolor = "black"; $textcolor = "black"; etc... or > $bgcolor = "black"; > $textcolor = "black"; > > @fields = split (/\|/, $line); > > foreach $field (@user_field_order) > { > This is what I have but it's not putting the >>";\n\n<< after each item > @fields and the $field is printing as $field and it's creating a list > foreach $field (@user_field_order) > $list .= join('\$$field = \"' => @fields => '\"\; \n\n '); > } > Any help is appreciated and thanks in advance for your help. > |
| All times are GMT. The time now is 09:57 AM. |
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.