Hi James, Thanks for the tips, I took your advice here is the HTML returned, There still isn't the full 43 elements though strange?
<select class='multiSelectStyle' name='anotherContainer/Choose Page Subject' size=1 onfocus='datacapture.handleElementSelect( 26);' onchange='parent.api.iw_dispatch_handleOnChange(26,this);'> <option value=""> <option value="About You"> About You <option value="Sales Recognition Events Framework"> Sales Recognition Events Framework <option value="Building Wealth"> Building Wealth <option value="Compensation"> Compensation <option value="Employee Development"> Employee Development <option value="Executive Development"> Executive Development <option value="Financial Benefits"> Financial Benefits <option value="Global Pulse Survey"> Global Pulse Survey <option value="Hiring"> Hiring <option value="IDP Tool"> IDP Tool <option value="Manager Services"> Manager Services <option value="Mobility"> Mobility <option value="Other"> Other <option value="Payroll Services"> Payroll Services <option value="PBC Tool - Normal"> PBC Tool - Normal <option value="Personnel Records"> Personnel Records <option value="Reporting"> Reporting <option value="Site Utilities"> Site Utilities <option value="Transition Employees"> Transition Employees <option value="Well Being"> Well Being <option value="Workforce Diversity"> Workforce Diversity <option value="Your Career"> Your Career </select> Cheers Colin James Edward Gray II <[EMAIL PROTECTED]> 30/12/2003 08:26 AM To: Colin Johnstone/Australia/Contr/[EMAIL PROTECTED] cc: [EMAIL PROTECTED] Subject: Re: Splitting Comma delimited list On Dec 29, 2003, at 3:12 PM, Colin Johnstone wrote: > Hello everyone, > > I use the following to split a comma delimited list and get varying > results and I don't understand why. Running your code on your data, I get the expected results (43). > my count of the elements in the splitdata array returns 43 but the > select > list when displayed in our Content management system only has > approximately 23 items. Some items are compltely ignored. The comma > delimited txt file is below. Could this be a browser issue? Is the XHTML still correct? > About You,BCS Employee,Sales Recognition Events > Framework,BPFJ+,Building > Wealth,Community Program,Compensation,Employment Confirmations,Employee > Development,Employee Services,Executive Development,Expense > Reimbursement,Financial Benefits,Flexibility,Global Pulse Survey,Health > Benefits,Hiring,HR Assist,IDP Tool,Insurance,Manager > Services,Management > Development,Mobility,New Hire Information,Other,PaylinkPlus,Payroll > Services,PBC Tool - Urgent,PBC Tool - Normal,Peace of Mind > Benefits,Personnel Records,Promotions,Reporting,Reporting - Data > Quality & > Integrity,Site Utilities,Single Cycle Salary Review,Transition > Employees,Transactional,Well Being,When Life Changes,Workforce > Diversity,Workplace Practices,Your Career > > > > #!/usr/bin/perl # I strongly recommend... use strict; use warnings; > my $fileToOpen = shift; > > # $string = qq[<option value="$fileToOpen" label="$fileToOpen"/>]; > > open( FILEHANDLE, $fileToOpen ) or die ("Could not open file > $fileToOpen"); # You'll stay sane longer if you think up file handle names better than FILEHANDLE > while( my $line = <FILEHANDLE> ){ > chomp $line; > $inFile .= $line; > } # you can replace the above loop with a single read undef $/; # enter slurp mode my $inFile = <FILEHANDLE>; > close(FILEHANDLE); > > my @splitData = split( /\,/, $inFile ); > > $numElements = scalar(@splitData); > $optionHTML = qq[<option label="$numElements:" />]; > > foreach $subject(@splitData){ > > $subject =~ s/&/&/g; > $subject =~ s/\"/"/g; > $optionHTML .= qq[<option label="$subject" />]; > > } > > # produce output > print <<EOF; > <?xml version="1.0" encoding='UTF-8'?> > <substitution> > $optionHTML > </substitution> > EOF > # -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>