I need to switch or convert the integer values from MySQL database to a string values in php, undescorejs -




this code; \socialkit\ui::view('timeline/user/info-bodybuild-row'); contains integer values database table 1, 2 , 3. passed frame $themedata['info_bodybuild_row'] display. code working viewing database, need change integer values string. datatype used in table enum type, , iam working on underscore.js framework.

if (! empty($timeline['bodybuild'])) { $bbt = \socialkit\ui::view('timeline/user/info-bodybuild-row'); $themedata['info_bodybuild_row'] = $bbt; } 

values need change is,

1 = 6 pack

2 = fat

3 = thin

i run doesnot work resulting in error

$bbt = \socialkit\ui::view('timeline/user/info-bodybuild-row'); switch ($bbt) { case '1': $bb = "six pack"; break; case '2': $bb = "fat"; break; case '3': $bb = "thin": break; } $themedata['info_bodybuild_row'] = $bb;

thank in advance!!!





wiki

Comments

Popular posts from this blog

Asterisk AGI Python Script to Dialplan does not work -

python - Read npy file directly from S3 StreamingBody -

kotlin - Out-projected type in generic interface prohibits the use of metod with generic parameter -