get comment array save to table

can anyone help im i want export the price and package to table without th

comment value format
,3,30 Minutes,5,1 Hour,10,2 Hours,20,3 Hours,30,5 Hours,40,1 Day,50,2 Days,60,3 Days,90,7 Days,150,15 Days,300,30 Days


:global RATE [/routing filter get [find chain=RATE] comment];

/file set flash/hotspot/rate.js contents=
“document.getElementById(‘myTable’).innerHTML=‘$RATE’;”
:log info (“Rate Set”);

iwant rate.js output like this

330 Minutes

You can add screenshot or picture with “Attachments” section when you add a post on a topic.

Do not use 3rd party sites (for monetiziong or not) for host images.

found it , thank you

final output i want load the the file insert to table like this

i change the get comment 90% finish now my last problem is combine the txt first tr & td and last closing td & tr tag like this

330 Minutes
:global contentz [/routing filter get [find chain=packageList] comment];
:global content [:pick $contentz 1 [:len $contentz]];
:set content ("$content" . "" . "|");
:global contentLen [ :len $content ] ;
:global lineEnd 0;
:global line "";
:global lastEnd 0;


:do {
       :set lineEnd [:find $content "|" $lastEnd ] ;
       :set line [:pick $content $lastEnd $lineEnd] ;
       :set lastEnd ( $lineEnd + 1) ;

       :local tmpArray [:toarray $line] ;
	:if ( [:pick $tmpArray 0] != "" ) do={
	:put $tmpArray;
         
/ppp secret add name=[:pick $tmpArray 3] comment=[:pick $tmpArray 0];
}
} while ($lineEnd < $contentLen)

Screenshot_2022-08-24-16-29-03-538_com.mikrotik.android.tikapp.jpg
Screenshot_2022-08-24-16-30-38-802_com.mikrotik.android.tikapp.jpg