If you don't want to use the other example and would rather stick to using codes of text, JSON is your best bet.
Live example. Edit: removed.
Code:
:: StoryInit
<<set $player to {
name : '',
age : 0,
description : ''
}>>
:: Start
[[New Character]]
[[Import]]
:: New Character
Name:
<<textbox '$player.name' $player.name>>
Age:
* <label>20s <<radiobutton '$player.age' 25>></label>
* <label>30s <<radiobutton '$player.age' 35>></label>
* <label>40s <<radiobutton '$player.age' 45>></label>
Description:
<<textarea '$player.description' $player.description>>
[[Created]]
:: Created
Name: $player.name
Age: $player.age
Description:
$player.description
[[Export]]
::Export
<<print JSON.stringify($player)>>
Copy and paste this code to import your character!
:: Import
Character code:
<<textarea '_import' ''>>
<<button [[Import|Created]]>>
<<set $player to JSON.parse(_import)>>
<</button>>
This is an incredibly minimal example. You may want to add niceties like a select all and copy all button, and you may want to encode the string as well.
I would not recommend developing and implementing your own code system, mostly because that seems like a lot more work, but if you do go that route, as suggested by @SmuJamesB, the simple answer is that there is no easy way to unpack that data back into story variables without a whole lot of <<if>>s and <<switch>>es, as far as I can tell.
All the other ways to achieve this will require some complex code.